static void blk_mig_read_cb(void *opaque, int ret)

{

    BlkMigBlock *blk = opaque;



    blk_mig_lock();

    blk->ret = ret;



    QSIMPLEQ_INSERT_TAIL(&block_mig_state.blk_list, blk, entry);

    bmds_set_aio_inflight(blk->bmds, blk->sector, blk->nr_sectors, 0);



    block_mig_state.submitted--;

    block_mig_state.read_done++;

    assert(block_mig_state.submitted >= 0);

    blk_mig_unlock();

}

static void blk_mig_read_cb(void *opaque, int ret)

{

    BlkMigBlock *blk = opaque;



    blk_mig_lock();

    blk->ret = ret;



    QSIMPLEQ_INSERT_TAIL(&block_mig_state.blk_list, blk, entry);

    bmds_set_aio_inflight(blk->bmds, blk->sector, blk->nr_sectors, 0);



    block_mig_state.submitted--;

    block_mig_state.read_done++;

    assert(block_mig_state.submitted >= 0);

    blk_mig_unlock();

}

static void FUNC_0(void *VAR_0, int VAR_1)

{

    BlkMigBlock *blk = VAR_0;



    blk_mig_lock();

    blk->VAR_1 = VAR_1;



    QSIMPLEQ_INSERT_TAIL(&block_mig_state.blk_list, blk, entry);

    bmds_set_aio_inflight(blk->bmds, blk->sector, blk->nr_sectors, 0);



    block_mig_state.submitted--;

    block_mig_state.read_done++;

    assert(block_mig_state.submitted >= 0);

    blk_mig_unlock();

}

static void FUNC_0(void *VAR_0, int VAR_1)
{ BlkMigBlock *blk = VAR_0; blk_mig_lock(); blk->VAR_1 = VAR_1; QSIMPLEQ_INSERT_TAIL(&block_mig_state.blk_list, blk, entry); bmds_set_aio_inflight(blk->bmds, blk->sector, blk->nr_sectors, 0); block_mig_state.submitted--; block_mig_state.read_done++; assert(block_mig_state.submitted >= 0); blk_mig_unlock(); }