[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [win-pv-devel] Porting libvchan to use the Windows PV Drivers



> -----Original Message-----
> From: win-pv-devel-bounces@xxxxxxxxxxxxxxxxxxxx [mailto:win-pv-devel-
> bounces@xxxxxxxxxxxxxxxxxxxx] On Behalf Of Christian Refvik
> Sent: 27 January 2015 03:02
> To: win-pv-devel@xxxxxxxxxxxxxxxxxxxx
> Cc: xen-devel@xxxxxxxxxxxxxxxxxxxx
> Subject: [win-pv-devel] Porting libvchan to use the Windows PV Drivers
> 
> Hi guys,
> 
> I'm a new Xen developer.  However, I've been looking at porting the libvchan
> library so that it uses the Windows PV Drivers that are currently checked in.

Hi,

  I think that would be a great idea.

> As far as libvchan is concerned, (I think) I understand it fairly well.  I've 
> even
> started to create some documentation which I'm happy to post on the Xen
> wiki.
> 
> From what I see, the libvchan basically relies on xenstore and libxc 
> (XenCtrl).
> The Windows PV drivers have the xeniface package contains the code used
> to access XenStore through XenBus.

Currently the most functional interface to xenstore through XENIFACE is via 
WMI. WMI is very painful to use from anything other than .NET so I suspect it 
would need a more functional IOCTL based interface as a start.

>   I'm not sure about the equivalent of
> libxc, but most of the functionality looks like it lives in the xenbus 
> package.
> The issue seems like libxc allows user space applications to make calls to the
> hypervisor using the devices privcmd, evtchn, and gntalloc.  I don't know how
> this should work on Windows, since the device driver structure is different
> than Linux.
> 

Continuing from above, I think IOCTL based interfaces (set up with 
IoRegisterDeviceInterface) in XENIFACE would be the way to go. XENBUS does 
contain the kernel implementations but I think XENIFACE is the right place to 
surface them to user space.

> 1.  Where should I start looking in the Windows PV side to get more familiar?

The best way to started is to get hold of source for each driver, build it and 
install it yourself. If you create debug builds then you should see a 
substantial amount of logging (via DbgPrint) so attaching a debugger to the VM 
is also a good idea.

> 2.  Where is there some documentation on how can I use the Windows PV
> drivers to build my own custom drivers on top of the Windows PV interfaces?

There's not much in the way of documentation. Each of the interface headers 
does contain some doxygen tagging though and there is a script in the repos to 
generate docs from these. 

> 3.  How should I correctly port libvchan to Windows?  Should libvchan be a
> new type of driver that might uses xen.sys directly?  Its not clear to me keep
> a high bandwidth and still get the best latency.
> 

As I said above, I think XENIFACE is the right place to do the coding. The 
libvchan equivalent should IMO be a Win32 DLL that is layered on the interfaces 
exposed by XENIFACE.

  Paul

> Any suggestions and help is appreciated.
> 
> Thanks,
> Christian
> 
> 
> _______________________________________________
> win-pv-devel mailing list
> win-pv-devel@xxxxxxxxxxxxxxxxxxxx
> http://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel

_______________________________________________
win-pv-devel mailing list
win-pv-devel@xxxxxxxxxxxxxxxxxxxx
http://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.