Repository navigation
Conversation
Explain how a mapped device is built from a table of ranges, how a table is loaded, suspended, swapped and resumed, and how a bio is cloned, mapped and completed. Cover the linear, thin-provisioning and cache targets, and the history of request-based DM, thin provisioning and the cache target.
Add the transitions out of PM_OUT_OF_METADATA_SPACE and from a table reload, give discards and unshared mapped blocks their own branches in the thin diagram, and scope the thin copy, writethrough and cache-miss statements to what the code does. Correct a few citation ranges.
…ice-mapper page Add a map of where a mapped device sits, an object diagram, worked examples for the sector index and for a bio that crosses a target boundary, a snapshot-sharing diagram, a commit-batching sequence, a cache migration flow, a target feature matrix, a side-by-side table of linear, thin and cache, and examples quoted from the kernel documentation.
…write path Link every commit to git.kernel.org, show the cache migration that carries the bio, and correct the object map, snapshot, map-return and table-line statements. Note which list postings are not linked.
Point every source link at the v7.3 release instead of v7.4-rc5. The line numbers are remapped from the diff between the two tags, and the description of the table's device list now matches v7.3, where struct dm_dev_internal holds a reference count and a dm_dev pointer.
Link "Linux v7.3" in the source note to the v7.3 tree on git.kernel.org.
5 tasks
Name the conditions under which a cache miss starts a migration, which thin pool modes use the read-only handlers, and where the swap keeps the existing queue limits. Cite the zero-fill path for reads of unmapped thin blocks and describe the 13- and 8-patch LWN postings by their counts.
State that the bio-path steps are for normal I/O, that the thin bio diagram shows the PM_WRITE handlers, that empty flush bios are not provisioned, and which cache writes go to the cache only. Cover the straddling-origin and passthrough cases, the needs_check demotion and the CONFIG_BLK_INLINE_ENCRYPTION condition.
Abnormal I/O is still cloned and mapped, by __process_abnormal_io(); fix the reference-count and single-device-test line anchors; scope the thin diagram and the FUA-commit sentence; and separate the straddling and past-the-end origin cases.
…ge cases in the device-mapper page An empty flush on a table of flush_bypasses_map targets goes straight to the underlying devices; a FUA write without PREFLUSH reaches the cache policy through the worker; whole-block FUA overwrites are completed from a second list after the commit; the read-only pool modes and PM_FAIL are scoped to thin devices and to writes with data.
…in statements Name the two completion exceptions with their sources, include write-zeroes in the copy counts, say that stripe also sets flush_bypasses_map, restrict the second flush list to writes issued ahead of the mapping, and describe the truncated origin read.
…statements Add the polled BLK_STS_AGAIN requeue case, say that the part of an origin-straddling read inside the origin is the part read, and include the break-sharing copy in the writes that reach the second flush list.
Cite what the metadata header says about the superblock and space maps, include FUA writes among the bios the thin target defers, anchor the end_io and wildcard rows to the code that shows them, fix two off-by-one line anchors, escape the underscores in a quoted comment, and remove duplicate and mismatched link labels.
… device-mapper page Describe the unreachable-looking writethrough duplicate branch from what the source shows, say that REQ_PREFLUSH bios (not all flush-flagged bios) skip the policy lookup, scope the thin diagram edges and the FUA sequence to writes with data and to the submit path, and note the sector-zero start rule and the clone allocation.
… discard case A FUA write that starts a migration with the bio is ended without the commit step; the promotion edge in the migration diagram is conditional; discards in the read-only pool modes are completed, not remapped; and two line anchors and a stray comma are corrected.
Align two line-range labels with their anchors, describe the deferred-bio list as also holding re-queued I/O, cite the commit behind the thin overview sentence, and make the thin bio-path diagram cover empty flushes and the zeroing condition.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds
block/device-mapper.md, linked from the block README and the nav.Device mapper builds a virtual block device from a table of ranges, each handled by a target.
docs/block/covereddm-verityandsecurity/coversdm-crypt, but nothing explained the core or the common targets. Every behaviour claim links to the function or line at Linux v7.3, every history claim links to its commit (the full hash is in the link; release and author date are in the text) or to the LWN posting, and quotes are verbatim. The page covers:/dev/mapper/control);DM_MAPIO_*return values, completion, and how flushes and discards are handled;linear, the smallest target, with its map function quoted;dm_submit_bio_remap(), with every commit linked to git.kernel.org. The thin-provisioning, cache,dm_submit_bio_remap()and bio-splitting commits carry noLink:trailer, so each posting is linked from the history section and was compared with its commit message.mkdocs build --strictpasses.Closes #896
Part of #882