ia64/xen-unstable

changeset 8467:4369fd869f51

Store admin-specified ioport capabilities in a rangeset
rather than a bitmap. arch_do_createdomain() can now
fail and the caller will clean up.

Signed-off-by: Keir Fraser <keir@xensource.com>
author kaf24@firebug.cl.cam.ac.uk
date Sat Dec 31 13:11:47 2005 +0100 (2005-12-31)
parents c0d8e1cf0a63
children d966b7a00959
files xen/arch/ia64/xen/domain.c xen/arch/x86/dom0_ops.c xen/arch/x86/domain.c xen/arch/x86/domain_build.c xen/arch/x86/physdev.c xen/arch/x86/setup.c xen/arch/x86/traps.c xen/common/domain.c xen/common/rangeset.c xen/drivers/char/ns16550.c xen/include/asm-ia64/domain.h xen/include/asm-ia64/iocap.h xen/include/asm-x86/domain.h xen/include/asm-x86/iocap.h xen/include/xen/domain.h xen/include/xen/iocap.h
line diff
     1.1 --- a/xen/arch/ia64/xen/domain.c	Fri Dec 30 17:12:40 2005 +0100
     1.2 +++ b/xen/arch/ia64/xen/domain.c	Sat Dec 31 13:11:47 2005 +0100
     1.3 @@ -181,7 +181,7 @@ static void init_switch_stack(struct vcp
     1.4  	memset(v->arch._thread.fph,0,sizeof(struct ia64_fpreg)*96);
     1.5  }
     1.6  
     1.7 -void arch_do_createdomain(struct vcpu *v)
     1.8 +int arch_do_createdomain(struct vcpu *v)
     1.9  {
    1.10  	struct domain *d = v->domain;
    1.11  	struct thread_info *ti = alloc_thread_info(v);
    1.12 @@ -248,7 +248,9 @@ void arch_do_createdomain(struct vcpu *v
    1.13  		}
    1.14  	} else
    1.15   		d->arch.mm = NULL;
    1.16 - 	printf ("arch_do_create_domain: domain=%p\n", d);
    1.17 +	printf ("arch_do_create_domain: domain=%p\n", d);
    1.18 +
    1.19 +	return 0;
    1.20  }
    1.21  
    1.22  void arch_getdomaininfo_ctxt(struct vcpu *v, struct vcpu_guest_context *c)
     2.1 --- a/xen/arch/x86/dom0_ops.c	Fri Dec 30 17:12:40 2005 +0100
     2.2 +++ b/xen/arch/x86/dom0_ops.c	Sat Dec 31 13:11:47 2005 +0100
     2.3 @@ -17,6 +17,7 @@
     2.4  #include <asm/msr.h>
     2.5  #include <xen/trace.h>
     2.6  #include <xen/console.h>
     2.7 +#include <xen/iocap.h>
     2.8  #include <asm/shadow.h>
     2.9  #include <asm/irq.h>
    2.10  #include <asm/processor.h>
    2.11 @@ -141,7 +142,6 @@ long arch_do_dom0_op(dom0_op_t *op, dom0
    2.12          struct domain *d;
    2.13          unsigned int fp = op->u.ioport_permission.first_port;
    2.14          unsigned int np = op->u.ioport_permission.nr_ports;
    2.15 -        unsigned int p;
    2.16  
    2.17          ret = -EINVAL;
    2.18          if ( (fp + np) > 65536 )
    2.19 @@ -152,25 +152,13 @@ long arch_do_dom0_op(dom0_op_t *op, dom0
    2.20              op->u.ioport_permission.domain)) == NULL) )
    2.21              break;
    2.22  
    2.23 -        ret = -ENOMEM;
    2.24 -        if ( d->arch.iobmp_mask == NULL )
    2.25 -        {
    2.26 -            if ( (d->arch.iobmp_mask = xmalloc_array(
    2.27 -                u8, IOBMP_BYTES)) == NULL )
    2.28 -            {
    2.29 -                put_domain(d);
    2.30 -                break;
    2.31 -            }
    2.32 -            memset(d->arch.iobmp_mask, 0xFF, IOBMP_BYTES);
    2.33 -        }
    2.34 -
    2.35          ret = 0;
    2.36 -        for ( p = fp; p < (fp + np); p++ )
    2.37 +        if ( np > 0 )
    2.38          {
    2.39              if ( op->u.ioport_permission.allow_access )
    2.40 -                clear_bit(p, d->arch.iobmp_mask);
    2.41 +                ioport_range_permit(d, fp, fp + np - 1);
    2.42              else
    2.43 -                set_bit(p, d->arch.iobmp_mask);
    2.44 +                ioport_range_deny(d, fp, fp + np - 1);
    2.45          }
    2.46  
    2.47          put_domain(d);
     3.1 --- a/xen/arch/x86/domain.c	Fri Dec 30 17:12:40 2005 +0100
     3.2 +++ b/xen/arch/x86/domain.c	Sat Dec 31 13:11:47 2005 +0100
     3.3 @@ -20,6 +20,7 @@
     3.4  #include <xen/delay.h>
     3.5  #include <xen/softirq.h>
     3.6  #include <xen/grant_table.h>
     3.7 +#include <xen/iocap.h>
     3.8  #include <asm/regs.h>
     3.9  #include <asm/mc146818rtc.h>
    3.10  #include <asm/system.h>
    3.11 @@ -36,7 +37,6 @@
    3.12  #include <xen/elf.h>
    3.13  #include <asm/vmx.h>
    3.14  #include <asm/msr.h>
    3.15 -#include <asm/physdev.h>
    3.16  #include <xen/kernel.h>
    3.17  #include <xen/multicall.h>
    3.18  
    3.19 @@ -249,21 +249,34 @@ void free_perdomain_pt(struct domain *d)
    3.20  #endif
    3.21  }
    3.22  
    3.23 -void arch_do_createdomain(struct vcpu *v)
    3.24 +int arch_do_createdomain(struct vcpu *v)
    3.25  {
    3.26      struct domain *d = v->domain;
    3.27      l1_pgentry_t gdt_l1e;
    3.28 -    int vcpuid, pdpt_order;
    3.29 +    int vcpuid, pdpt_order, rc;
    3.30  #ifdef __x86_64__
    3.31      int i;
    3.32  #endif
    3.33  
    3.34      if ( is_idle_task(d) )
    3.35 -        return;
    3.36 +        return 0;
    3.37 +
    3.38 +    d->arch.ioport_caps = 
    3.39 +        rangeset_new(d, "I/O Ports", RANGESETF_prettyprint_hex);
    3.40 +    if ( d->arch.ioport_caps == NULL )
    3.41 +        return -ENOMEM;
    3.42 +
    3.43 +    if ( (d->shared_info = alloc_xenheap_page()) == NULL )
    3.44 +        return -ENOMEM;
    3.45 +
    3.46 +    if ( (rc = ptwr_init(d)) != 0 )
    3.47 +    {
    3.48 +        free_xenheap_page(d->shared_info);
    3.49 +        return rc;
    3.50 +    }
    3.51  
    3.52      v->arch.schedule_tail = continue_nonidle_task;
    3.53  
    3.54 -    d->shared_info = alloc_xenheap_page();
    3.55      memset(d->shared_info, 0, PAGE_SIZE);
    3.56      v->vcpu_info = &d->shared_info->vcpu_info[v->vcpu_id];
    3.57      v->cpumap = CPUMAP_RUNANYWHERE;
    3.58 @@ -307,10 +320,10 @@ void arch_do_createdomain(struct vcpu *v
    3.59                              __PAGE_HYPERVISOR);
    3.60  #endif
    3.61  
    3.62 -    (void)ptwr_init(d);
    3.63 -
    3.64      shadow_lock_init(d);
    3.65      INIT_LIST_HEAD(&d->arch.free_shadow_frames);
    3.66 +
    3.67 +    return 0;
    3.68  }
    3.69  
    3.70  void vcpu_migrate_cpu(struct vcpu *v, int newcpu)
    3.71 @@ -954,8 +967,6 @@ void domain_relinquish_resources(struct 
    3.72  
    3.73      BUG_ON(!cpus_empty(d->cpumask));
    3.74  
    3.75 -    physdev_destroy_state(d);
    3.76 -
    3.77      ptwr_destroy(d);
    3.78  
    3.79      /* Drop the in-use references to page-table bases. */
     4.1 --- a/xen/arch/x86/domain_build.c	Fri Dec 30 17:12:40 2005 +0100
     4.2 +++ b/xen/arch/x86/domain_build.c	Sat Dec 31 13:11:47 2005 +0100
     4.3 @@ -16,13 +16,13 @@
     4.4  #include <xen/kernel.h>
     4.5  #include <xen/domain.h>
     4.6  #include <xen/compile.h>
     4.7 +#include <xen/iocap.h>
     4.8  #include <asm/regs.h>
     4.9  #include <asm/system.h>
    4.10  #include <asm/io.h>
    4.11  #include <asm/processor.h>
    4.12  #include <asm/desc.h>
    4.13  #include <asm/i387.h>
    4.14 -#include <asm/physdev.h>
    4.15  #include <asm/shadow.h>
    4.16  
    4.17  static long dom0_nrpages;
    4.18 @@ -96,7 +96,7 @@ static struct pfn_info *alloc_chunk(stru
    4.19  
    4.20  static void process_dom0_ioports_disable()
    4.21  {
    4.22 -    unsigned long io_from, io_to, io_nr;
    4.23 +    unsigned long io_from, io_to;
    4.24      char *t, *u, *s = opt_dom0_ioports_disable;
    4.25  
    4.26      if ( *s == '\0' )
    4.27 @@ -126,8 +126,7 @@ static void process_dom0_ioports_disable
    4.28          printk("Disabling dom0 access to ioport range %04lx-%04lx\n",
    4.29              io_from, io_to);
    4.30  
    4.31 -        io_nr = io_to - io_from + 1;
    4.32 -        physdev_modify_ioport_access_range(dom0, 0, io_from, io_nr);
    4.33 +        ioport_range_deny(dom0, io_from, io_to);
    4.34      }
    4.35  }
    4.36  
    4.37 @@ -183,7 +182,6 @@ int construct_dom0(struct domain *d,
    4.38      /* Machine address of next candidate page-table page. */
    4.39      unsigned long mpt_alloc;
    4.40  
    4.41 -    extern void physdev_init_dom0(struct domain *);
    4.42      extern void translate_l2pgtable(
    4.43          struct domain *d, l1_pgentry_t *p2m, unsigned long l2mfn);
    4.44  
    4.45 @@ -692,9 +690,6 @@ int construct_dom0(struct domain *d,
    4.46      zap_low_mappings(l2start);
    4.47      zap_low_mappings(idle_pg_table_l2);
    4.48  #endif
    4.49 -    
    4.50 -    /* DOM0 gets access to everything. */
    4.51 -    physdev_init_dom0(d);
    4.52  
    4.53      init_domain_time(d);
    4.54  
    4.55 @@ -746,18 +741,22 @@ int construct_dom0(struct domain *d,
    4.56          printk("dom0: shadow setup done\n");
    4.57      }
    4.58  
    4.59 +    /* DOM0 is permitted full I/O capabilities. */
    4.60 +    ioport_range_permit(dom0, 0, 0xFFFF);
    4.61 +    set_bit(_DOMF_physdev_access, &dom0->domain_flags);
    4.62 +
    4.63      /*
    4.64       * Modify I/O port access permissions.
    4.65       */
    4.66      /* Master Interrupt Controller (PIC). */
    4.67 -    physdev_modify_ioport_access_range(dom0, 0, 0x20, 2);
    4.68 +    ioport_range_deny(dom0, 0x20, 0x21);
    4.69      /* Slave Interrupt Controller (PIC). */
    4.70 -    physdev_modify_ioport_access_range(dom0, 0, 0xA0, 2);
    4.71 +    ioport_range_deny(dom0, 0xA0, 0xA1);
    4.72      /* Interval Timer (PIT). */
    4.73 -    physdev_modify_ioport_access_range(dom0, 0, 0x40, 4);
    4.74 +    ioport_range_deny(dom0, 0x40, 0x43);
    4.75      /* PIT Channel 2 / PC Speaker Control. */
    4.76 -    physdev_modify_ioport_access_range(dom0, 0, 0x61, 1);
    4.77 -    /* Command-line passed i/o ranges */
    4.78 +    ioport_range_deny(dom0, 0x61, 0x61);
    4.79 +    /* Command-line I/O ranges. */
    4.80      process_dom0_ioports_disable();
    4.81  
    4.82      return 0;
     5.1 --- a/xen/arch/x86/physdev.c	Fri Dec 30 17:12:40 2005 +0100
     5.2 +++ b/xen/arch/x86/physdev.c	Sat Dec 31 13:11:47 2005 +0100
     5.3 @@ -14,20 +14,6 @@
     5.4  extern int ioapic_guest_read(int apicid, int address, u32 *pval);
     5.5  extern int ioapic_guest_write(int apicid, int address, u32 pval);
     5.6  
     5.7 -void physdev_modify_ioport_access_range(
     5.8 -    struct domain *d, int enable, int port, int num)
     5.9 -{
    5.10 -    int i;
    5.11 -    for ( i = port; i < (port + num); i++ )
    5.12 -        (enable ? clear_bit : set_bit)(i, d->arch.iobmp_mask);
    5.13 -}
    5.14 -
    5.15 -void physdev_destroy_state(struct domain *d)
    5.16 -{
    5.17 -    xfree(d->arch.iobmp_mask);
    5.18 -    d->arch.iobmp_mask = NULL;
    5.19 -}
    5.20 -
    5.21  /* Check if a domain controls a device with IO memory within frame @pfn.
    5.22   * Returns: 1 if the domain should be allowed to map @pfn, 0 otherwise.  */
    5.23  int domain_iomem_in_pfn(struct domain *p, unsigned long pfn)
    5.24 @@ -120,18 +106,6 @@ long do_physdev_op(physdev_op_t *uop)
    5.25      return ret;
    5.26  }
    5.27  
    5.28 -/* Domain 0 has read access to all devices. */
    5.29 -void physdev_init_dom0(struct domain *d)
    5.30 -{
    5.31 -    /* Access to all I/O ports. */
    5.32 -    d->arch.iobmp_mask = xmalloc_array(u8, IOBMP_BYTES);
    5.33 -    BUG_ON(d->arch.iobmp_mask == NULL);
    5.34 -    memset(d->arch.iobmp_mask, 0, IOBMP_BYTES);
    5.35 -
    5.36 -    set_bit(_DOMF_physdev_access, &d->domain_flags);
    5.37 -}
    5.38 -
    5.39 -
    5.40  /*
    5.41   * Local variables:
    5.42   * mode: C
     6.1 --- a/xen/arch/x86/setup.c	Fri Dec 30 17:12:40 2005 +0100
     6.2 +++ b/xen/arch/x86/setup.c	Sat Dec 31 13:11:47 2005 +0100
     6.3 @@ -388,8 +388,9 @@ void __init __start_xen(multiboot_info_t
     6.4  
     6.5      sort_exception_tables();
     6.6  
     6.7 -    arch_do_createdomain(current);
     6.8 -    
     6.9 +    if ( arch_do_createdomain(current) != 0 )
    6.10 +        BUG();
    6.11 +
    6.12      /*
    6.13       * Map default GDT into its final positions in the idle page table. As
    6.14       * noted in arch_do_createdomain(), we must map for every possible VCPU#.
     7.1 --- a/xen/arch/x86/traps.c	Fri Dec 30 17:12:40 2005 +0100
     7.2 +++ b/xen/arch/x86/traps.c	Sat Dec 31 13:11:47 2005 +0100
     7.3 @@ -41,6 +41,7 @@
     7.4  #include <xen/softirq.h>
     7.5  #include <xen/domain_page.h>
     7.6  #include <xen/symbols.h>
     7.7 +#include <xen/iocap.h>
     7.8  #include <asm/shadow.h>
     7.9  #include <asm/system.h>
    7.10  #include <asm/io.h>
    7.11 @@ -622,17 +623,7 @@ static inline int admin_io_okay(
    7.12      unsigned int port, unsigned int bytes,
    7.13      struct vcpu *v, struct cpu_user_regs *regs)
    7.14  {
    7.15 -    struct domain *d = v->domain;
    7.16 -    u16 x;
    7.17 -
    7.18 -    if ( d->arch.iobmp_mask != NULL )
    7.19 -    {
    7.20 -        x = *(u16 *)(d->arch.iobmp_mask + (port >> 3));
    7.21 -        if ( (x & (((1<<bytes)-1) << (port&7))) == 0 )
    7.22 -            return 1;
    7.23 -    }
    7.24 -
    7.25 -    return 0;
    7.26 +    return ioport_range_access_permitted(v->domain, port, port + bytes - 1);
    7.27  }
    7.28  
    7.29  /* Check admin limits. Silently fail the access if it is disallowed. */
     8.1 --- a/xen/common/domain.c	Fri Dec 30 17:12:40 2005 +0100
     8.2 +++ b/xen/common/domain.c	Sat Dec 31 13:11:47 2005 +0100
     8.3 @@ -53,24 +53,16 @@ struct domain *do_createdomain(domid_t d
     8.4  
     8.5      if ( !is_idle_task(d) &&
     8.6           ((evtchn_init(d) != 0) || (grant_table_create(d) != 0)) )
     8.7 -    {
     8.8 -        evtchn_destroy(d);
     8.9 -        free_domain(d);
    8.10 -        return NULL;
    8.11 -    }
    8.12 +        goto fail1;
    8.13      
    8.14      if ( (v = alloc_vcpu(d, 0, cpu)) == NULL )
    8.15 -    {
    8.16 -        grant_table_destroy(d);
    8.17 -        evtchn_destroy(d);
    8.18 -        free_domain(d);
    8.19 -        return NULL;
    8.20 -    }
    8.21 +        goto fail2;
    8.22  
    8.23      rangeset_domain_initialise(d);
    8.24  
    8.25 -    arch_do_createdomain(v);
    8.26 -    
    8.27 +    if ( arch_do_createdomain(v) != 0 )
    8.28 +        goto fail3;
    8.29 +
    8.30      if ( !is_idle_task(d) )
    8.31      {
    8.32          write_lock(&domlist_lock);
    8.33 @@ -86,6 +78,15 @@ struct domain *do_createdomain(domid_t d
    8.34      }
    8.35  
    8.36      return d;
    8.37 +
    8.38 + fail3:
    8.39 +    rangeset_domain_destroy(d);
    8.40 + fail2:
    8.41 +    grant_table_destroy(d);
    8.42 + fail1:
    8.43 +    evtchn_destroy(d);
    8.44 +    free_domain(d);
    8.45 +    return NULL;
    8.46  }
    8.47  
    8.48  
     9.1 --- a/xen/common/rangeset.c	Fri Dec 30 17:12:40 2005 +0100
     9.2 +++ b/xen/common/rangeset.c	Sat Dec 31 13:11:47 2005 +0100
     9.3 @@ -350,7 +350,7 @@ void rangeset_printk(
     9.4  
     9.5      spin_lock(&r->lock);
     9.6  
     9.7 -    printk("%10s {", r->name);
     9.8 +    printk("%-10s {", r->name);
     9.9  
    9.10      for ( x = first_range(r); x != NULL; x = next_range(r, x) )
    9.11      {
    10.1 --- a/xen/drivers/char/ns16550.c	Fri Dec 30 17:12:40 2005 +0100
    10.2 +++ b/xen/drivers/char/ns16550.c	Sat Dec 31 13:11:47 2005 +0100
    10.3 @@ -13,6 +13,7 @@
    10.4  #include <xen/irq.h>
    10.5  #include <xen/sched.h>
    10.6  #include <xen/serial.h>
    10.7 +#include <xen/iocap.h>
    10.8  #include <asm/io.h>
    10.9  
   10.10  /*
   10.11 @@ -233,11 +234,10 @@ static void ns16550_init_postirq(struct 
   10.12  }
   10.13  
   10.14  #ifdef CONFIG_X86
   10.15 -#include <asm/physdev.h>
   10.16  static void ns16550_endboot(struct serial_port *port)
   10.17  {
   10.18      struct ns16550 *uart = port->uart;
   10.19 -    physdev_modify_ioport_access_range(dom0, 0, uart->io_base, 8);
   10.20 +    ioport_range_deny(dom0, uart->io_base, uart->io_base + 7);
   10.21  }
   10.22  #else
   10.23  #define ns16550_endboot NULL
    11.1 --- a/xen/include/asm-ia64/domain.h	Fri Dec 30 17:12:40 2005 +0100
    11.2 +++ b/xen/include/asm-ia64/domain.h	Sat Dec 31 13:11:47 2005 +0100
    11.3 @@ -10,7 +10,7 @@
    11.4  #include <asm/vmx_platform.h>
    11.5  #include <xen/list.h>
    11.6  
    11.7 -extern void arch_do_createdomain(struct vcpu *);
    11.8 +extern int arch_do_createdomain(struct vcpu *);
    11.9  
   11.10  extern void domain_relinquish_resources(struct domain *);
   11.11  
    12.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    12.2 +++ b/xen/include/asm-ia64/iocap.h	Sat Dec 31 13:11:47 2005 +0100
    12.3 @@ -0,0 +1,10 @@
    12.4 +/******************************************************************************
    12.5 + * iocap.h
    12.6 + * 
    12.7 + * Architecture-specific per-domain I/O capabilities.
    12.8 + */
    12.9 +
   12.10 +#ifndef __IA64_IOCAP_H__
   12.11 +#define __IA64_IOCAP_H__
   12.12 +
   12.13 +#endif /* __IA64_IOCAP_H__ */
    13.1 --- a/xen/include/asm-x86/domain.h	Fri Dec 30 17:12:40 2005 +0100
    13.2 +++ b/xen/include/asm-x86/domain.h	Sat Dec 31 13:11:47 2005 +0100
    13.3 @@ -24,8 +24,8 @@ struct arch_domain
    13.4      /* Writable pagetables. */
    13.5      struct ptwr_info ptwr[2];
    13.6  
    13.7 -    /* I/O-port access bitmap mask. */
    13.8 -    u8 *iobmp_mask;       /* Address of IO bitmap mask, or NULL.      */
    13.9 +    /* I/O-port admin-specified access capabilities. */
   13.10 +    struct rangeset *ioport_caps;
   13.11  
   13.12      /* Shadow mode status and controls. */
   13.13      struct shadow_ops *ops;
    14.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    14.2 +++ b/xen/include/asm-x86/iocap.h	Sat Dec 31 13:11:47 2005 +0100
    14.3 @@ -0,0 +1,17 @@
    14.4 +/******************************************************************************
    14.5 + * iocap.h
    14.6 + * 
    14.7 + * Architecture-specific per-domain I/O capabilities.
    14.8 + */
    14.9 +
   14.10 +#ifndef __X86_IOCAP_H__
   14.11 +#define __X86_IOCAP_H__
   14.12 +
   14.13 +#define ioport_range_permit(d, s, e)                    \
   14.14 +    rangeset_add_range((d)->arch.ioport_caps, s, e)
   14.15 +#define ioport_range_deny(d, s, e)                      \
   14.16 +    rangeset_remove_range((d)->arch.ioport_caps, s, e)
   14.17 +#define ioport_range_access_permitted(d, s, e)          \
   14.18 +    rangeset_contains_range((d)->arch.ioport_caps, s, e)
   14.19 +
   14.20 +#endif /* __X86_IOCAP_H__ */
    15.1 --- a/xen/include/asm-x86/physdev.h	Fri Dec 30 17:12:40 2005 +0100
    15.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
    15.3 @@ -1,17 +0,0 @@
    15.4 -/******************************************************************************
    15.5 - * physdev.h
    15.6 - */
    15.7 -
    15.8 -#ifndef __XEN_PHYSDEV_H__
    15.9 -#define __XEN_PHYSDEV_H__
   15.10 -
   15.11 -#include <public/physdev.h>
   15.12 -
   15.13 -void physdev_modify_ioport_access_range(
   15.14 -    struct domain *d, int enable, int port, int num );
   15.15 -void physdev_destroy_state(struct domain *d);
   15.16 -int domain_iomem_in_pfn(struct domain *p, unsigned long pfn);
   15.17 -long do_physdev_op(physdev_op_t *uop);
   15.18 -void physdev_init_dom0(struct domain *d);
   15.19 -
   15.20 -#endif /* __XEN_PHYSDEV_H__ */
    16.1 --- a/xen/include/xen/domain.h	Fri Dec 30 17:12:40 2005 +0100
    16.2 +++ b/xen/include/xen/domain.h	Sat Dec 31 13:11:47 2005 +0100
    16.3 @@ -13,9 +13,9 @@ struct vcpu *alloc_vcpu_struct(struct do
    16.4  
    16.5  extern void free_vcpu_struct(struct vcpu *v);
    16.6  
    16.7 -extern void arch_do_createdomain(struct vcpu *v);
    16.8 +extern int arch_do_createdomain(struct vcpu *v);
    16.9  
   16.10 -extern int  arch_set_info_guest(
   16.11 +extern int arch_set_info_guest(
   16.12      struct vcpu *v, struct vcpu_guest_context *c);
   16.13  
   16.14  extern void vcpu_migrate_cpu(struct vcpu *v, int newcpu);
    17.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    17.2 +++ b/xen/include/xen/iocap.h	Sat Dec 31 13:11:47 2005 +0100
    17.3 @@ -0,0 +1,13 @@
    17.4 +/******************************************************************************
    17.5 + * iocap.h
    17.6 + * 
    17.7 + * Per-domain I/O capabilities.
    17.8 + */
    17.9 +
   17.10 +#ifndef __XEN_IOCAP_H__
   17.11 +#define __XEN_IOCAP_H__
   17.12 +
   17.13 +#include <xen/rangeset.h>
   17.14 +#include <asm/iocap.h>
   17.15 +
   17.16 +#endif /* __XEN_IOCAP_H__ */