Linux-Fsdevel Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Eric Biggers <ebiggers@kernel.org>
Cc: Matthew Wilcox <willy@infradead.org>,
	linux-fsdevel@vger.kernel.org,
	Alexander Viro <viro@zeniv.linux.org.uk>
Subject: Re: [PATCH] fs: define inode flags using bit numbers
Date: Tue, 14 Jul 2020 11:18:11 +1000	[thread overview]
Message-ID: <20200714011811.GJ5369@dread.disaster.area> (raw)
In-Reply-To: <20200713160259.GB1696@sol.localdomain>

On Mon, Jul 13, 2020 at 09:02:59AM -0700, Eric Biggers wrote:
> On Mon, Jul 13, 2020 at 12:59:47PM +0100, Matthew Wilcox wrote:
> > On Sun, Jul 12, 2020 at 08:09:52PM -0700, Eric Biggers wrote:
> > > Define the VFS inode flags using bit numbers instead of hardcoding
> > > powers of 2, which has become unwieldy now that we're up to 65536.
> > 
> > If you're going to change these, why not use the BIT() macro?
> > 
> 
> Either way would be fine with me, but I've seen people complain about BIT()
> before and say they prefer just (1 << n).

Yup, BIT() is just another layer of largely useless macro
obfuscation that forces readers to do yet another lookup to find out
what it means.  Please don't use it.

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

  reply	other threads:[~2020-07-14  1:18 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-13  3:09 Eric Biggers
2020-07-13 11:59 ` Matthew Wilcox
2020-07-13 16:02   ` Eric Biggers
2020-07-14  1:18     ` Dave Chinner [this message]
2020-07-27 16:48 ` Eric Biggers
2020-07-27 18:38   ` Al Viro

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200714011811.GJ5369@dread.disaster.area \
    --to=david@fromorbit.com \
    --cc=ebiggers@kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    --cc=willy@infradead.org \
    --subject='Re: [PATCH] fs: define inode flags using bit numbers' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).