The QoS throttle will invoke its throttle complete callback within
the scope of the ImageCtx timer lock singleton. This would cause
the potential for deadlock if a future dispatch layer attempted
to acquire the same timer lock.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
<< "flag=" << flag << dendl;
if (set_throttle_flag(tag.image_dispatch_flags, flag)) {
- tag.on_dispatched->complete(0);
+ // timer_lock is held -- so dispatch from outside the timer thread
+ m_image_ctx->op_work_queue->queue(tag.on_dispatched, 0);
}
}