CVE-2026-89558: md/raid10: fix still_degraded being inverted in raid10_sync_request()
In the Linux kernel, the following vulnerability has been resolved:
md/raid10: fix stilldegraded being inverted in raid10syncrequest()
Commit fe6a19d40ceb ("md/md-bitmap: merge mdbitmapstartsync() into bitmapoperations") converted stilldegraded from int to bool, but inverted the assignment in the loop that checks whether the array will still be degraded after the current device is recovered: "stilldegraded = 1" became "stilldegraded = false".
As a result, recovering a device while another mirror is still missing calls mdbitmapstartsync() with degraded == false, which clears bitmap bits that the still-missing device needs. When that device is re-added, its bitmap-based recovery finds the bits already cleared and skips every region written while the array was degraded, so it is marked Insync while holding stale data: silent corruption.
Reproducer (raid10 near=2, 4 disks, internal bitmap): - fail and remove one disk of each mirror pair - write to the degraded array - re-add both disks and let recovery finish - "check" reports mismatchcnt=262272 after 256 MiB of degraded writes and file contents differ; the second disk's "recovery" completes in milliseconds because everything is skipped
The same conversion in raid1 got it right (stilldegraded = true). Restore the correct value.
Affected Software
Event History
Frequently Asked Questions
Which RAID configurations and recovery sequence are affected?
The described failure affects RAID10 arrays with an internal bitmap when one disk from each mirror pair is failed or removed, data is written while degraded, and the disks are then re-added. The demonstrated case uses a near=2, four-disk RAID10 array.
What is the impact if the issue is triggered?
A re-added disk can be marked In_sync even though it contains stale data, causing silent data corruption. A subsequent RAID check can report mismatches, and file contents can differ after writes made while the array was degraded.
How can an administrator identify a potentially affected recovery?
Look for RAID10 arrays that underwent degraded writes after disks from multiple mirror pairs were removed and then re-added with bitmap-based recovery. A recovery that completes unusually quickly for a re-added disk, followed by a RAID "check" reporting mismatches, matches the described symptom.