[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] RE: [Xen-devel] debug logging in windows
> > > Is there something similar implemented via hvm/qemu that can log via hvm > > log files? That would make life easier. If not, I'll implement it. > There isn't at the moment, at least not in the xenbits repositories. > There is one in the XenServer version of qemu, though. I've attached > the relevant patch. If you apply this and rebuild qemu then you > should be able to send stuff to the qemu logfile by writing bytes to > port 0x12. Note that this is rate limited, though, and if you hit the > limiter the domain will be quite severely punished. > > I've checked that this applies against qemu-xen-unstable.git, and that > the resulting tree at least builds, but I've not actually checked that > it works. Upstream qemu is pretty similar to XenServer qemu at the > moment, though, so it should be okay. > I'd love to see this in 3.3.1... what are the chances? The only change I'd like to make is one that I did in my own version which is to keep separate log buffers per io port (with the intent that each DomU CPU writes to a different port), as I was finding the log messages from different CPU's writing at the same time causing garbled messages. Synchronising access to the io port between different drivers in windows would require a heap of overhead. By making sure in the DomU that each CPU uses port (0x10 + (cpu# & 0x0f)) each CPU only has to disable interrupts on the local CPU while writing the log message. Obviously with #cpu's > 16 you will get some merged log messages, but this would be less of a problem than the mess I was seeing when logging at a high rate. Basically the change is to use the full range of 16 ports, and declare log_buffer[16][4096] and use the port offset from 0x10 as the first index into the array, and obviously index all the other variables that manage the buffer. I also prefix each message with the CPU number (eg '06: '). The throttling would remain global. Having this in 3.3.1 would make it heaps easier to get debug info from people having problems with the GPLPV drivers! I can put my changes in and submit a patch if the above sounds reasonable... Thanks James _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |