Added blktap support. Includes kernel driver (enabled as CONFIG_XEN_BLKDEV_TAP=y) and userspace tools. The userspace deamon (blktapctrl) is enabled by default when xend is activated. For further information on using and configuring blktap see tools/blktap/README.

This commit is contained in:
jchesterfield@dhcp92.uk.xensource.com committed 2006-07-13 10:13:26 +01:00
1 parent 0929bd9fc0
commit 0da81aa1d4
133 files changed
+16928 -8

No files matched your search

+2
View File
@@ -1701,6 +1701,7 @@ def addControllerClass(device_class, cls):
from xen.xend.server import blkif, netif, tpmif, pciif, iopif, irqif, usbif
from xen.xend.server.BlktapController import BlktapController
addControllerClass('vbd', blkif.BlkifController)
addControllerClass('vif', netif.NetifController)
addControllerClass('vtpm', tpmif.TPMifController)
@@ -1708,3 +1709,4 @@ addControllerClass('pci', pciif.PciController)
addControllerClass('ioports', iopif.IOPortsController)
addControllerClass('irq', irqif.IRQController)
addControllerClass('usb', usbif.UsbifController)
addControllerClass('tap', BlktapController)
@@ -0,0 +1,14 @@
# Copyright (c) 2005, XenSource Ltd.
from xen.xend.server.blkif import BlkifController
class BlktapController(BlkifController):
def __init__(self, vm):
BlkifController.__init__(self, vm)
def frontendRoot(self):
"""@see DevController#frontendRoot"""
return "%s/device/vbd" % self.vm.getDomainPath()
+7 -1
View File
@@ -479,7 +479,13 @@ def configure_disks(config_devs, vals):
"""Create the config for disks (virtual block devices).
"""
for (uname, dev, mode, backend) in vals.disk:
config_vbd = ['vbd',
if uname.startswith('tap:'):
cls = 'tap'
else:
cls = 'vbd'
config_vbd = [cls,
['uname', uname],
['dev', dev ],
['mode', mode ] ]
+7 -1
View File
@@ -994,7 +994,13 @@ def xm_block_attach(args):
arg_check(args, 'block-attach', 4, 5)
dom = args[0]
vbd = ['vbd',
if args[1].startswith('tap:'):
cls = 'tap'
else:
cls = 'vbd'
vbd = [cls,
['uname', args[1]],
['dev', args[2]],
['mode', args[3]]]
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.