Skip to content
Commit 52287ed4 authored by Yewon Choi's avatar Yewon Choi Committed by Sasha Levin
Browse files

rds: introduce acquire/release ordering in acquire/release_in_xmit()



[ Upstream commit 1422f288 ]

acquire/release_in_xmit() work as bit lock in rds_send_xmit(), so they
are expected to ensure acquire/release memory ordering semantics.
However, test_and_set_bit/clear_bit() don't imply such semantics, on
top of this, following smp_mb__after_atomic() does not guarantee release
ordering (memory barrier actually should be placed before clear_bit()).

Instead, we use clear_bit_unlock/test_and_set_bit_lock() here.

Fixes: 0f4b1c7e ("rds: fix rds_send_xmit() serialization")
Fixes: 1f9ecd7e ("RDS: Pass rds_conn_path to rds_send_xmit()")
Signed-off-by: default avatarYewon Choi <woni9911@gmail.com>
Reviewed-by: default avatarMichal Kubiak <michal.kubiak@intel.com>
Link: https://lore.kernel.org/r/ZfQUxnNTO9AJmzwc@libra05


Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 45a83b22
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment