|
|
|
|
|
|
|
|
|
|
xen-changelog
[Xen-changelog] [xen-unstable] [XEND] Re-add vtpm device support in Xend
# HG changeset patch
# User Alastair Tse <atse@xxxxxxxxxxxxx>
# Node ID 98413fa7826c2b83a592fe25974c07208112e0d0
# Parent 4b577c1909a9c988210b759a79633d6560e96dc6
[XEND] Re-add vtpm device support in XendConfig
This patch re-adds a recently removed vTPM device handling code.
I am also removing that one code part in the test script that does not
work.
Signed-off-by: Stefan Berger <stefanb@xxxxxxxxxx>
---
tools/python/scripts/xapi.py | 2 --
tools/python/xen/xend/XendConfig.py | 12 +++++++++++-
2 files changed, 11 insertions(+), 3 deletions(-)
diff -r 4b577c1909a9 -r 98413fa7826c tools/python/scripts/xapi.py
--- a/tools/python/scripts/xapi.py Fri Dec 01 17:31:50 2006 +0000
+++ b/tools/python/scripts/xapi.py Fri Dec 01 17:37:42 2006 +0000
@@ -446,8 +446,6 @@ def xapi_vtpm_create(*args):
print "Has driver type '%s'" % driver
vtpm_rec = execute(server.VTPM.get_record, session, vtpm_uuid)
print "Has vtpm record '%s'" % vtpm_rec
- vm = execute(server.VTPM.get_VM, session, vtpm_uuid)
- print "Has VM '%s'" % vm
#
diff -r 4b577c1909a9 -r 98413fa7826c tools/python/xen/xend/XendConfig.py
--- a/tools/python/xen/xend/XendConfig.py Fri Dec 01 17:31:50 2006 +0000
+++ b/tools/python/xen/xend/XendConfig.py Fri Dec 01 17:37:42 2006 +0000
@@ -945,7 +945,17 @@ class XendConfig(dict):
self['devices'][dev_uuid] = (dev_type, dev_info)
self['vbd_refs'].append(dev_uuid)
return dev_uuid
-
+
+ elif dev_type in ('vtpm'):
+ if cfg_xenapi.get('type'):
+ dev_info['type'] = cfg_xenapi.get('type')
+
+ dev_uuid = cfg_xenapi.get('uuid', uuid.createString())
+ dev_info['uuid'] = dev_uuid
+ self['devices'][dev_uuid] = (dev_type, dev_info)
+ self['vtpm_refs'].append(dev_uuid)
+ return dev_uuid
+
return ''
def device_update(self, dev_uuid, cfg_sxp):
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-changelog] [xen-unstable] [XEND] Re-add vtpm device support in XendConfig,
Xen patchbot-unstable <=
|
|
|
|
|