Description
In the Linux kernel, the following vulnerability has been resolved: nvmet-rdma: queue the release work under the mutex nvmet_rdma_remove_one() takes the queue mutex, unlists each queue of the device and queues its release work, then flushes nvmet-wq. So a queue that still holds objects on the device must either be on the list or have its release work queued. nvmet_rdma_queue_disconnect() breaks that: it unlists the queue under the mutex, drops it, and only then calls __nvmet_rdma_queue_disconnect() to queue the work. A device removal in that window finds nothing to wait for, and the release work then destroys the QP and CQ share on a freed device. Queue the work before dropping the mutex, as nvmet_rdma_remove_one() itself does. That's safe now that rdma_disconnect() no longer sleeps on an iWARP event that needs the same mutex.
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
f1d4ef7d88832444e8dfeb0e85e19d3b6ecb5011 to < 3209a79c40e365cc8608fc883b4a423f0a93e4e5affectedf1d4ef7d88832444e8dfeb0e85e19d3b6ecb5011 to < db59223701cc1d566ef7d9cbbf8eed737804fab1affectedf1d4ef7d88832444e8dfeb0e85e19d3b6ecb5011 to < 82aef3f6b2b452493fb492d8fd26dfd5f0e4a983affectedf1d4ef7d88832444e8dfeb0e85e19d3b6ecb5011 to < 84afc77892aa3913176e16dfca971ac9acc81252affectedf1d4ef7d88832444e8dfeb0e85e19d3b6ecb5011 to < 2b8b2393dc2cb5288a73151554482af824b9c6e7affectedf1d4ef7d88832444e8dfeb0e85e19d3b6ecb5011 to < 80095787f776967361cca76357f19e5445e0cd75affected
Linux Linux
Default version status: affected
4.13affected0 to < 4.13unaffected5.10.276 to ≤ 5.10.*unaffected5.15.227 to ≤ 5.15.*unaffected6.12.120 to ≤ 6.12.*unaffected6.18.66 to ≤ 6.18.*unaffected7.3.7 to ≤ 7.3.*unaffected7.4-rc2 to ≤ *unaffected
References
- https://git.kernel.org/stable/c/3209a79c40e365cc8608fc883b4a423f0a93e4e5 ↗
- https://git.kernel.org/stable/c/db59223701cc1d566ef7d9cbbf8eed737804fab1 ↗
- https://git.kernel.org/stable/c/82aef3f6b2b452493fb492d8fd26dfd5f0e4a983 ↗
- https://git.kernel.org/stable/c/84afc77892aa3913176e16dfca971ac9acc81252 ↗
- https://git.kernel.org/stable/c/2b8b2393dc2cb5288a73151554482af824b9c6e7 ↗
- https://git.kernel.org/stable/c/80095787f776967361cca76357f19e5445e0cd75 ↗