summaryrefslogtreecommitdiffstats
path: root/fs/bcachefs/alloc_foreground.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2025-05-26 17:03:48 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2025-05-30 01:21:13 -0400
commite87de7d4918bd43901685dd1dd5620fc1aafd0aa (patch)
treea2482f521395cacab2b71f2cb274ad215c4da652 /fs/bcachefs/alloc_foreground.h
parentbcachefs: reduce stack usage in alloc_sectors_start() (diff)
downloadlinux-e87de7d4918bd43901685dd1dd5620fc1aafd0aa.tar.gz
linux-e87de7d4918bd43901685dd1dd5620fc1aafd0aa.zip
bcachefs: Move devs_sorted to alloc_request
More stack usage work. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/alloc_foreground.h')
-rw-r--r--fs/bcachefs/alloc_foreground.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/fs/bcachefs/alloc_foreground.h b/fs/bcachefs/alloc_foreground.h
index 2e01c7b61ed1..1b3fc8460096 100644
--- a/fs/bcachefs/alloc_foreground.h
+++ b/fs/bcachefs/alloc_foreground.h
@@ -42,6 +42,7 @@ struct alloc_request {
struct bch_devs_mask devs_may_alloc;
/* bch2_bucket_alloc_set_trans(): */
+ struct dev_alloc_list devs_sorted;
struct bch_dev_usage usage;
/* bch2_bucket_alloc_trans(): */
@@ -71,9 +72,10 @@ struct alloc_request {
struct bch_devs_mask scratch_devs_may_alloc;
};
-struct dev_alloc_list bch2_dev_alloc_list(struct bch_fs *,
- struct dev_stripe_state *,
- struct bch_devs_mask *);
+void bch2_dev_alloc_list(struct bch_fs *,
+ struct dev_stripe_state *,
+ struct bch_devs_mask *,
+ struct dev_alloc_list *);
void bch2_dev_stripe_increment(struct bch_dev *, struct dev_stripe_state *);
static inline struct bch_dev *ob_dev(struct bch_fs *c, struct open_bucket *ob)