Description
In the Linux kernel, the following vulnerability has been resolved: RDMA/nldev: Fix locking when accessing mr->pd Sashiko points out that, due to rereg_mr, the PD is actually variable and all the touches in nldev are racy. Use mr->device instead of mr->pd->device. Getting the PD restrack ID is more tricky. To avoid disturbing all the happy paths, add an rdma_restrack_sync() operation which is sort of like flush_workqueue() or synchronize_irq(): after it returns, all the old nldev touches to the mr are gone and everything sees the new PD. This makes it safe to reach into the PD pointer.
Affected products
Version statuses are supplied by the assigning organization. Consult the original record for detailed ranges and platform conditions.
Linux Linux
Default version status: unaffected
da5c8507821573b8ed6e3f47e009f273493ffaf7 to < 845c6b355226195dad1f26b300c4830f57034e8baffectedda5c8507821573b8ed6e3f47e009f273493ffaf7 to < 7a0cbb5721a1da81e902d73b6049f85ca8f3fc0aaffectedda5c8507821573b8ed6e3f47e009f273493ffaf7 to < 05e26f34597e9c38bb5b340d86b179b23673869faffectedda5c8507821573b8ed6e3f47e009f273493ffaf7 to < a07cba1296aaa81bf9b914486ca957aaff196247affectedda5c8507821573b8ed6e3f47e009f273493ffaf7 to < 1a132ee4e655288d9a0937ea5109a0d038431ae9affectedda5c8507821573b8ed6e3f47e009f273493ffaf7 to < 50d5c02ab8e62325548bd3a6e6b758a9dcd6e7c3affected
Linux Linux
Default version status: affected
4.18affected0 to < 4.18unaffected6.1.188 to ≤ 6.1.*unaffected6.6.157 to ≤ 6.6.*unaffected6.12.110 to ≤ 6.12.*unaffected6.18.52 to ≤ 6.18.*unaffected7.1.5 to ≤ 7.1.*unaffected7.2 to ≤ *unaffected
References
- https://git.kernel.org/stable/c/845c6b355226195dad1f26b300c4830f57034e8b ↗
- https://git.kernel.org/stable/c/7a0cbb5721a1da81e902d73b6049f85ca8f3fc0a ↗
- https://git.kernel.org/stable/c/05e26f34597e9c38bb5b340d86b179b23673869f ↗
- https://git.kernel.org/stable/c/a07cba1296aaa81bf9b914486ca957aaff196247 ↗
- https://git.kernel.org/stable/c/1a132ee4e655288d9a0937ea5109a0d038431ae9 ↗
- https://git.kernel.org/stable/c/50d5c02ab8e62325548bd3a6e6b758a9dcd6e7c3 ↗