job-manual-start-v2
jnsnow
tagged this
30 Sep 22:00
There are a few problems with transactional job completion right now. First, if jobs complete so quickly they complete before remaining jobs get a chance to join the transaction, the completion mode can leave well known state and the QLIST can get corrupted and the transactional jobs can complete in batches or phases instead of all together. Second, if two or more jobs defer to the main loop at roughly the same time, it's possible for one job's cleanup to directly invoke the other job's cleanup from within the same thread, leading to a situation that will deadlock the entire transaction. Thanks to Vladimir for pointing out these modes of failure. This series also does a little digging into refactoring Jobs into public and private interfaces. It's somewhat unrelated, but it was easier to include this with this series than separate it out and send it later. This comprises patches 2-6. The actual fixes here are in patches 1 and 7-10. A new test to catch Vladimir's failure scenario is in patch 11. v2: - Lots of differences in patches 2-9. - Cancel should now work on an "unstarted" blockjob. - New refactoring patches. - Added "start" property for BlockJob Drivers. ________________________________________________________________________________ For convenience, this branch is available at: https://github.com/jnsnow/qemu.git branch job-manual-start https://github.com/jnsnow/qemu/tree/job-manual-start This version is tagged job-manual-start-v2: https://github.com/jnsnow/qemu/releases/tag/job-manual-start-v2
Assets 2
-
2016-09-30T22:00:34Z -
2016-09-30T22:00:34Z -