ia64/xen-unstable

changeset 3966:0b9ff7354a95

bitkeeper revision 1.1236.1.47 (4225ff68LvKUt73k78dKjnXxsnQt7A)

Fix tools build. Clean up barrier defs.
Signed-off-by: Jerone Young <jyoung5@us.ibm.com>
Signed-off-by: Keir Fraser <keir.fraser@cl.cam.ac.uk>
author kaf24@scramble.cl.cam.ac.uk
date Wed Mar 02 18:01:12 2005 +0000 (2005-03-02)
parents f16176a68244
children c00d1876f1ac
files tools/blktap/blktaplib.h tools/libxc/xc.h
line diff
     1.1 --- a/tools/blktap/blktaplib.h	Wed Mar 02 17:53:54 2005 +0000
     1.2 +++ b/tools/blktap/blktaplib.h	Wed Mar 02 18:01:12 2005 +0000
     1.3 @@ -8,8 +8,7 @@
     1.4  #ifndef __BLKTAPLIB_H__
     1.5  #define __BLKTAPLIB_H__
     1.6  
     1.7 -#include <stdint.h>
     1.8 -
     1.9 +#include <xc.h>
    1.10  #include <sys/user.h>
    1.11  #include <xen/xen.h>
    1.12  #include <xen/io/blkif.h>
     2.1 --- a/tools/libxc/xc.h	Wed Mar 02 17:53:54 2005 +0000
     2.2 +++ b/tools/libxc/xc.h	Wed Mar 02 18:01:12 2005 +0000
     2.3 @@ -25,18 +25,18 @@ typedef int64_t            s64;
     2.4  #include <xen/event_channel.h>
     2.5  #include <xen/sched_ctl.h>
     2.6  
     2.7 -
     2.8  /*
     2.9   *  DEFINITIONS FOR CPU BARRIERS
    2.10   */ 
    2.11  
    2.12  #if defined(__i386__)
    2.13 -#define rmb() __asm__ __volatile__ ("lock; addl $0,0(%%esp)" : : : "memory")
    2.14 -#define wmb() __asm__ __volatile__ ("" : : : "memory")
    2.15 +#define mb()  __asm__ __volatile__ ( "lock; addl $0,0(%%esp)" : : : "memory" )
    2.16 +#define rmb() __asm__ __volatile__ ( "lock; addl $0,0(%%esp)" : : : "memory" )
    2.17 +#define wmb() __asm__ __volatile__ ( "" : : : "memory")
    2.18  #elif defined(__x86_64__)
    2.19 -#define mb()     asm volatile("mfence":::"memory")
    2.20 -#define rmb()    asm volatile("lfence":::"memory")
    2.21 -#define wmb()    asm volatile( "" :::"memory")
    2.22 +#define mb()  __asm__ __volatile__ ( "mfence" : : : "memory")
    2.23 +#define rmb() __asm__ __volatile__ ( "lfence" : : : "memory")
    2.24 +#define wmb() __asm__ __volatile__ ( "" : : : "memory")
    2.25  #else
    2.26  #error "Define barriers"
    2.27  #endif