mirror of
https://github.com/ceph/ceph
synced 2025-02-24 03:27:10 +00:00
librbd: update refresh image dispatch layer flush exclusions
Only flush requests coming from the refresh state machine or from the exclusive-lock dispatch layer initializationshould be ignored. This is because both can be initiated from the refresh state machine and therefore deadlock. Signed-off-by: Jason Dillaman <dillaman@redhat.com>
This commit is contained in:
parent
a320a2b821
commit
2122542a2e
@ -122,7 +122,11 @@ bool RefreshImageDispatch<I>::flush(
|
||||
auto cct = m_image_ctx->cct;
|
||||
ldout(cct, 20) << "tid=" << tid << dendl;
|
||||
|
||||
if (flush_source != FLUSH_SOURCE_USER) {
|
||||
// The refresh state machine can initiate a flush and it can
|
||||
// enable the exclusive-lock which will also attmept to flush.
|
||||
if (flush_source == FLUSH_SOURCE_REFRESH ||
|
||||
flush_source == FLUSH_SOURCE_EXCLUSIVE_LOCK_SKIP_REFRESH ||
|
||||
flush_source == FLUSH_SOURCE_SHUTDOWN) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user