From: Josef Bacik <josef@toxicpanda.com>
To: dsterba@suse.cz, linux-btrfs@vger.kernel.org, kernel-team@fb.com
Subject: Re: [PATCH v3 01/12] btrfs: make flush_space take a enum btrfs_flush_state instead of int
Date: Tue, 26 Jan 2021 15:32:36 -0500 [thread overview]
Message-ID: <ea66a2e1-6cd0-8ba9-42dd-a062e31e2dc0@toxicpanda.com> (raw)
In-Reply-To: <20210126183624.GU1993@twin.jikos.cz>
On 1/26/21 1:36 PM, David Sterba wrote:
> On Fri, Oct 09, 2020 at 09:28:18AM -0400, Josef Bacik wrote:
>> 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.
>
> I can't find any such public report and none of the clang warnings seem
> to be specific about that. Local run with clang 11 does not produce any
> warning.
>
IDK, it was a private email just to me with the following output from clang
s/btrfs/space-info.c:1115:12: warning: implicit conversion from
enumeration type 'enum btrfs_flush_state' to different enumeration type
'enum btrfs_reserve_flush_enum' [-Wenum-conversion]
flush = FLUSH_DELALLOC;
~ ^~~~~~~~~~~~~~
fs/btrfs/space-info.c:1120:12: warning: implicit conversion from
enumeration type 'enum btrfs_flush_state' to different enumeration type
'enum btrfs_reserve_flush_enum' [-Wenum-conversion]
flush = FORCE_COMMIT_TRANS;
~ ^~~~~~~~~~~~~~~~~~
fs/btrfs/space-info.c:1124:12: warning: implicit conversion from
enumeration type 'enum btrfs_flush_state' to different enumeration type
'enum btrfs_reserve_flush_enum' [-Wenum-conversion]
flush = FLUSH_DELAYED_ITEMS_NR;
~ ^~~~~~~~~~~~~~~~~~~~~~
fs/btrfs/space-info.c:1127:12: warning: implicit conversion from
enumeration type 'enum btrfs_flush_state' to different enumeration type
'enum btrfs_reserve_flush_enum' [-Wenum-conversion]
flush = FLUSH_DELAYED_REFS_NR;
~ ^~~~~~~~~~~~~~~~~~~~~
I figure it made sense, might as well fix it. Do we have that option for our
shiny new -W build options? Thanks,
Josef
next prev parent reply other threads:[~2021-01-27 10:10 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 ` [PATCH v3 01/12] btrfs: make flush_space take a enum btrfs_flush_state instead of int Josef Bacik
2020-10-12 13:49 ` Nikolay Borisov
2021-01-26 18:36 ` David Sterba
2021-01-26 20:32 ` Josef Bacik [this message]
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=ea66a2e1-6cd0-8ba9-42dd-a062e31e2dc0@toxicpanda.com \
--to=josef@toxicpanda.com \
--cc=dsterba@suse.cz \
--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 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).