• Josh Durgin's avatar
    rbd: make rbd_obj_notify_ack() synchronous · b10f19aa
    Josh Durgin authored
    commit 20e0af67 upstream.
    
    The only user of rbd_obj_notify_ack() is rbd_watch_cb(). It used
    asynchronously with no tracking of when the notify ack completes, so
    it may still be in progress when the osd_client is shut down.  This
    results in a BUG() since the osd client assumes no requests are in
    flight when it stops. Since all notifies are flushed before the
    osd_client is stopped, waiting for the notify ack to complete before
    returning from the watch callback ensures there are no notify acks in
    flight during shutdown.
    
    Rename rbd_obj_notify_ack() to rbd_obj_notify_ack_sync() to reflect
    its new synchronous nature.
    Signed-off-by: default avatarJosh Durgin <josh.durgin@inktank.com>
    Reviewed-by: default avatarAlex Elder <elder@linaro.org>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    b10f19aa
rbd.c 135 KB