[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] Fwd: Mouse Click and Context Switch Question
Hi Thank you very much for your response --- yes we are using full virtualization with a Windows Guest OS -- thanks for pointing out about the qemu-dm On the context switching front, I was wondering if there is a way to leverage the memory information i.e every new process creation should have a new page directory and its own address space associated with it right ?-- so is there a way to use that information to figure out which was the current process ? --- I agree, we would still need application specific information to map the application to the process -- but can the context switching be inferred by the VMM on a process level without asking the guest OS? Thanks again Sujata On 10/13/06, Petersson, Mats <Mats.Petersson@xxxxxxx> wrote: > -----Original Message----- > From: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx > [mailto:xen-devel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of > Sujata Doshi > Sent: 13 October 2006 17:28 > To: xen-devel@xxxxxxxxxxxxxxxxxxx > Subject: [Xen-devel] Fwd: Mouse Click and Context Switch Question > > Hi > I wasn't sure if the email below went through , since I was not > subscribed to the list. Would appreciate your response. > Thanks > Sujata > > ---------- Forwarded message ---------- > From: Sujata Doshi <sujatadoshi@xxxxxxxxx> > Date: Oct 13, 2006 10:37 AM > Subject: Mouse Click and Context Switch Question > To: xen-devel@xxxxxxxxxxxxxxxxxxx > > > Hello > I am starting a research project which involves using Xen. Basically > we would like to monitor the input to an application running in the > guest OS . Specifically, we need to be able to figure out when an > input was made via a mouse click and what the coordinates of the mouse > pointer were on that click. If I understand correctly, on a mouse > click, an interrupt occurs which gets handled by the Xen VMM --- is > there a way of figuring out at the Xen VMM level what the coordinates > of the click are when this interrupt occurs ? You understand correctly on the principle of interrupts, but the actual mouse-movements are tracked in the mouse-handling code inside Linux Dom0, not in the VMM, as the VMM doesn't actually know (or care) anything about the mouse as a device, just about forwarding the interrupt to the rightfull owner. If you know what application you want to track, and you're able to hack some code, I'd suggest that you go modify the X-windows code (such as XFree86) to track where the mouse-clicks are forwarded to the application. Since X-windows knows which application it forwards what information to, it's the "perfect" place to do this [from my understanding of the subject - I could of course be missing some important factor that isn't apparent from the above brief description]. > I understand this would also involve figuring out when a context > switch occurs to that particular application so that we can grab the > right mouse click. Is there an easy way to figure this context switch > out ? The VMM scheduler is not per process but per virtual machine, so the application level would have to be understood by the operating system running on top of Xen, as Xen doesn't actually know what application (if any) is running at any given time, only the Linux kernel (typial case) that is running on top of Xen will know this. > > I would appreciate if you could guide me with the above queries and > also which files in the Xen source I should be looking at to achieve > this task. I could theoretically help you with any Xen-files, but I don't think that's the right approach in the first place - you want to be working further up in the architecture to have access to the "current application". [Note: this is assuming that we're talking about para-virtualized clients. In the case of a full-virtualized guest [HVM, VT/AMD-V], such as a Windows guest, there is a possibility that you could follow the mouse within the qemu-dm [the device model that generates the virtual mouse], and use that information to record where the mouse moves to. However, it's still impossible to understand which application is running at that particular point in time - again, you need to have OS to help you with that]. -- Mats > Thank you very much for your help > Sujata > > _______________________________________________ > Xen-devel mailing list > Xen-devel@xxxxxxxxxxxxxxxxxxx > http://lists.xensource.com/xen-devel > > > _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |