direct-io.hg

changeset 13394:3dcd2664853a

Add scheduler name to 'xm info' output.
Signed-off-by: Masaki Kanno <kanno.masaki@jp.fujitsu.com>
author kfraser@localhost.localdomain
date Wed Jan 17 14:54:06 2007 +0000 (2007-01-17)
parents 84b7639a3bd4
children 13db896ef324
files docs/man/xm.pod.1 tools/python/xen/xend/XendNode.py
line diff
     1.1 --- a/docs/man/xm.pod.1	Wed Jan 17 14:45:00 2007 +0000
     1.2 +++ b/docs/man/xm.pod.1	Wed Jan 17 14:54:06 2007 +0000
     1.3 @@ -451,6 +451,7 @@ make the man page more readable):
     1.4   xen_minor              : 0
     1.5   xen_extra              : -devel
     1.6   xen_caps               : xen-3.0-x86_32
     1.7 + xen_scheduler          : credit
     1.8   xen_pagesize           : 4096
     1.9   platform_params        : virt_start=0xfc000000
    1.10   xen_changeset          : Mon Nov 14 18:13:38 2005 +0100 
    1.11 @@ -460,7 +461,7 @@ make the man page more readable):
    1.12   cc_compile_by          : sdague
    1.13   cc_compile_domain      : (none)
    1.14   cc_compile_date        : Mon Nov 14 14:16:48 EST 2005
    1.15 - xend_config_format     : 2
    1.16 + xend_config_format     : 3
    1.17  
    1.18  B<FIELDS>
    1.19  
     2.1 --- a/tools/python/xen/xend/XendNode.py	Wed Jan 17 14:45:00 2007 +0000
     2.2 +++ b/tools/python/xen/xend/XendNode.py	Wed Jan 17 14:54:06 2007 +0000
     2.3 @@ -365,14 +365,24 @@ class XendNode:
     2.4  
     2.5          return [[k, info[k]] for k in ITEM_ORDER]
     2.6  
     2.7 +    def xenschedinfo(self):
     2.8 +        sched_id = self.xc.sched_id_get()
     2.9 +        if sched_id == xen.lowlevel.xc.XEN_SCHEDULER_SEDF:
    2.10 +            return 'sedf'
    2.11 +        elif sched_id == xen.lowlevel.xc.XEN_SCHEDULER_CREDIT:
    2.12 +            return 'credit'
    2.13 +        else:
    2.14 +            return 'unknown'
    2.15  
    2.16      def xeninfo(self):
    2.17          info = self.xc.xeninfo()
    2.18 +        info['xen_scheduler'] = self.xenschedinfo()
    2.19  
    2.20          ITEM_ORDER = ['xen_major',
    2.21                        'xen_minor',
    2.22                        'xen_extra',
    2.23                        'xen_caps',
    2.24 +                      'xen_scheduler',
    2.25                        'xen_pagesize',
    2.26                        'platform_params',
    2.27                        'xen_changeset',