Accepting request 44315 from Virtualization
checked in (request 44315) OBS-URL: https://build.opensuse.org/request/show/44315 OBS-URL: https://build.opensuse.org/package/show/Virtualization/xen?expand=0&rev=70
This commit is contained in:
committed by
Git OBS Bridge
parent
1fbd8d52a6
commit
8198e029dc
@@ -516,7 +516,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendAPI.py
|
||||
except Exception, ex:
|
||||
log.exception(ex)
|
||||
|
||||
@@ -1836,7 +1871,9 @@ class XendAPI(object):
|
||||
@@ -1835,7 +1870,9 @@ class XendAPI(object):
|
||||
'is_control_domain': xeninfo.info['is_control_domain'],
|
||||
'metrics': xeninfo.get_metrics(),
|
||||
'security_label': xeninfo.get_security_label(),
|
||||
@@ -527,7 +527,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendAPI.py
|
||||
}
|
||||
return xen_api_success(record)
|
||||
|
||||
@@ -1934,6 +1971,25 @@ class XendAPI(object):
|
||||
@@ -1933,6 +1970,25 @@ class XendAPI(object):
|
||||
xendom.domain_restore(src, bool(paused))
|
||||
return xen_api_success_void()
|
||||
|
||||
@@ -1465,7 +1465,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendConfig.py
|
||||
===================================================================
|
||||
--- xen-4.0.0-testing.orig/tools/python/xen/xend/XendConfig.py
|
||||
+++ xen-4.0.0-testing/tools/python/xen/xend/XendConfig.py
|
||||
@@ -134,6 +134,7 @@ XENAPI_CFG_TO_LEGACY_CFG = {
|
||||
@@ -128,6 +128,7 @@ XENAPI_CFG_TO_LEGACY_CFG = {
|
||||
'PV_bootloader': 'bootloader',
|
||||
'PV_bootloader_args': 'bootloader_args',
|
||||
'Description': 'description',
|
||||
@@ -1473,7 +1473,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendConfig.py
|
||||
}
|
||||
|
||||
LEGACY_CFG_TO_XENAPI_CFG = reverse_dict(XENAPI_CFG_TO_LEGACY_CFG)
|
||||
@@ -240,6 +241,7 @@ XENAPI_CFG_TYPES = {
|
||||
@@ -234,6 +235,7 @@ XENAPI_CFG_TYPES = {
|
||||
'superpages' : int,
|
||||
'memory_sharing': int,
|
||||
'Description': str,
|
||||
@@ -1481,7 +1481,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendConfig.py
|
||||
}
|
||||
|
||||
# List of legacy configuration keys that have no equivalent in the
|
||||
@@ -285,6 +287,7 @@ LEGACY_CFG_TYPES = {
|
||||
@@ -279,6 +281,7 @@ LEGACY_CFG_TYPES = {
|
||||
'bootloader': str,
|
||||
'bootloader_args': str,
|
||||
'description': str,
|
||||
@@ -1489,7 +1489,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendConfig.py
|
||||
}
|
||||
|
||||
# Values that should be stored in xenstore's /vm/<uuid> that is used
|
||||
@@ -306,6 +309,7 @@ LEGACY_XENSTORE_VM_PARAMS = [
|
||||
@@ -300,6 +303,7 @@ LEGACY_XENSTORE_VM_PARAMS = [
|
||||
'on_xend_stop',
|
||||
'bootloader',
|
||||
'bootloader_args',
|
||||
@@ -1497,7 +1497,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendConfig.py
|
||||
]
|
||||
|
||||
##
|
||||
@@ -414,6 +418,7 @@ class XendConfig(dict):
|
||||
@@ -408,6 +412,7 @@ class XendConfig(dict):
|
||||
'other_config': {},
|
||||
'platform': {},
|
||||
'target': 0,
|
||||
@@ -1530,7 +1530,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendDomainInfo.py
|
||||
from xen.xend.server.DevConstants import xenbusState
|
||||
from xen.xend.server.BlktapController import TAPDISK_DEVICE, parseDeviceString
|
||||
|
||||
@@ -2569,6 +2570,19 @@ class XendDomainInfo:
|
||||
@@ -2565,6 +2566,19 @@ class XendDomainInfo:
|
||||
oos = self.info['platform'].get('oos', 1)
|
||||
oos_off = 1 - int(oos)
|
||||
|
||||
@@ -1550,7 +1550,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendDomainInfo.py
|
||||
flags = (int(hvm) << 0) | (int(hap) << 1) | (int(s3_integrity) << 2) | (int(oos_off) << 3)
|
||||
|
||||
try:
|
||||
@@ -2590,6 +2604,11 @@ class XendDomainInfo:
|
||||
@@ -2586,6 +2600,11 @@ class XendDomainInfo:
|
||||
failmsg += ', error=%i' % int(self.domid)
|
||||
raise VmError(failmsg)
|
||||
|
||||
@@ -1562,7 +1562,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendDomainInfo.py
|
||||
self.dompath = GetDomainPath(self.domid)
|
||||
|
||||
self._recreateDom()
|
||||
@@ -3617,6 +3636,11 @@ class XendDomainInfo:
|
||||
@@ -3613,6 +3632,11 @@ class XendDomainInfo:
|
||||
|
||||
retval = xc.sched_credit_domain_get(self.getDomid())
|
||||
return retval
|
||||
@@ -1634,7 +1634,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendNode.py
|
||||
|
||||
def _init_networks(self):
|
||||
# Initialise networks
|
||||
@@ -366,6 +369,18 @@ class XendNode:
|
||||
@@ -361,6 +364,18 @@ class XendNode:
|
||||
for physical_host, pscsi_HBA_uuid in pscsi_HBA_table.items():
|
||||
XendPSCSI_HBA(pscsi_HBA_uuid, {'physical_host': physical_host})
|
||||
|
||||
@@ -1653,7 +1653,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendNode.py
|
||||
|
||||
def add_network(self, interface):
|
||||
# TODO
|
||||
@@ -586,6 +601,7 @@ class XendNode:
|
||||
@@ -581,6 +596,7 @@ class XendNode:
|
||||
self.save_PPCIs()
|
||||
self.save_PSCSIs()
|
||||
self.save_PSCSI_HBAs()
|
||||
@@ -1661,7 +1661,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendNode.py
|
||||
|
||||
def save_PIFs(self):
|
||||
pif_records = dict([(pif_uuid, XendAPIStore.get(
|
||||
@@ -628,6 +644,12 @@ class XendNode:
|
||||
@@ -623,6 +639,12 @@ class XendNode:
|
||||
for pscsi_HBA_uuid in XendPSCSI_HBA.get_all()])
|
||||
self.state_store.save_state('pscsi_HBA', pscsi_HBA_records)
|
||||
|
||||
@@ -1674,7 +1674,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendNode.py
|
||||
def shutdown(self):
|
||||
return 0
|
||||
|
||||
@@ -939,6 +961,7 @@ class XendNode:
|
||||
@@ -934,6 +956,7 @@ class XendNode:
|
||||
self.format_node_to_memory(info, 'node_to_memory')
|
||||
info['node_to_dma32_mem'] = \
|
||||
self.format_node_to_memory(info, 'node_to_dma32_mem')
|
||||
@@ -1682,7 +1682,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xend/XendNode.py
|
||||
|
||||
# FIXME: These are hard-coded to be the inverse of the getXenMemory
|
||||
# functions in image.py. Find a cleaner way.
|
||||
@@ -958,6 +981,7 @@ class XendNode:
|
||||
@@ -953,6 +976,7 @@ class XendNode:
|
||||
'virt_caps',
|
||||
'total_memory',
|
||||
'free_memory',
|
||||
@@ -1798,7 +1798,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
from xen.util import auxbin
|
||||
|
||||
import XenAPI
|
||||
@@ -237,6 +238,23 @@ SUBCOMMAND_HELP = {
|
||||
@@ -235,6 +236,23 @@ SUBCOMMAND_HELP = {
|
||||
'tmem-freeable' : ('', 'Print freeable tmem (in MiB).'),
|
||||
'tmem-shared-auth' : ('[<Domain>|-a|--all] [--uuid=<uuid>] [--auth=<0|1>]', 'De/authenticate shared tmem pool.'),
|
||||
|
||||
@@ -1822,7 +1822,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
# security
|
||||
|
||||
'addlabel' : ('<label> {dom <ConfigFile>|res <resource>|mgt <managed domain>} [<policy>]',
|
||||
@@ -283,6 +301,7 @@ SUBCOMMAND_OPTIONS = {
|
||||
@@ -281,6 +299,7 @@ SUBCOMMAND_OPTIONS = {
|
||||
('-l', '--long', 'Output all VM details in SXP'),
|
||||
('', '--label', 'Include security labels'),
|
||||
('', '--state=<state>', 'Select only VMs with the specified state'),
|
||||
@@ -1830,7 +1830,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
),
|
||||
'console': (
|
||||
('-q', '--quiet', 'Do not print an error message if the domain does not exist'),
|
||||
@@ -344,6 +363,10 @@ SUBCOMMAND_OPTIONS = {
|
||||
@@ -342,6 +361,10 @@ SUBCOMMAND_OPTIONS = {
|
||||
('-u', '--uuid', 'Specify uuid (abcdef01-2345-6789-01234567890abcdef).'),
|
||||
('-A', '--auth', '0=auth,1=deauth'),
|
||||
),
|
||||
@@ -1841,7 +1841,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
}
|
||||
|
||||
common_commands = [
|
||||
@@ -490,9 +513,21 @@ tmem_commands = [
|
||||
@@ -486,9 +509,21 @@ tmem_commands = [
|
||||
"tmem-shared-auth",
|
||||
]
|
||||
|
||||
@@ -1864,7 +1864,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
['shell', 'event-monitor'])
|
||||
|
||||
|
||||
@@ -889,7 +924,7 @@ def datetime_to_secs(v):
|
||||
@@ -885,7 +920,7 @@ def datetime_to_secs(v):
|
||||
v = str(v).replace(c, "")
|
||||
return time.mktime(time.strptime(v[0:14], '%Y%m%dT%H%M%S'))
|
||||
|
||||
@@ -1873,7 +1873,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
if serverType == SERVER_XEN_API:
|
||||
doms_sxp = []
|
||||
doms_dict = []
|
||||
@@ -898,6 +933,9 @@ def getDomains(domain_names, state, full
|
||||
@@ -894,6 +929,9 @@ def getDomains(domain_names, state, full
|
||||
dom_metrics_recs = server.xenapi.VM_metrics.get_all_records()
|
||||
|
||||
for dom_ref, dom_rec in dom_recs.items():
|
||||
@@ -1883,7 +1883,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
dom_metrics_rec = dom_metrics_recs[dom_rec['metrics']]
|
||||
|
||||
states = ('running', 'blocked', 'paused', 'shutdown',
|
||||
@@ -937,7 +975,15 @@ def getDomains(domain_names, state, full
|
||||
@@ -934,7 +972,15 @@ def getDomains(domain_names, state, full
|
||||
if domain_names:
|
||||
return [server.xend.domain(dom, full) for dom in domain_names]
|
||||
else:
|
||||
@@ -1900,7 +1900,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
|
||||
|
||||
def xm_list(args):
|
||||
@@ -945,10 +991,11 @@ def xm_list(args):
|
||||
@@ -942,10 +988,11 @@ def xm_list(args):
|
||||
show_vcpus = 0
|
||||
show_labels = 0
|
||||
state = 'all'
|
||||
@@ -1913,7 +1913,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
except getopt.GetoptError, opterr:
|
||||
err(opterr)
|
||||
usage('list')
|
||||
@@ -962,18 +1009,24 @@ def xm_list(args):
|
||||
@@ -959,18 +1006,24 @@ def xm_list(args):
|
||||
show_labels = 1
|
||||
if k in ['--state']:
|
||||
state = v
|
||||
@@ -1939,7 +1939,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
|
||||
if use_long:
|
||||
map(PrettyPrint.prettyprint, doms)
|
||||
@@ -1839,6 +1892,13 @@ def xm_info(args):
|
||||
@@ -1806,6 +1859,13 @@ def xm_info(args):
|
||||
else:
|
||||
return ""
|
||||
|
||||
@@ -1953,7 +1953,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
info = {
|
||||
"host": getVal(["name_label"]),
|
||||
"release": getVal(["software_version", "release"]),
|
||||
@@ -1850,6 +1910,7 @@ def xm_info(args):
|
||||
@@ -1817,6 +1877,7 @@ def xm_info(args):
|
||||
"threads_per_core": getVal(["cpu_configuration", "threads_per_core"]),
|
||||
"cpu_mhz": getCpuMhz(),
|
||||
"hw_caps": getCpuFeatures(),
|
||||
@@ -1961,7 +1961,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
"total_memory": int(host_metrics_record["memory_total"])/1024/1024,
|
||||
"free_memory": int(host_metrics_record["memory_free"])/1024/1024,
|
||||
"xen_major": getVal(["software_version", "xen_major"]),
|
||||
@@ -3484,6 +3545,169 @@ def xm_tmem_shared_auth(args):
|
||||
@@ -3451,6 +3512,169 @@ def xm_tmem_shared_auth(args):
|
||||
else:
|
||||
return server.xend.node.tmem_shared_auth(domid,uuid_str,auth)
|
||||
|
||||
@@ -2131,7 +2131,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
|
||||
commands = {
|
||||
"shell": xm_shell,
|
||||
@@ -3569,6 +3793,14 @@ commands = {
|
||||
@@ -3536,6 +3760,14 @@ commands = {
|
||||
"usb-list-assignable-devices": xm_usb_list_assignable_devices,
|
||||
"usb-hc-create": xm_usb_hc_create,
|
||||
"usb-hc-destroy": xm_usb_hc_destroy,
|
||||
@@ -2146,7 +2146,7 @@ Index: xen-4.0.0-testing/tools/python/xen/xm/main.py
|
||||
# tmem
|
||||
"tmem-thaw": xm_tmem_thaw,
|
||||
"tmem-freeze": xm_tmem_freeze,
|
||||
@@ -3602,6 +3834,8 @@ IMPORTED_COMMANDS = [
|
||||
@@ -3567,6 +3799,8 @@ IMPORTED_COMMANDS = [
|
||||
'resetpolicy',
|
||||
'getenforce',
|
||||
'setenforce',
|
||||
|
Reference in New Issue
Block a user