[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMRc=MdNQ+rquq6_rf-rxvoPzz9G0EzO4T=ryF6XYXh51NBL_w@mail.gmail.com>
Date: Mon, 20 Sep 2021 17:00:10 +0200
From: Bartosz Golaszewski <brgl@...ev.pl>
To: Geert Uytterhoeven <geert@...ux-m68k.org>
Cc: Christoph Hellwig <hch@....de>, Joel Becker <jlbec@...lplan.org>,
Shuah Khan <shuah@...nel.org>,
Linus Walleij <linus.walleij@...aro.org>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Uwe Kleine-König
<u.kleine-koenig@...gutronix.de>,
Kent Gibson <warthog618@...il.com>,
Jonathan Corbet <corbet@....net>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Al Viro <viro@...iv.linux.org.uk>,
Jack Winch <sunt.un.morcov@...il.com>,
"open list:GPIO SUBSYSTEM" <linux-gpio@...r.kernel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"open list:DOCUMENTATION" <linux-doc@...r.kernel.org>
Subject: Re: [PATCH v5 2/8] configfs: use BIT() for internal flags
On Mon, Sep 20, 2021 at 4:50 PM Geert Uytterhoeven <geert@...ux-m68k.org> wrote:
>
> Hi Bartosz,
>
> On Mon, Sep 20, 2021 at 4:47 PM Bartosz Golaszewski <brgl@...ev.pl> wrote:
> > On Mon, Sep 20, 2021 at 4:30 PM Christoph Hellwig <hch@....de> wrote:
> > > On Mon, Sep 20, 2021 at 04:29:30PM +0200, Geert Uytterhoeven wrote:
> > > > On Mon, Sep 20, 2021 at 4:09 PM Christoph Hellwig <hch@....de> wrote:
> > > > > On Mon, Sep 20, 2021 at 04:05:03PM +0200, Bartosz Golaszewski wrote:
> > > > > > For better readability and maintenance: use the BIT() macro for flag
> > > > > > definitions.
> > > > >
> > > > > NAK. BIT() is the stupidest macro in the kernel and shall not be used
> > > > > ever. And I'm pretty sure we had this discussion a few times.
> > > >
> > > > Care to explain why it is a stupid macro?
> > >
> > > Please look at the previous thread. I'm tired of this discussion.
> >
> > The only previous answer from Christoph is this:
> > https://www.mail-archive.com/linux-kernel@vger.kernel.org/msg2399968.html
>
> Yep, found that one, too.
>
> Now, as these definitions do not correspond to hardware register bits,
> perhaps use an enum?
>
These are flags, we can set more than one to any given dirent.
Anyway, I'm more interested in Al's comments on the implementation of
committable items than bikeshedding about whether to use or not to use
BIT() so I'll wait for those before revisiting this patch.
Bart
Powered by blists - more mailing lists