From: Sage Weil Date: Tue, 31 Jul 2018 21:54:26 +0000 (-0500) Subject: osd: no osd_lock for finish_splits X-Git-Tag: v14.0.1~371^2~11 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=45a556ad7dbf3fb8963b734de931cdb60ce09d0a;p=ceph-ci.git osd: no osd_lock for finish_splits This used to protect the pg registration probably? There is no need for it now. More importantly, having it here can cause a deadlock when we are holding osd_lock and blocking on wait_min_pg_epoch(), because a PG may need to finish splitting to advance and then merge with a peer. (The wait won't block on *this* PG since it isn't registered in the shard yet, but it will block on the merge peer.) Signed-off-by: Sage Weil --- diff --git a/src/osd/OSD.cc b/src/osd/OSD.cc index 073c90c66e0..022e2c46d5b 100644 --- a/src/osd/OSD.cc +++ b/src/osd/OSD.cc @@ -8035,7 +8035,6 @@ struct C_FinishSplits : public Context { void OSD::_finish_splits(set& pgs) { dout(10) << __func__ << " " << pgs << dendl; - Mutex::Locker l(osd_lock); if (is_stopping()) return; PG::RecoveryCtx rctx = create_context();