On Mon, 12/12 13:27, Liviu Ionescu wrote: > > > On 12 Dec 2016, at 12:36, Fam Zheng <f...@redhat.com> wrote: > > > > an EventNotifier in the main thread which is notified by the vCPU > > thread upon a new graphics operation? > > the idea of using notifications is ok, but I could not figure out what api to > use to implement it. can you provide more details?
Take a look at event_notifier_set_handler() and event_notifier_set(). Or alternatively (whichever works better for you, I don't know): qemu_bh_new() and qemu_bh_schedule(). Both can register a callback that will be called in main loop once fired. Fam