[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHp75VceSvk25rbbS-hmJKAgP4Xe+U6tFQDHBEA=9EHnzBH5+g@mail.gmail.com>
Date: Thu, 7 May 2020 12:17:05 +0300
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: David Laight <David.Laight@...lab.com>
Cc: Brian Gerst <brgerst@...il.com>,
Nick Desaulniers <ndesaulniers@...gle.com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>, Borislav Petkov <bp@...en8.de>,
Sedat Dilek <sedat.dilek@...il.com>,
stable <stable@...r.kernel.org>,
Jesse Brandeburg <jesse.brandeburg@...el.com>,
"kernelci . org bot" <bot@...nelci.org>,
Andy Shevchenko <andriy.shevchenko@...el.com>,
Ilie Halip <ilie.halip@...il.com>,
"the arch/x86 maintainers" <x86@...nel.org>,
"H. Peter Anvin" <hpa@...or.com>, Marco Elver <elver@...gle.com>,
"Paul E. McKenney" <paulmck@...nel.org>,
"Peter Zijlstra (Intel)" <peterz@...radead.org>,
Daniel Axtens <dja@...ens.net>,
Masahiro Yamada <yamada.masahiro@...ionext.com>,
Luc Van Oostenryck <luc.vanoostenryck@...il.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"clang-built-linux@...glegroups.com"
<clang-built-linux@...glegroups.com>
Subject: Re: [PATCH] x86: bitops: fix build regression
On Thu, May 7, 2020 at 10:50 AM David Laight <David.Laight@...lab.com> wrote:
> From: Brian Gerst
> > Sent: 07 May 2020 07:18
> > I think a better fix would be to make CONST_MASK() return a u8 value
> > rather than have to cast on every use.
>
> Or assign to a local variable - then it doesn't matter how
> the value is actually calculated. So:
> u8 mask = CONST_MASK(nr);
Another case with negation won't work like this I believe.
So, I thin kthe patch we have is good enough, no need to seek for an evil.
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists