From a0c51d0e7f05e84411e3877b5861f3eec26ad934 Mon Sep 17 00:00:00 2001 From: JonBailey1993 Date: Wed, 9 Oct 2024 11:28:42 +0100 Subject: [PATCH] common/io_exerciser: Modify is_locked_by_me call in ceph_test_rados_io_sequence is_locked_by_me() is a function of ceph::mutex which is only used in debug builds. By using the ceph_mutex_is_locked_by_me macro, we can neatly make sure we only run this function in debug mode, allowing compilation to no longer be affected when running in release mode. Signed-off-by: Jon Bailey --- src/common/io_exerciser/RadosIo.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/io_exerciser/RadosIo.cc b/src/common/io_exerciser/RadosIo.cc index 41be2885f3f67..a28a1e2f488b4 100644 --- a/src/common/io_exerciser/RadosIo.cc +++ b/src/common/io_exerciser/RadosIo.cc @@ -81,7 +81,7 @@ RadosIo::AsyncOpInfo::AsyncOpInfo(uint64_t offset1, uint64_t length1, bool RadosIo::readyForIoOp(IoOp &op) { - ceph_assert(lock.is_locked_by_me()); //Must be called with lock held + ceph_assert(ceph_mutex_is_locked_by_me(lock)); //Must be called with lock held if (!om->readyForIoOp(op)) { return false; } -- 2.39.5