gfs2: Simplify gfs2_read_super
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Wed, 3 Apr 2024 17:23:50 +0000 (18:23 +0100)
committerAndreas Gruenbacher <agruenba@redhat.com>
Thu, 2 May 2024 17:24:08 +0000 (19:24 +0200)
commit75377ae754c93a312e8430e9c159db3273bb679c
treed4c82fd852646879425bf7ccd2ee47ff835a8dbf
parentf3851fed07327b6a19e7ff8c2106e2b424f44cca
gfs2: Simplify gfs2_read_super

Use submit_bio_wait() instead of hand-rolling our own synchronous
wait.  Also allocate the BIO on the stack since we're not deep in
the call stack at this point.

There's no need to kmap the page, since it isn't allocated from HIGHMEM.
Turn the GFP_NOFS allocation into GFP_KERNEL; if the page allocator
enters reclaim, we cannot be called as the filesystem has not yet been
initialised and so has no pages to reclaim.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
fs/gfs2/ops_fstype.c