All of lore.kernel.org
 help / color / mirror / Atom feed
From: Josef Bacik <josef@toxicpanda.com>
To: linux-btrfs@vger.kernel.org, kernel-team@fb.com
Subject: [PATCH v3 01/12] btrfs: make flush_space take a enum btrfs_flush_state instead of int
Date: Fri,  9 Oct 2020 09:28:18 -0400	[thread overview]
Message-ID: <397b21a29dfe5d3c8d5fec261c3246b07b93e42c.1602249928.git.josef@toxicpanda.com> (raw)
In-Reply-To: <cover.1602249928.git.josef@toxicpanda.com>

I got a automated message from somebody who runs clang against our
kernels and it's because I used the wrong enum type for what I passed
into flush_space.  Change the argument to be explicitly the enum we're
expecting to make everything consistent.  Maybe eventually gcc will
catch errors like this.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
---
 fs/btrfs/space-info.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/btrfs/space-info.c b/fs/btrfs/space-info.c
index 64099565ab8f..ba2b72409d46 100644
--- a/fs/btrfs/space-info.c
+++ b/fs/btrfs/space-info.c
@@ -667,7 +667,7 @@ static int may_commit_transaction(struct btrfs_fs_info *fs_info,
  */
 static void flush_space(struct btrfs_fs_info *fs_info,
 		       struct btrfs_space_info *space_info, u64 num_bytes,
-		       int state)
+		       enum btrfs_flush_state state)
 {
 	struct btrfs_root *root = fs_info->extent_root;
 	struct btrfs_trans_handle *trans;
@@ -920,7 +920,7 @@ static void btrfs_async_reclaim_metadata_space(struct work_struct *work)
 	struct btrfs_fs_info *fs_info;
 	struct btrfs_space_info *space_info;
 	u64 to_reclaim;
-	int flush_state;
+	enum btrfs_flush_state flush_state;
 	int commit_cycles = 0;
 	u64 last_tickets_id;
 
-- 
2.26.2


  reply	other threads:[~2020-10-09 13:28 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-09 13:28 [PATCH v3 00/12] Improve preemptive ENOSPC flushing Josef Bacik
2020-10-09 13:28 ` Josef Bacik [this message]
2020-10-12 13:49   ` [PATCH v3 01/12] btrfs: make flush_space take a enum btrfs_flush_state instead of int Nikolay Borisov
2021-01-26 18:36   ` David Sterba
2021-01-26 20:32     ` Josef Bacik
2021-01-27 15:27       ` David Sterba
2020-10-09 13:28 ` [PATCH v3 02/12] btrfs: add a trace point for reserve tickets Josef Bacik
2021-01-26 19:41   ` David Sterba
2020-10-09 13:28 ` [PATCH v3 03/12] btrfs: track ordered bytes instead of just dio ordered bytes Josef Bacik
2020-10-12 13:50   ` Nikolay Borisov
2020-10-09 13:28 ` [PATCH v3 04/12] btrfs: introduce a FORCE_COMMIT_TRANS flush operation Josef Bacik
2020-10-12 13:50   ` Nikolay Borisov
2020-10-29 17:03   ` David Sterba
2021-01-26 18:41     ` David Sterba
2020-10-09 13:28 ` [PATCH v3 05/12] btrfs: improve preemptive background space flushing Josef Bacik
2020-10-13 11:29   ` Nikolay Borisov
2020-10-09 13:28 ` [PATCH v3 06/12] btrfs: rename need_do_async_reclaim Josef Bacik
2021-01-26 18:51   ` David Sterba
2020-10-09 13:28 ` [PATCH v3 07/12] btrfs: check reclaim_size in need_preemptive_reclaim Josef Bacik
2020-10-09 13:28 ` [PATCH v3 08/12] btrfs: rework btrfs_calc_reclaim_metadata_size Josef Bacik
2020-10-09 13:28 ` [PATCH v3 09/12] btrfs: simplify the logic in need_preemptive_flushing Josef Bacik
2020-10-13 12:18   ` Nikolay Borisov
2020-10-09 13:28 ` [PATCH v3 10/12] btrfs: implement space clamping for preemptive flushing Josef Bacik
2020-10-29 17:48   ` David Sterba
2020-10-09 13:28 ` [PATCH v3 11/12] btrfs: adjust the flush trace point to include the source Josef Bacik
2021-01-26 19:13   ` David Sterba
2020-10-09 13:28 ` [PATCH v3 12/12] btrfs: add a trace class for dumping the current ENOSPC state Josef Bacik

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=397b21a29dfe5d3c8d5fec261c3246b07b93e42c.1602249928.git.josef@toxicpanda.com \
    --to=josef@toxicpanda.com \
    --cc=kernel-team@fb.com \
    --cc=linux-btrfs@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.