diff options
author | Matthew Wilcox (Oracle) <willy@infradead.org> | 2024-04-16 20:28:58 +0300 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2024-05-07 22:38:17 +0300 |
commit | c84f1510fba9fb181e6a1aa7b5fcfc67381b39c9 (patch) | |
tree | 2f7330b8aaa8c632a3e23a7ecd7cba7a2217db0d /fs/ext4 | |
parent | ccedf35b5daa429c0e731eac6fb32b0208302c6b (diff) | |
download | linux-c84f1510fba9fb181e6a1aa7b5fcfc67381b39c9.tar.xz |
ext4: convert ac_buddy_page to ac_buddy_folio
This just carries around the bd_buddy_folio so should also be a folio.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Link: https://lore.kernel.org/r/20240416172900.244637-6-willy@infradead.org
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/ext4')
-rw-r--r-- | fs/ext4/mballoc.c | 8 | ||||
-rw-r--r-- | fs/ext4/mballoc.h | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c index 218480b20058..ac0ee747f4b9 100644 --- a/fs/ext4/mballoc.c +++ b/fs/ext4/mballoc.c @@ -2163,8 +2163,8 @@ static void ext4_mb_use_best_found(struct ext4_allocation_context *ac, */ ac->ac_bitmap_folio = e4b->bd_bitmap_folio; folio_get(ac->ac_bitmap_folio); - ac->ac_buddy_page = &e4b->bd_buddy_folio->page; - get_page(ac->ac_buddy_page); + ac->ac_buddy_folio = e4b->bd_buddy_folio; + folio_get(ac->ac_buddy_folio); /* store last allocated for subsequent stream allocation */ if (ac->ac_flags & EXT4_MB_STREAM_ALLOC) { spin_lock(&sbi->s_md_lock); @@ -6004,8 +6004,8 @@ static void ext4_mb_release_context(struct ext4_allocation_context *ac) } if (ac->ac_bitmap_folio) folio_put(ac->ac_bitmap_folio); - if (ac->ac_buddy_page) - put_page(ac->ac_buddy_page); + if (ac->ac_buddy_folio) + folio_put(ac->ac_buddy_folio); if (ac->ac_flags & EXT4_MB_HINT_GROUP_ALLOC) mutex_unlock(&ac->ac_lg->lg_mutex); ext4_mb_collect_stats(ac); diff --git a/fs/ext4/mballoc.h b/fs/ext4/mballoc.h index 469e5516fb77..d8553f1498d3 100644 --- a/fs/ext4/mballoc.h +++ b/fs/ext4/mballoc.h @@ -205,7 +205,7 @@ struct ext4_allocation_context { * N > 0, the field stores N, otherwise 0 */ __u8 ac_op; /* operation, for history only */ struct folio *ac_bitmap_folio; - struct page *ac_buddy_page; + struct folio *ac_buddy_folio; struct ext4_prealloc_space *ac_pa; struct ext4_locality_group *ac_lg; }; |