Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1413174

Re: [PATCH] of: irq: don't return 0 from of_irq_get()

From Rob Herring <robh@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH] of: irq: don't return 0 from of_irq_get()
Date 2016-06-03 14:20 +0200
Message-ID <rFWf0-32g-21@gated-at.bofh.it> (permalink)
References <rDUqZ-5Or-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Sun, May 29, 2016 at 12:53:08AM +0300, Sergei Shtylyov wrote:
> of_irq_get() returns 0 iff irq_create_of_mapping() call fails. Returning
> both error code  and 0 on failure is a sign of a misdesigned API. Return
> -ENXIO instead like one of the callers, platform_get_irq(), does; fix up
> the kernel-doc as well...
> 
> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>

So I think this is done this way because of the variation in NO_IRQ 
definition across architectures. But then again, of_irq_get is 
relatively new.

Rob

Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

Re: [PATCH] of: irq: don't return 0 from of_irq_get() Rob Herring <robh@kernel.org> - 2016-06-03 14:20 +0200
  Re: [PATCH] of: irq: don't return 0 from of_irq_get() Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> - 2016-06-10 14:20 +0200
    Re: [PATCH] of: irq: don't return 0 from of_irq_get() Rob Herring <robh@kernel.org> - 2016-06-10 15:00 +0200

csiph-web