/* Update L1 table with new L2 table offset and write it out  */
static void qed_aio_write_l1_update(void *opaque, int ret)
/* Update L1 table with new L2 table offset and write it out  */
static void qed_aio_write_l1_update(void *opaque, int ret)
{
    QEDAIOCB *acb = opaque;
    BDRVQEDState *s = acb_to_s(acb);
    int index;
    if (ret) {
        qed_aio_complete(acb, ret);
        return;
    }
    index = qed_l1_index(s, acb->cur_pos);
    s->l1_table->offsets[index] = acb->request.l2_table->offset;
    qed_write_l1_table(s, index, 1, qed_commit_l2_update, acb);
}