From 03b59b2ef890dfcb4e60a080147aa30cd0016f77 Mon Sep 17 00:00:00 2001 From: Jianpeng Ma Date: Fri, 14 Jul 2017 01:07:48 +0800 Subject: [PATCH] os/bluestore/BlueStore: remove useless judgement. In fact logger is never null. Signed-off-by: Jianpeng Ma --- src/os/bluestore/BlueStore.cc | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/os/bluestore/BlueStore.cc b/src/os/bluestore/BlueStore.cc index c07cff4bf46f6..7e5b4fe2fe4d3 100644 --- a/src/os/bluestore/BlueStore.cc +++ b/src/os/bluestore/BlueStore.cc @@ -8423,16 +8423,16 @@ void BlueStore::_kv_sync_thread() dout(10) << __func__ << " blobid_max now " << blobid_max << dendl; } - utime_t finish = ceph_clock_now(); - utime_t dur_flush = after_flush - start; - utime_t dur_kv = finish - after_flush; - utime_t dur = finish - start; - dout(20) << __func__ << " committed " << kv_committing.size() - << " cleaned " << deferred_stable.size() - << " in " << dur - << " (" << dur_flush << " flush + " << dur_kv << " kv commit)" - << dendl; - if (logger) { + { + utime_t finish = ceph_clock_now(); + utime_t dur_flush = after_flush - start; + utime_t dur_kv = finish - after_flush; + utime_t dur = finish - start; + dout(20) << __func__ << " committed " << kv_committing.size() + << " cleaned " << deferred_stable.size() + << " in " << dur + << " (" << dur_flush << " flush + " << dur_kv << " kv commit)" + << dendl; logger->tinc(l_bluestore_kv_flush_lat, dur_flush); logger->tinc(l_bluestore_kv_commit_lat, dur_kv); logger->tinc(l_bluestore_kv_lat, dur); -- 2.39.5