nvdimm: pmem: keep PREFLUSH before data writes
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
nvdimm: pmem: keep PREFLUSH before data writes
pmem_submit_bio() records a REQ_PREFLUSH error, but continues to copy the bio data and can later overwrite the error with a successful REQ_FUA flush. That lets data writes run after a failed preflush and can complete the bio successfully despite the failed ordering barrier.
Run the REQ_PREFLUSH flush synchronously before touching the bio data and complete the bio with the flush error if it fails. Keep asynchronous flush chaining for REQ_FUA. At that point, data copy has completed and the parent bio can wait for the chained flush bio.
From the CVE record · Linux
The Linux kernel's nvdimm pmem code can continue writing data after a REQ_PREFLUSH failure and then report the operation as successful if a later REQ_FUA flush succeeds. This can violate the write-ordering barrier; the input does not specify an attacker, access requirements, or user interaction.
Engineers running the Linux kernel with nvdimm pmem should check their deployments; affected versions are not specified.