1. 01 3月, 2017 1 次提交
  2. 24 2月, 2017 1 次提交
    • K
      block: Attach bs->file only during .bdrv_open() · 4e4bf5c4
      Kevin Wolf 提交于
      The way that attaching bs->file worked was a bit unusual in that it was
      the only child that would be attached to a node which is not opened yet.
      Because of this, the block layer couldn't know yet which permissions the
      driver would eventually need.
      
      This patch moves the point where bs->file is attached to the beginning
      of the individual .bdrv_open() implementations, so drivers already know
      what they are going to do with the child. This is also more consistent
      with how driver-specific children work.
      
      For a moment, bdrv_open() gets its own BdrvChild to perform image
      probing, but instead of directly assigning this BdrvChild to the BDS, it
      becomes a temporary one and the node name is passed as an option to the
      drivers, so that they can simply use bdrv_open_child() to create another
      reference for their own use.
      
      This duplicated child for (the not opened yet) bs is not the final
      state, a follow-up patch will change the image probing code to use a
      BlockBackend, which is completely independent of bs.
      Signed-off-by: NKevin Wolf <kwolf@redhat.com>
      Reviewed-by: NMax Reitz <mreitz@redhat.com>
      4e4bf5c4
  3. 15 11月, 2016 1 次提交
    • J
      blockjob: refactor backup_start as backup_job_create · 111049a4
      John Snow 提交于
      Refactor backup_start as backup_job_create, which only creates the job,
      but does not automatically start it. The old interface, 'backup_start',
      is not kept in favor of limiting the number of nearly-identical interfaces
      that would have to be edited to keep up with QAPI changes in the future.
      
      Callers that wish to synchronously start the backup_block_job can
      instead just call block_job_start immediately after calling
      backup_job_create.
      
      Transactions are updated to use the new interface, calling block_job_start
      only during the .commit phase, which helps prevent race conditions where
      jobs may finish before we even finish building the transaction. This may
      happen, for instance, during empty block backup jobs.
      Reported-by: NVladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
      Signed-off-by: NJohn Snow <jsnow@redhat.com>
      Message-id: 1478587839-9834-6-git-send-email-jsnow@redhat.com
      Signed-off-by: NJeff Cody <jcody@redhat.com>
      111049a4
  4. 01 11月, 2016 1 次提交
  5. 28 10月, 2016 3 次提交
  6. 24 10月, 2016 1 次提交
  7. 13 9月, 2016 1 次提交