On 10/01/2015 02:01 PM, Paolo Bonzini wrote:
> 
> 
> On 01/10/2015 18:34, John Snow wrote:
>> +
>> +    error_setg(&blocker, "Block device(s) are in use by a Block 
>> Transaction");
> 
> s/Block Transaction/transaction command/
> 
> But how can migration start during a transaction?
> 

Well, it definitely can't now ! :)

This is actually more for the other case: The migration starts, and we
want to prohibit snapshots and transactions during that period. Together
with the patch this depends on, we accomplish that.

The workflow of snapshot/transaction-before-migration isn't currently
possible.

>> +    ret = migrate_add_blocker(blocker, errp);
>> +    if (ret < 0) {
>> +        goto cleanup_mig;
>> +    }
>>  
>>      QSIMPLEQ_HEAD(snap_bdrv_states, BlkTransactionState) snap_bdrv_states;
>>      QSIMPLEQ_INIT(&snap_bdrv_states);
>> @@ -1814,6 +1823,9 @@ exit:
>>          }
>>          g_free(state);
>>      }
>> + cleanup_mig:
>> +    migrate_del_blocker(blocker);
>> +    error_free(blocker);
> 

Reply via email to