Paolo Bonzini <pbonz...@redhat.com> writes: > Il 21/02/2013 18:25, Anthony Liguori ha scritto: >>> > >>> > What would be more problematic is the chardev flow control patches, >>> > which use the glib main loop directly. I don't recall your KVM forum >>> > presentation---did you need RT prioritization of the serial port too? >> It uses GSources which don't need a full glib main loop. We just need >> to be able to support glib event dispatch from whatever our main loop >> is. > > The lock in g_main_context_{prepare,query,check,dispatch} is not > RT-friendly. We could have contention on that lock between the iothread > and the VCPU thread.
Since I assume we'll have multiple I/O threads by then, I also assume that we'll run RT events on one or more dedicated I/O thread that only handles RT events. In terms of attaching events to I/O threads, it's pretty simple to delay the GSource attach to a bottom half on a non-RT I/O thread if the VCPU needs to add a glib based event. Regards, Anthony Liguori > > Paolo > >> I would assume that we'd treat any glib event with the same priority if >> we ever had a RT-iothread.