On Fri, Jan 12, 2018 at 02:05:15PM +0800, Peter Xu wrote: > On Mon, Jan 08, 2018 at 05:09:16PM +0000, Stefan Hajnoczi wrote: > > On Tue, Dec 19, 2017 at 04:45:46PM +0800, Peter Xu wrote: > > > > > + */ > > > + bool need_resume; > > > > This isn't really a per-request decision so a QMPRequest field is not > > necessary. If "oob" is enabled then we dispatch commands without > > waiting. If "oob" is disabled then we complete the current command > > before dispatching the next one. > > I explicitly added this to make sure the suspend and resume will be > paired up. Actually there is at least one exception, which is the > initial "qmp_capabilities" command especially when used to enable the > OOB capability. For that case, OOB is not enabled before execution, > while OOB is enabled during the execution and after running the > command. If without this field, monitor can hang.
Good point, your approach avoids bugs. It's safest to leave it as is.
signature.asc
Description: PGP signature