Re: [PATCH v1 05/13] gpio: dwapb: Convert to use irqd_to_hwirq()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 15, 2020 at 03:42:42PM +0300, Serge Semin wrote:
> On Thu, Apr 09, 2020 at 05:12:20PM +0300, Andy Shevchenko wrote:
> > Convert to use irqd_to_hwirq() instead of direct access to the hwirq member.

> > -	int bit = d->hwirq;

> > +	u32 bit = irqd_to_hwirq(d);
> 
> I'm not saying that the rest of the driver code is highly coherent with
> ideal design and style. But here I don't really see a point in converting
> the type to u32. As I see it int-like type is more appropriate since
> we don't need to signify the data type width in this context.

> > +	u32 bit = irqd_to_hwirq(d);

The idea is that it corresponds the hardware register width. But, i think the
proper one is irq_hw_number_t as return type in all cases.
Let me check this and fix accordingly.

> > +	irq_hw_number_t hwirq;

-- 
With Best Regards,
Andy Shevchenko





[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux