/* We can cancel aio when any request belonging to the acb is: */
static bool sd_acb_cancelable(const SheepdogAIOCB *acb)
/* We can cancel aio when any request belonging to the acb is: */
static bool sd_acb_cancelable(const SheepdogAIOCB *acb)
{
    BDRVSheepdogState *s = acb->common.bs->opaque;
    AIOReq *aioreq;
    if (!acb->cancelable) {
        return false;
    }
    QLIST_FOREACH(aioreq, &s->inflight_aio_head, aio_siblings) {
        if (aioreq->aiocb == acb) {
            return false;
        }
    }
    return true;
}