lkml.org 
[lkml]   [2016]   [Sep]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] genirq: Generic chip: factorise code using irq_get_domain_generic_chip()
On Mon, 1 Aug 2016, Sebastian Frias wrote:
> @@ -350,10 +350,10 @@ irq_get_domain_generic_chip(struct irq_domain *d, unsigned int hw_irq)
> int idx;
>
> if (!dgc)
> - return NULL;
> + return ERR_PTR(-ENODEV);
> idx = hw_irq / dgc->irqs_per_chip;
> if (idx >= dgc->num_chips)
> - return NULL;
> + return ERR_PTR(-EINVAL);

This is completely pointless churn. None of the existing callsites cares
about the error value. We can simply split out the guts into a static
function and keep the semantics for irq_get_domain_generic_chip.

I'll fix that up while applying it.

Thanks,

tglx


\
 
 \ /
  Last update: 2016-09-17 09:58    [W:0.040 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site