[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YtWwzW/Cou3/aia1@smile.fi.intel.com>
Date: Mon, 18 Jul 2022 22:13:17 +0300
From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To: Marc Zyngier <maz@...nel.org>
Cc: Antonio Borneo <antonio.borneo@...s.st.com>,
linux-kernel@...r.kernel.org,
linux-stm32@...md-mailman.stormreply.com,
linux-arm-kernel@...ts.infradead.org,
Thomas Gleixner <tglx@...utronix.de>,
Maxime Coquelin <mcoquelin.stm32@...il.com>,
Alexandre Torgue <alexandre.torgue@...s.st.com>
Subject: Re: [PATCH v1 1/1] irqchip/stm32-exti: Use INVALID_HWIRQ definition
On Sat, Jul 16, 2022 at 10:41:59AM +0100, Marc Zyngier wrote:
> On Fri, 15 Jul 2022 21:52:03 +0100,
> Andy Shevchenko <andriy.shevchenko@...ux.intel.com> wrote:
> >
> > Use specific definition for invalid IRQ. It makes the
> > code uniform in respect to the constant used for that.
> > No functional change intended.
...
> > -#define EXTI_INVALID_IRQ U8_MAX
> > +#define EXTI_INVALID_IRQ ((u8)INVALID_HWIRQ)
>
> This looks like a terrible idea. It gives the impression that you can
> now rely on comparing the internal data structure field to
> INVALID_HWIRQ. Which is of course bound to fail.
I don't know how one can go to that conclusion, but okay, I understood you.
> To be honest, I'd rather *kill* INVALID_HWIRQ, because apart from
> cherryview, nobody even *checks* for this value by that name. So much
> for the "code uniformity"...
It's used by two or three, I don't remember by heart.
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists