Skip to content

Commit 6361838

Browse files
author
Paul Durrant
committed
New README.md and INSTALL.md.
Signed-off-by: Paul Durrant <[email protected]>
1 parent 3b4bdca commit 6361838

File tree

4 files changed

+104
-102
lines changed

4 files changed

+104
-102
lines changed

INSTALL.md

+25-11
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,26 @@
1-
To install the XenServer Interface Device Driver onto a XenServer Windows
2-
guest VM:
3-
4-
* Copy xeniface.sys and xeniface.inf onto the guest VM
5-
* Install xenbus.sys on the guest VM
6-
* Copy dpinst.exe from the Windows driver kit into the same folder as
7-
xeniface.sys and xeniface.inf on the guest vm, ensuring the version
8-
of dpinst.exe matches the architecture of the verison of Windows
9-
installed on your VM
10-
* As administrator, run dpinst.exe on the guest vm
11-
* If any warnings arise about unknown certificates, accept them
1+
Installing XenIface
2+
===================
123

4+
It's important to note that the build scripts generate a driver which is
5+
*test signed*. This means that when the driver is installed on a 64-bit
6+
version of Windows you must enabled testsigning mode otherwise your system
7+
will fail signature verification checked on the next reboot.
8+
If you wish to install the test certificate on the target system then copy
9+
xeniface.pfx (which you'll find in he proj subdirectory) onto your system and
10+
use certmgr to install it. (It is not password protected).
11+
12+
xeniface.sys binds to one of three devices which may be created by XenBus:
13+
14+
1. XENBUS\\VEN_XSC000&DEV_IFACE&REV_00000001
15+
2. XENBUS\\VEN_XS0001&DEV_IFACE&REV_00000001
16+
3. XENBUS\\VEN_XS0002&DEV_IFACE&REV_00000001
17+
18+
The particular device present in your VM will be determined by the binding
19+
of the XenBus driver. The DeviceID of the PCI device to which it is bound is
20+
echoed in the VEN_ substring of the devices it creates. Hence only one of the
21+
above three variants will be present.
22+
23+
To install the driver on your target system, copy the contents of the xeniface
24+
subdirectory onto the system, then navigate into the copy, to either the x86
25+
or x64 subdirectory (whichever is appropriate), and execute the copy of
26+
dpinst.exe you find there with Administrator privilege.

MAINTAINERS

+9-13
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,20 @@
11
List of maintainers and how to submit changes
22
=============================================
33

4-
This is an early public release of the XenServer XenIface driver.
4+
If you wish to submit code, we recommend first reaching out to the maintainers,
5+
who will advise you on the precise procedure they wish to use.
56

6-
At the moment we are working hard on improving this early release, to make
7-
it easier to build and install and test on your own systems. As such things
8-
are in a state of flux, and we may well find it difficult to take submissions.
7+
We also request you follow these basic guidelines:
98

10-
We hope things will have improved by January 2014
9+
1. Make sure you test your changes on both 32- and 64-bit versions of Windows.
1110

12-
If you do wish to submit code, we recommend reaching out to the maintainers
13-
first, who will attempt to steer you in the right direction.
11+
2. Make sure your changes do not introduce any new prefast warnings.
1412

15-
We also request you follow these guidelines:
16-
17-
1. All submissions must be made under the terms of the "Developer's Certificate
13+
3. All submissions must be made under the terms of the "Developer's Certificate
1814
of Origin" (DC) and should include a Signed-off-by: line.
1915

2016
2. All Submissions should use Unix line endings for consitency with the rest of
21-
the XenServer project
17+
the XenServer project.
2218

2319
3. Each patch should include a descriptive commit comment that helps understand
2420
why the patch is necessary and why it works. This will be used both for
@@ -32,9 +28,9 @@ We also request you follow these guidelines:
3228
Maintainers List
3329
----------------
3430

35-
* Ben Chalmers <[email protected]>
36-
3731
* Paul Durrant <[email protected]>
3832

33+
* Ben Chalmers <[email protected]>
34+
3935
* Owen Smith <[email protected]>
4036

README.md

+53-37
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,74 @@
1-
XenIface - The XenServer Interface Device Driver
2-
==========================================
1+
XenIface - The XenServer Interface Driver for Windows
2+
=====================================================
33

4-
XenIface is a device driver which provides userlevel applications WMI and Ioctl
5-
read and write access to information provided to the guest domain by
6-
xenstore and xapi
4+
The XenIface package consists of a single device driver:
75

8-
Quick Start
9-
===========
6+
* xeniface.sys is a driver which attaches to a virtual device created
7+
by XenBus (see https://github.com/xenserver/win-xenbus) and provides
8+
a WMI to xenstore (and also an IOCTL interface for simple xenstore
9+
read/write access).
1010

11-
Prerequisites to build
12-
----------------------
11+
Quick Start Guide
12+
=================
1313

14-
* Visual Studio 2012 or later
15-
* Windows Driver Kit 8 or later
16-
* Python 3 or later
14+
Building the driver
15+
-------------------
1716

18-
Environment variables used in building driver
19-
-----------------------------
17+
First you'll need a device driver build environment for Windows 8. For this
18+
you must use:
2019

21-
MAJOR\_VERSION Major version number
20+
* Visual Studio 2012 (Professional or Ultimate)
21+
* Windows Driver Kit 8
2222

23-
MINOR\_VERSION Minor version number
23+
(See http://msdn.microsoft.com/en-us/windows/hardware/hh852365.aspx). You
24+
may find it useful to install VirtualCloneDrive from http://www.slysoft.com
25+
as Visual Studio is generally supplied in ISO form.
2426

25-
MICRO\_VERSION Micro version number
27+
Install Visual Studio first (you only need install MFC for C++) and then
28+
the WDK. Set an environment variable called VS to the base of the Visual
29+
Studio Installation (e.g. C:\Program Files\Microsoft Visual Studio 11.0) and
30+
a variable called KIT to the base of the WDK
31+
(e.g. C:\Program Files\Windows Kits\8.0). Also set an environment variable
32+
called SYMBOL\_SERVER to point at a location where driver symbols can be
33+
stored. This can be local directory e.g. C:\Symbols.
2634

27-
BUILD\_NUMBER Build number
35+
Next you'll need a 3.x version of python (which you can get from
36+
http://www.python.org). Make sure python.exe is somewhere on your default
37+
path.
2838

29-
SYMBOL\_SERVER location of a writable symbol server directory
39+
Now fire up a Command Prompt and navigate to the base of your git repository.
40+
At the prompt type:
3041

31-
KIT location of the Windows driver kit
42+
build.py checked
3243

33-
PROCESSOR\_ARCHITECTURE x86 or x64
44+
This will create a debug build of the driver. To create a non-debug build
45+
type:
3446

35-
VS location of visual studio
47+
build.py free
3648

37-
Commands to build
38-
-----------------
49+
Installing the driver
50+
---------------------
3951

40-
git clone http://github.com/xenserver/win-xeniface
41-
cd win-xeniface
42-
.\\build.py [checked | free]
52+
See INSTALL.md
4353

54+
Miscellaneous
55+
=============
4456

45-
Device tree diagram
46-
-------------------
57+
For convenience the source repository includes some other scripts:
58+
59+
kdfiles.py
60+
----------
61+
62+
This generates two files called kdfiles32.txt and kdfiles64.txt which can
63+
be used as map files for the .kdfiles WinDBG command.
4764

48-
XenIface
49-
|
50-
XenBus
51-
|
52-
PCI Bus
65+
sdv.py
66+
------
5367

54-
See Also
55-
========
68+
This runs Static Driver Verifier on the source.
5669

57-
win-xeniface\WmiDocumentation.txt for documentation of the WMI interface
70+
clean.py
71+
--------
5872

73+
This removes any files not checked into the repository and not covered by
74+
the .gitignore file.

clean.py

+17-41
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,21 @@
11
#!/usr/bin/env python
22

3-
# Copyright (c) Citrix Systems Inc.
4-
# All rights reserved.
5-
#
6-
# Redistribution and use in source and binary forms,
7-
# with or without modification, are permitted provided
8-
# that the following conditions are met:
9-
#
10-
# * Redistributions of source code must retain the above
11-
# copyright notice, this list of conditions and the
12-
# following disclaimer.
13-
# * Redistributions in binary form must reproduce the above
14-
# copyright notice, this list of conditions and the
15-
# following disclaimer in the documentation and/or other
16-
# materials provided with the distribution.
17-
#
18-
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
19-
# CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
20-
# INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
21-
# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
22-
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
23-
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
24-
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
25-
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
26-
# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27-
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28-
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
29-
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30-
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31-
# SUCH DAMAGE.
3+
import os, sys, shutil
324

5+
if __name__ == '__main__':
6+
file = os.popen('git status -u --porcelain')
337

34-
import os, sys
35-
36-
file = os.popen('git status --untracked-files --short')
37-
38-
for line in file:
39-
item = line.split(' ')
40-
if item[0] == '??':
41-
path = ' '.join(item[1:]).rstrip()
42-
print(path)
43-
os.remove(path)
44-
45-
file.close()
8+
for line in file:
9+
item = line.split(' ')
10+
if item[0] == '??':
11+
path = ' '.join(item[1:]).rstrip()
12+
print(path)
13+
try:
14+
if os.path.isfile(path):
15+
os.remove(path)
16+
if os.path.isdir(path):
17+
shutil.rmtree(path)
18+
except OSError:
19+
None
20+
21+
file.close()

0 commit comments

Comments
 (0)