lkml.org 
[lkml]   [2022]   [May]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v4 5/7] gpio: gpiolib: Add a check to validate GPIO hwirq
On Wed, May 18, 2022 at 9:30 PM Lad Prabhakar
<prabhakar.mahadev-lad.rj@bp.renesas.com> wrote:
>
> Add a check to validate GPIO hwirq is always within the range of hwirq_max
> set in the GPIO irq domain.

...

> + if (WARN(hwirq >= domain->hwirq_max,
> + "error: hwirq 0x%x is too large for %s\n",
> + (int)hwirq, domain->name))

Using castings in the printf() often points to possible mistakes or
missed custom specifiers.

...

> + if (WARN(hwirq >= domain->hwirq_max,
> + "error: hwirq 0x%x is too large for %s\n", (int)hwirq, domain->name))

Ditto.

--
With Best Regards,
Andy Shevchenko

\
 
 \ /
  Last update: 2022-05-18 23:14    [W:0.164 / U:0.176 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site