Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
netfs: Slice a writeback from a dirty region
Handle the initiation of writeback of a piece of the dirty list. A slice
of a dirty region is extracted and a writeback record is set up to manage
it. The pages in the affected region are flipped from dirty to
writeback-in-progress.
The writeback is then dispatched (which currently just logs a "--- WRITE
---" message to dmesg and then abandons it).
Notes:
(*) A page may host multiple disjoint dirty regions, each with its own
netfs_dirty_region, and a region may span multiple pages. Dirty
regions are not permitted to overlap, though they may be merged if
they would otherwise overlap.
(*) A page may be involved in multiple simultaneous writebacks. Each one
is managed by a separate netfs_dirty_region and netfs_write_request.
(*) Multiple pages may be required to form a write (for crypto/compression
purposes) and so adjacent non-dirty pages may also get marked for
writeback.
Signed-off-by: David Howells <dhowells@redhat.com>- Loading branch information