]> www.infradead.org Git - users/dwmw2/linux.git/commit
orangefs: Pass mapping to orangefs_writepages_work()
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Wed, 5 Mar 2025 20:47:30 +0000 (20:47 +0000)
committerChristian Brauner <brauner@kernel.org>
Thu, 6 Mar 2025 08:26:06 +0000 (09:26 +0100)
commit6420f17963f2a898407c19ee16a8e71b958125d5
treea4f58f3ac4252a6a20ffc03e51024de2a2f96445
parent40eca026bbaa4216dcabeda4f304f7d3d5247209
orangefs: Pass mapping to orangefs_writepages_work()

Remove two accesses to page->mapping by passing the mapping from
orangefs_writepages() to orangefs_writepages_callback() and then
orangefs_writepages_work().  That makes it obvious that all folios come
from the same mapping, so we can hoist the call to mapping_set_error()
outside the loop.  While I'm here, switch from write_cache_pages()
to writeback_iter() which removes an indirect function call.

Signed-off-by: "Matthew Wilcox (Oracle)" <willy@infradead.org>
Link: https://lore.kernel.org/r/20250305204734.1475264-7-willy@infradead.org
Tested-by: Mike Marshall <hubcap@omnibond.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/orangefs/inode.c