Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

bcachefs: Kill journal_seq/gc args to bch2_dev_usage_update_m()

This is only used by gc (fsck).

Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>

+5 -8
+5 -8
fs/bcachefs/buckets.c
··· 346 346 } 347 347 348 348 static void bch2_dev_usage_update_m(struct bch_fs *c, struct bch_dev *ca, 349 - struct bucket old, struct bucket new, 350 - u64 journal_seq, bool gc) 349 + struct bucket old, struct bucket new) 351 350 { 352 351 bch2_dev_usage_update(c, ca, 353 352 bucket_m_to_alloc(old), 354 353 bucket_m_to_alloc(new), 355 - journal_seq, gc); 354 + 0, true); 356 355 } 357 356 358 357 static inline int __update_replicas(struct bch_fs *c, ··· 657 658 err: 658 659 bucket_unlock(g); 659 660 if (!ret) 660 - bch2_dev_usage_update_m(c, ca, old, new, 0, true); 661 + bch2_dev_usage_update_m(c, ca, old, new); 661 662 percpu_up_read(&c->mark_lock); 662 663 return ret; 663 664 } ··· 772 773 unsigned flags) 773 774 { 774 775 struct bch_fs *c = trans->c; 775 - u64 journal_seq = trans->journal_res.seq; 776 776 const struct bch_stripe *s = bkey_s_c_to_stripe(k).v; 777 777 unsigned nr_data = s->nr_blocks - s->nr_redundant; 778 778 bool parity = ptr_idx >= nr_data; ··· 818 820 err: 819 821 bucket_unlock(g); 820 822 if (!ret) 821 - bch2_dev_usage_update_m(c, ca, old, new, journal_seq, true); 823 + bch2_dev_usage_update_m(c, ca, old, new); 822 824 percpu_up_read(&c->mark_lock); 823 825 printbuf_exit(&buf); 824 826 return ret; ··· 857 859 s64 sectors, 858 860 unsigned flags) 859 861 { 860 - u64 journal_seq = trans->journal_res.seq; 861 862 struct bch_fs *c = trans->c; 862 863 struct bch_dev *ca = bch_dev_bkey_exists(c, p.ptr.dev); 863 864 struct bucket old, new, *g; ··· 883 886 new = *g; 884 887 bucket_unlock(g); 885 888 if (!ret) 886 - bch2_dev_usage_update_m(c, ca, old, new, journal_seq, true); 889 + bch2_dev_usage_update_m(c, ca, old, new); 887 890 percpu_up_read(&c->mark_lock); 888 891 889 892 return ret;