------------------------------>8-------------8<---------------------------------
platform_get_irq() can return -ENXIO, but since 'irq' is an unsigned int, it
does not show when the IRQ resource wasn't found.
Signed-off-by: Roel Kluin <redacted>
---
From: Jeff Garzik <hidden> Date: 2009-03-05 12:23:32
Roel Kluin wrote:
quoted hunk
------------------------------>8-------------8<---------------------------------
platform_get_irq() can return -ENXIO, but since 'irq' is an unsigned int, it
does not show when the IRQ resource wasn't found.
Signed-off-by: Roel Kluin <redacted>
---
From: Phil Sutter <hidden> Date: 2009-03-06 16:53:46
Hi,
On Thu, Mar 05, 2009 at 07:23:22AM -0500, Jeff Garzik wrote:
Roel Kluin wrote:
quoted
------------------------------>8-------------8<---------------------------------
platform_get_irq() can return -ENXIO, but since 'irq' is an unsigned int,
it
does not show when the IRQ resource wasn't found.
Signed-off-by: Roel Kluin <redacted>
---
That's fine for me, though I didn't test it (I managed to break my
build-machine somehow, in an attempt to having the mainboard properly
grounded).
One could simplify the patch by making the variable 'irq' be signed
instead of unsigned. This would also prevent "abusing" the variable
'ret'. What do you think?
Greetings, Phil
Hi,
Le Friday 06 March 2009 17:43:18 Phil Sutter, vous avez écrit :
Hi,
On Thu, Mar 05, 2009 at 07:23:22AM -0500, Jeff Garzik wrote:
quoted
Roel Kluin wrote:
quoted
------------------------------>8-------------8<-------------------------
-------- platform_get_irq() can return -ENXIO, but since 'irq' is an
unsigned int, it
does not show when the IRQ resource wasn't found.
Signed-off-by: Roel Kluin <redacted>
---
That's fine for me, though I didn't test it (I managed to break my
build-machine somehow, in an attempt to having the mainboard properly
grounded).
One could simplify the patch by making the variable 'irq' be signed
instead of unsigned. This would also prevent "abusing" the variable
'ret'. What do you think?
I agree with this proposal, abusing the ret value is not that good. What about the patch below :
--
From: Florian Fainelli <florian@openwrt.org>
Subject: [PATCH v2] pata-rb532-cf: platform_get_irq() failure ignored
platform_get_irq() can return -ENXIO, but since 'irq' is an
unsigned int, it does not show when the IRQ resource wasn't found.
Make irq an int so that we can use a single variable to test the
platform_get_irq() return value.
Signed-off-by: Roel Kluin <redacted>
Signed-off-by: Phil Sutter <redacted>
Signed-off-by: Florian Fainelli <florian@openwrt.org>
--
From: Jeff Garzik <hidden> Date: 2009-03-25 02:17:10
Florian Fainelli wrote:
quoted hunk
Hi,
Le Friday 06 March 2009 17:43:18 Phil Sutter, vous avez écrit :
quoted
Hi,
On Thu, Mar 05, 2009 at 07:23:22AM -0500, Jeff Garzik wrote:
quoted
Roel Kluin wrote:
quoted
------------------------------>8-------------8<-------------------------
-------- platform_get_irq() can return -ENXIO, but since 'irq' is an
unsigned int, it
does not show when the IRQ resource wasn't found.
Signed-off-by: Roel Kluin <redacted>
---
That's fine for me, though I didn't test it (I managed to break my
build-machine somehow, in an attempt to having the mainboard properly
grounded).
One could simplify the patch by making the variable 'irq' be signed
instead of unsigned. This would also prevent "abusing" the variable
'ret'. What do you think?
I agree with this proposal, abusing the ret value is not that good. What about the patch below :
--
From: Florian Fainelli <florian@openwrt.org>
Subject: [PATCH v2] pata-rb532-cf: platform_get_irq() failure ignored
platform_get_irq() can return -ENXIO, but since 'irq' is an
unsigned int, it does not show when the IRQ resource wasn't found.
Make irq an int so that we can use a single variable to test the
platform_get_irq() return value.
Signed-off-by: Roel Kluin <redacted>
Signed-off-by: Phil Sutter <redacted>
Signed-off-by: Florian Fainelli <florian@openwrt.org>
--