diff options
| author | Julian Sun <sunjunchao@bytedance.com> | 2025-09-29 19:13:49 +0800 |
|---|---|---|
| committer | Christian Brauner <brauner@kernel.org> | 2025-10-29 23:33:48 +0100 |
| commit | 4952f35f0545f3b53dab8d5fd727c4827c2a2778 (patch) | |
| tree | 0cc0563c7281223a21f18ebedf01adff666d775d /fs/ceph | |
| parent | 891bea757c771dca47e871444faecb1ed642a311 (diff) | |
fs: Make wbc_to_tag() inline and use it in fs.
The logic in wbc_to_tag() is widely used in file systems, so modify this
function to be inline and use it in file systems.
This patch has only passed compilation tests, but it should be fine.
Signed-off-by: Julian Sun <sunjunchao@bytedance.com>
Reviewed-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'fs/ceph')
| -rw-r--r-- | fs/ceph/addr.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/fs/ceph/addr.c b/fs/ceph/addr.c index 322ed268f14a..63b75d214210 100644 --- a/fs/ceph/addr.c +++ b/fs/ceph/addr.c @@ -1045,11 +1045,7 @@ void ceph_init_writeback_ctl(struct address_space *mapping, ceph_wbc->index = ceph_wbc->start_index; ceph_wbc->end = -1; - if (wbc->sync_mode == WB_SYNC_ALL || wbc->tagged_writepages) { - ceph_wbc->tag = PAGECACHE_TAG_TOWRITE; - } else { - ceph_wbc->tag = PAGECACHE_TAG_DIRTY; - } + ceph_wbc->tag = wbc_to_tag(wbc); ceph_wbc->op_idx = -1; ceph_wbc->num_ops = 0; |
