All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <djwong@kernel.org>
To: Christoph Hellwig <hch@lst.de>,
	linux-xfs@vger.kernel.org, hch@infradead.org,
	david@fromorbit.com
Subject: [PATCH 5/4] xfs: fix up build warnings when quotas are disabled
Date: Mon, 25 Jan 2021 20:51:28 -0800	[thread overview]
Message-ID: <20210126045128.GL7698@magnolia> (raw)
In-Reply-To: <161142789504.2170981.1372317837643770452.stgit@magnolia>

From: Darrick J. Wong <djwong@kernel.org>

Fix some build warnings on gcc 10.2 when quotas are disabled.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
---
 fs/xfs/xfs_quota.h |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/fs/xfs/xfs_quota.h b/fs/xfs/xfs_quota.h
index 16a2e7adf4da..4cafc1c78879 100644
--- a/fs/xfs/xfs_quota.h
+++ b/fs/xfs/xfs_quota.h
@@ -130,7 +130,7 @@ xfs_qm_vop_dqalloc(struct xfs_inode *ip, kuid_t kuid, kgid_t kgid,
 }
 #define xfs_trans_dup_dqinfo(tp, tp2)
 #define xfs_trans_free_dqinfo(tp)
-#define xfs_trans_mod_dquot_byino(tp, ip, fields, delta)
+#define xfs_trans_mod_dquot_byino(tp, ip, fields, delta) do { } while (0)
 #define xfs_trans_apply_dquot_deltas(tp)
 #define xfs_trans_unreserve_and_mod_dquots(tp)
 static inline int xfs_trans_reserve_quota_nblks(struct xfs_trans *tp,
@@ -167,8 +167,8 @@ xfs_trans_reserve_quota_icreate(struct xfs_trans *tp, struct xfs_inode *dp,
 #define xfs_qm_dqattach(ip)						(0)
 #define xfs_qm_dqattach_locked(ip, fl)					(0)
 #define xfs_qm_dqdetach(ip)
-#define xfs_qm_dqrele(d)
-#define xfs_qm_statvfs(ip, s)
+#define xfs_qm_dqrele(d)			do { (d) = (d); } while(0)
+#define xfs_qm_statvfs(ip, s)			do { } while(0)
 #define xfs_qm_newmount(mp, a, b)					(0)
 #define xfs_qm_mount_quotas(mp)
 #define xfs_qm_unmount(mp)

  parent reply	other threads:[~2021-01-27 10:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-23 18:51 [PATCHSET v2 0/4] xfs: minor cleanups of the quota functions Darrick J. Wong
2021-01-23 18:51 ` [PATCH 1/4] xfs: clean up quota reservation callsites Darrick J. Wong
2021-01-25 15:13   ` Brian Foster
2021-01-23 18:51 ` [PATCH 2/4] xfs: clean up quota reservation wrappers Darrick J. Wong
2021-01-25 15:13   ` Brian Foster
2021-01-23 18:51 ` [PATCH 3/4] xfs: create convenience wrappers for incore quota block reservations Darrick J. Wong
2021-01-24  9:33   ` Christoph Hellwig
2021-01-25 15:15   ` Brian Foster
2021-01-26 20:37     ` Darrick J. Wong
2021-01-23 18:51 ` [PATCH 4/4] xfs: clean up icreate quota reservation calls Darrick J. Wong
2021-01-25 15:17   ` Brian Foster
2021-01-26 18:23     ` Darrick J. Wong
2021-01-26  4:51 ` Darrick J. Wong [this message]
2021-01-27 16:58   ` [PATCH 5/4] xfs: fix up build warnings when quotas are disabled 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=20210126045128.GL7698@magnolia \
    --to=djwong@kernel.org \
    --cc=david@fromorbit.com \
    --cc=hch@infradead.org \
    --cc=hch@lst.de \
    --cc=linux-xfs@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.