public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: Eric Sandeen <sandeen@sandeen.net>
Cc: xiakaixu1987@gmail.com, linux-xfs@vger.kernel.org,
	Kaixu Xia <kaixuxia@tencent.com>
Subject: Re: [PATCH] xfs: remove the unused BBMASK macro
Date: Mon, 19 Oct 2020 09:08:02 -0700	[thread overview]
Message-ID: <20201019160802.GI9832@magnolia> (raw)
In-Reply-To: <c1453fb1-3e84-677c-15ab-7f51ca758862@sandeen.net>

On Mon, Oct 19, 2020 at 08:54:28AM -0500, Eric Sandeen wrote:
> On 10/19/20 4:47 AM, xiakaixu1987@gmail.com wrote:
> > From: Kaixu Xia <kaixuxia@tencent.com>
> > 
> > There are no callers of the BBMASK macro, so remove it.
> > 
> > Signed-off-by: Kaixu Xia <kaixuxia@tencent.com>
> > ---
> >  fs/xfs/libxfs/xfs_fs.h | 1 -
> >  1 file changed, 1 deletion(-)
> > 
> > diff --git a/fs/xfs/libxfs/xfs_fs.h b/fs/xfs/libxfs/xfs_fs.h
> > index 2a2e3cfd94f0..8fd1e20f0d73 100644
> > --- a/fs/xfs/libxfs/xfs_fs.h
> > +++ b/fs/xfs/libxfs/xfs_fs.h
> > @@ -847,7 +847,6 @@ struct xfs_scrub_metadata {
> >   */
> >  #define BBSHIFT		9
> >  #define BBSIZE		(1<<BBSHIFT)
> > -#define BBMASK		(BBSIZE-1)
> >  #define BTOBB(bytes)	(((__u64)(bytes) + BBSIZE - 1) >> BBSHIFT)
> >  #define BTOBBT(bytes)	((__u64)(bytes) >> BBSHIFT)
> >  #define BBTOB(bbs)	((bbs) << BBSHIFT)
> 
> 
> This header is shared with userspace, and the macro is used there,
> though only once.
> 
> This header is also shipped as part of the "install-dev" fileset, and
> defines a public API, though I don't think BBMSK is actually used
> in any userspace interface.

$ grep BBMASK /usr/include/
/usr/include/xfs/xfs_fs.h:868:#define BBMASK            (BBSIZE-1)

This ships in a user-visible header file, so it can only be removed by
going through the deprecation process.

--D

> 
> -Eric

  reply	other threads:[~2020-10-19 16:09 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-19  9:47 [PATCH] xfs: remove the unused BBMASK macro xiakaixu1987
2020-10-19  9:47 ` [PATCH] xfs: use the SECTOR_SHIFT macro instead of the magic number xiakaixu1987
2020-10-19 16:32   ` Eric Sandeen
2020-10-20  2:54     ` kaixuxia
2020-10-19 13:54 ` [PATCH] xfs: remove the unused BBMASK macro Eric Sandeen
2020-10-19 16:08   ` Darrick J. Wong [this message]
2020-10-27 18:46     ` Christoph Hellwig
2020-10-20  2:59   ` kaixuxia
2020-10-27 18:44 ` Christoph Hellwig

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=20201019160802.GI9832@magnolia \
    --to=darrick.wong@oracle.com \
    --cc=kaixuxia@tencent.com \
    --cc=linux-xfs@vger.kernel.org \
    --cc=sandeen@sandeen.net \
    --cc=xiakaixu1987@gmail.com \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox