block.c (eeea1faa099f82328f5831cf252f8ce0a59a9287) block.c (17e1e2be5f9e84e0298e28e70675655b43e225ea)
1/*
2 * QEMU System Emulator block driver
3 *
4 * Copyright (c) 2003 Fabrice Bellard
5 *
6 * Permission is hereby granted, free of charge, to any person obtaining a copy
7 * of this software and associated documentation files (the "Software"), to deal
8 * in the Software without restriction, including without limitation the rights

--- 3681 unchanged lines hidden (view full) ---

3690 bdrv_set_perm(state->bs, state->perm, state->shared_perm);
3691 } else {
3692 bdrv_abort_perm_update(state->bs);
3693 if (state->replace_backing_bs && state->new_backing_bs) {
3694 bdrv_abort_perm_update(state->new_backing_bs);
3695 }
3696 }
3697 }
1/*
2 * QEMU System Emulator block driver
3 *
4 * Copyright (c) 2003 Fabrice Bellard
5 *
6 * Permission is hereby granted, free of charge, to any person obtaining a copy
7 * of this software and associated documentation files (the "Software"), to deal
8 * in the Software without restriction, including without limitation the rights

--- 3681 unchanged lines hidden (view full) ---

3690 bdrv_set_perm(state->bs, state->perm, state->shared_perm);
3691 } else {
3692 bdrv_abort_perm_update(state->bs);
3693 if (state->replace_backing_bs && state->new_backing_bs) {
3694 bdrv_abort_perm_update(state->new_backing_bs);
3695 }
3696 }
3697 }
3698
3699 if (ret == 0) {
3700 QTAILQ_FOREACH_REVERSE(bs_entry, bs_queue, entry) {
3701 BlockDriverState *bs = bs_entry->state.bs;
3702
3703 if (bs->drv->bdrv_reopen_commit_post)
3704 bs->drv->bdrv_reopen_commit_post(&bs_entry->state);
3705 }
3706 }
3698cleanup:
3699 QTAILQ_FOREACH_SAFE(bs_entry, bs_queue, entry, next) {
3700 if (ret) {
3701 if (bs_entry->prepared) {
3702 bdrv_reopen_abort(&bs_entry->state);
3703 }
3704 qobject_unref(bs_entry->state.explicit_options);
3705 qobject_unref(bs_entry->state.options);

--- 3026 unchanged lines hidden ---
3707cleanup:
3708 QTAILQ_FOREACH_SAFE(bs_entry, bs_queue, entry, next) {
3709 if (ret) {
3710 if (bs_entry->prepared) {
3711 bdrv_reopen_abort(&bs_entry->state);
3712 }
3713 qobject_unref(bs_entry->state.explicit_options);
3714 qobject_unref(bs_entry->state.options);

--- 3026 unchanged lines hidden ---