ia64/xen-unstable

changeset 3563:25f3f22927e9

bitkeeper revision 1.1159.1.539 (41f925edsOM-7RHXmwoPRFfYwoxtEw)

Merge tempest.cl.cam.ac.uk:/auto/groups/xeno-xenod/BK/xeno.bk
into tempest.cl.cam.ac.uk:/local/scratch/smh22/xen-unstable.bk
author smh22@tempest.cl.cam.ac.uk
date Thu Jan 27 17:33:33 2005 +0000 (2005-01-27)
parents 08e173bd9db1 de9af8f0cdf1
children bc0fbb38cb25
files .rootkeys Makefile install.sh tools/Make.defs tools/Rules.mk tools/libxc/Makefile tools/libxutil/Makefile tools/misc/Makefile tools/python/Makefile tools/python/xen/lowlevel/xu/xu.c tools/vnet/vnet-module/Makefile-2.4 tools/vnet/vnetd/Makefile tools/x2d2/Makefile tools/xcs/Makefile tools/xentrace/Makefile tools/xfrd/Makefile xen/Rules.mk
line diff
     1.1 --- a/.rootkeys	Wed Jan 26 09:53:46 2005 +0000
     1.2 +++ b/.rootkeys	Thu Jan 27 17:33:33 2005 +0000
     1.3 @@ -313,8 +313,8 @@ 413cb3b5eKxnzoodEqaWn2wrPnHWnA netbsd-2.
     1.4  413cb3b5F56TvQWAmO5TsuzhtzLFPQ netbsd-2.0-xen-sparse/sys/arch/xen/xen/xenkbc.c
     1.5  413cb3b53nyOv1OIeDSsCXhBFDXvJA netbsd-2.0-xen-sparse/sys/nfs/files.nfs
     1.6  413aa1d0oNP8HXLvfPuMe6cSroUfSA patches/linux-2.6.9/agpgart.patch
     1.7 -40e1b09db5mN69Ijj0X_Eol-S7dXiw tools/Make.defs
     1.8  3f776bd1Hy9rn69ntXBhPReUFw9IEA tools/Makefile
     1.9 +40e1b09db5mN69Ijj0X_Eol-S7dXiw tools/Rules.mk
    1.10  4124b307nRyK3dhn1hAsvrY76NuV3g tools/check/Makefile
    1.11  4124b307vHLUWbfpemVefmaWDcdfag tools/check/README
    1.12  4124b307jt7T3CHysgl9LijNHSe1tA tools/check/check_brctl
     2.1 --- a/Makefile	Wed Jan 26 09:53:46 2005 +0000
     2.2 +++ b/Makefile	Thu Jan 27 17:33:33 2005 +0000
     2.3 @@ -11,7 +11,7 @@ INSTALL_DIR	:= $(INSTALL) -d -m0755
     2.4  INSTALL_DATA	:= $(INSTALL) -m0644
     2.5  INSTALL_PROG	:= $(INSTALL) -m0755
     2.6  
     2.7 -KERNELS ?= linux-2.6-xen0 linux-2.6-xenU  linux-2.4-xen0 linux-2.4-xenU netbsd-2.0-xenU
     2.8 +KERNELS ?= *2.6*
     2.9  # linux-2.4-xen0 linux-2.4-xenU netbsd-2.0-xenU
    2.10  # You may use wildcards in the above e.g. KERNELS=*2.4*
    2.11  
    2.12 @@ -21,6 +21,12 @@ XKERNELS := $(foreach kernel, $(KERNELS)
    2.13  
    2.14  export DESTDIR
    2.15  
    2.16 +# Export target architecture overrides to Xen and Linux sub-trees.
    2.17 +ifneq ($(TARGET_ARCH),)
    2.18 +SUBARCH := $(subst x86_32,i386,$(TARGET_ARCH))
    2.19 +export TARGET_ARCH SUBARCH
    2.20 +endif
    2.21 +
    2.22  include buildconfigs/Rules.mk
    2.23  
    2.24  .PHONY:	all dist install xen tools kernels docs world clean mkpatches mrproper
    2.25 @@ -146,9 +152,20 @@ help:
    2.26  	@echo '                     with extreme care!)'
    2.27  
    2.28  # Use this target with extreme care!
    2.29 +uninstall: DESTDIR=
    2.30 +uninstall: D=$(DESTDIR)
    2.31  uninstall:
    2.32 -	cp -a /etc/xen /etc/xen.old && rm -rf /etc/xen 
    2.33 -	rm -rf "/usr/lib/python2.?/site-packages/xen* /usr/lib/libxc* /usr/lib/python2.?/site-packages/Xc*"
    2.34 +	[ ! -d $(D)/etc/xen ] || mv -f $(D)/etc/xen $(D)/etc/xen.old
    2.35 +	rm -rf $(D)/etc/init.d/xend*
    2.36 +	rm -rf $(D)/usr/lib/libxc* $(D)/usr/lib/libxutil*
    2.37 +	rm -rf $(D)/usr/lib/python/xen $(D)/usr/include/xen
    2.38 +	rm -rf $(D)/usr/include/xcs_proto.h $(D)/usr/include/xc.h
    2.39 +	rm -rf $(D)/usr/sbin/xcs $(D)/usr/sbin/xcsdump $(D)/usr/sbin/xen*
    2.40 +	rm -rf $(D)/usr/sbin/netfix
    2.41 +	rm -rf $(D)/usr/sbin/xfrd $(D)/usr/sbin/xm $(D)/var/lib/xen
    2.42 +	rm -rf $(D)/usr/share/doc/xen  $(D)/usr/man/man*/xentrace*
    2.43 +	rm -rf $(D)/usr/bin/xen* $(D)/usr/bin/miniterm
    2.44 +	rm -rf $(D)/boot/*xen*
    2.45  
    2.46  # Legacy targets for compatibility
    2.47  linux24:
     3.1 --- a/install.sh	Wed Jan 26 09:53:46 2005 +0000
     3.2 +++ b/install.sh	Thu Jan 27 17:33:33 2005 +0000
     3.3 @@ -24,7 +24,7 @@ fi
     3.4  
     3.5  echo "Installing Xen from '$src' to '$dst'..."
     3.6  cd $src/boot
     3.7 -(echo '2.6.*' -2.6; echo '2.4.*' -2.4; echo '2.*.*' '') | while read mv
     3.8 +(echo '2.6.*' -2.6; echo '2.4.*' -2.4; echo '2.*.*' '') | while read m v
     3.9  do
    3.10    l=$(eval ls -t vmlinuz-$m-xen0 2>/dev/null | head -n 1)
    3.11    [ -e "$l" ] && ln -fs "$l" vmlinuz${v}-xen0
     4.1 --- a/tools/Make.defs	Wed Jan 26 09:53:46 2005 +0000
     4.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.3 @@ -1,4 +0,0 @@
     4.4 -#  -*- mode: Makefile; -*-
     4.5 -XEN_XC             = $(XEN_ROOT)/tools/python/xen/lowlevel/xc
     4.6 -XEN_LIBXC          = $(XEN_ROOT)/tools/libxc
     4.7 -XEN_LIBXUTIL       = $(XEN_ROOT)/tools/libxutil
     5.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.2 +++ b/tools/Rules.mk	Thu Jan 27 17:33:33 2005 +0000
     5.3 @@ -0,0 +1,15 @@
     5.4 +#  -*- mode: Makefile; -*-
     5.5 +
     5.6 +XEN_XC             = $(XEN_ROOT)/tools/python/xen/lowlevel/xc
     5.7 +XEN_LIBXC          = $(XEN_ROOT)/tools/libxc
     5.8 +XEN_LIBXUTIL       = $(XEN_ROOT)/tools/libxutil
     5.9 +
    5.10 +ifeq ($(TARGET_ARCH),x86_32)
    5.11 +CFLAGS  += -m32 -march=i686
    5.12 +LDFLAGS += -m elf_i386
    5.13 +endif
    5.14 +
    5.15 +ifeq ($(TARGET_ARCH),x86_64)
    5.16 +CFLAGS  += -m64
    5.17 +LDFLAGS += -m elf_x86_64
    5.18 +endif
     6.1 --- a/tools/libxc/Makefile	Wed Jan 26 09:53:46 2005 +0000
     6.2 +++ b/tools/libxc/Makefile	Thu Jan 27 17:33:33 2005 +0000
     6.3 @@ -10,7 +10,7 @@ SONAME   = libxc.so.$(MAJOR)
     6.4  CC       = gcc
     6.5  
     6.6  XEN_ROOT = ../..
     6.7 -include $(XEN_ROOT)/tools/Make.defs
     6.8 +include $(XEN_ROOT)/tools/Rules.mk
     6.9  
    6.10  vpath %c       $(XEN_LIBXUTIL)
    6.11  INCLUDES += -I $(XEN_LIBXUTIL)
    6.12 @@ -70,8 +70,8 @@ install: all
    6.13  	$(INSTALL_DIR) $(DESTDIR)/usr/lib
    6.14  	$(INSTALL_DIR) $(DESTDIR)/usr/include
    6.15  	$(INSTALL_PROG) $(LIB) $(DESTDIR)/usr/lib
    6.16 -	ln -sf $(LIB_NAME).so.$(MAJOR).$(MINOR) $(DESTDIR)/usr/lib/$(LIB_NAME).so.$(MAJOR)
    6.17 -	ln -sf $(LIB_NAME).so.$(MAJOR) $(DESTDIR)/usr/lib/$(LIB_NAME).so
    6.18 +	ln -sf libxc.so.$(MAJOR).$(MINOR) $(DESTDIR)/usr/lib/libxc.so.$(MAJOR)
    6.19 +	ln -sf libxc.so.$(MAJOR) $(DESTDIR)/usr/lib/libxc.so
    6.20  	$(INSTALL_DATA) xc.h $(DESTDIR)/usr/include
    6.21  
    6.22  clean:
     7.1 --- a/tools/libxutil/Makefile	Wed Jan 26 09:53:46 2005 +0000
     7.2 +++ b/tools/libxutil/Makefile	Thu Jan 27 17:33:33 2005 +0000
     7.3 @@ -4,7 +4,7 @@ INSTALL_DATA	= $(INSTALL) -m0644
     7.4  INSTALL_PROG	= $(INSTALL) -m0755
     7.5  INSTALL_DIR	= $(INSTALL) -d -m0755
     7.6  
     7.7 -include $(XEN_ROOT)/tools/Make.defs
     7.8 +include $(XEN_ROOT)/tools/Rules.mk
     7.9  
    7.10  CC = gcc
    7.11  
     8.1 --- a/tools/misc/Makefile	Wed Jan 26 09:53:46 2005 +0000
     8.2 +++ b/tools/misc/Makefile	Thu Jan 27 17:33:33 2005 +0000
     8.3 @@ -3,10 +3,10 @@ INSTALL_PROG	= $(INSTALL) -m0755
     8.4  INSTALL_DIR	= $(INSTALL) -d -m0755
     8.5  
     8.6  XEN_ROOT=../..
     8.7 -include $(XEN_ROOT)/tools/Make.defs
     8.8 +include $(XEN_ROOT)/tools/Rules.mk
     8.9  
    8.10 -CC         = gcc
    8.11 -CFLAGS     = -Wall -Werror -O3 
    8.12 +CC        = gcc
    8.13 +CFLAGS   += -Wall -Werror -O3 
    8.14  
    8.15  INCLUDES += -I $(XEN_XC)
    8.16  INCLUDES += -I $(XEN_LIBXC)
    8.17 @@ -27,7 +27,8 @@ install: all
    8.18  	$(INSTALL_DIR) $(DESTDIR)/usr/sbin
    8.19  	$(INSTALL_PROG) $(INSTALL_BIN) $(DESTDIR)/usr/bin
    8.20  	$(INSTALL_PROG) $(INSTALL_SBIN) $(DESTDIR)/usr/sbin
    8.21 -	$(MAKE) -C miniterm install
    8.22 +#       No sense in installing miniterm on the Xen box.
    8.23 +#	$(MAKE) -C miniterm install
    8.24  
    8.25  clean:
    8.26  	$(RM) *.o $(TARGETS) *~
     9.1 --- a/tools/python/Makefile	Wed Jan 26 09:53:46 2005 +0000
     9.2 +++ b/tools/python/Makefile	Thu Jan 27 17:33:33 2005 +0000
     9.3 @@ -1,9 +1,12 @@
     9.4 +
     9.5 +XEN_ROOT = ../..
     9.6 +include $(XEN_ROOT)/tools/Rules.mk
     9.7  
     9.8  all:
     9.9 -	python setup.py build
    9.10 +	CFLAGS="$(CFLAGS)" python setup.py build
    9.11  
    9.12  install: all
    9.13 -	python setup.py install --home="$(DESTDIR)/usr"
    9.14 +	CFLAGS="$(CFLAGS)" python setup.py install --home="$(DESTDIR)/usr"
    9.15  
    9.16  clean:
    9.17  	rm -rf build *.pyc *.pyo *.o *.a *~
    10.1 --- a/tools/python/xen/lowlevel/xu/xu.c	Wed Jan 26 09:53:46 2005 +0000
    10.2 +++ b/tools/python/xen/lowlevel/xu/xu.c	Thu Jan 27 17:33:33 2005 +0000
    10.3 @@ -82,12 +82,12 @@ static int xcs_ctrl_fd = -1; /* control 
    10.4  static int xcs_data_fd = -1; /*    data connection to the xcs server. */
    10.5  static u32 xcs_session_id = 0;
    10.6  
    10.7 -int xcs_ctrl_send(xcs_msg_t *msg);
    10.8 -int xcs_ctrl_read(xcs_msg_t *msg);
    10.9 -int xcs_data_send(xcs_msg_t *msg);
   10.10 -int xcs_data_read(xcs_msg_t *msg);
   10.11 +static int xcs_ctrl_send(xcs_msg_t *msg);
   10.12 +static int xcs_ctrl_read(xcs_msg_t *msg);
   10.13 +static int xcs_data_send(xcs_msg_t *msg);
   10.14 +static int xcs_data_read(xcs_msg_t *msg);
   10.15  
   10.16 -int xcs_connect(char *ip, short port)
   10.17 +static int xcs_connect(char *ip, short port)
   10.18  {
   10.19      struct sockaddr_in addr;
   10.20      int ret, flags;
   10.21 @@ -170,22 +170,6 @@ int xcs_connect(char *ip, short port)
   10.22          goto data_fd_fail;
   10.23      }
   10.24      
   10.25 -    /* Haven't put type binding hooks into Xend yet. */
   10.26 -    /* for now, register for everything:             */
   10.27 -    /*
   10.28 -    msg.type = XCS_MSG_BIND;
   10.29 -    msg.u.bind.port = PORT_WILDCARD;
   10.30 -    msg.u.bind.type = TYPE_WILDCARD;
   10.31 -    xcs_ctrl_send(&msg);
   10.32 -    xcs_ctrl_read(&msg);
   10.33 -    
   10.34 -    if (msg.result != XCS_RSLT_OK)
   10.35 -    {
   10.36 -        printf("error binding!\n");
   10.37 -        goto data_fd_fail;
   10.38 -    }
   10.39 -    printf("successfully connected to xcs.\n");
   10.40 -    */
   10.41      return 0;
   10.42  
   10.43  data_fd_fail: 
   10.44 @@ -201,66 +185,43 @@ fail:
   10.45      
   10.46  }
   10.47  
   10.48 -void xcs_disconnect(void)
   10.49 +static void xcs_disconnect(void)
   10.50  {
   10.51 -    printf("xcs_disconnect called!\n");
   10.52      close(xcs_data_fd);
   10.53      xcs_data_fd = -1;
   10.54      close(xcs_ctrl_fd);
   10.55      xcs_ctrl_fd = -1;
   10.56  }
   10.57  
   10.58 -int xcs_ctrl_read(xcs_msg_t *msg)
   10.59 +static int xcs_ctrl_read(xcs_msg_t *msg)
   10.60  {
   10.61      int ret;
   10.62      
   10.63      ret = read(xcs_ctrl_fd, msg, sizeof(xcs_msg_t));
   10.64 -    if (ret != sizeof(xcs_msg_t)) {
   10.65 -        printf("xu-xcs: ctrl read error (%d)\n", errno);
   10.66 -        /* TODO: set xcs_fd to -1 if the connection has been dropped. */
   10.67 -    } else {
   10.68 -        printf("xu-xcs: read! fd: %d, type: %u\n", xcs_ctrl_fd, msg->type);
   10.69 -    }
   10.70      return ret;
   10.71  }
   10.72  
   10.73 -int xcs_ctrl_send(xcs_msg_t *msg)
   10.74 +static int xcs_ctrl_send(xcs_msg_t *msg)
   10.75  {
   10.76      int ret;
   10.77      
   10.78      ret = send(xcs_ctrl_fd, msg, sizeof(xcs_msg_t), 0);
   10.79 -    if (ret != sizeof(xcs_msg_t) )
   10.80 -    {
   10.81 -        printf("xu-xcs: ctrl send error(%d)\n", errno);
   10.82 -        /* TODO: set xcs_fd to -1 if the connection has been dropped. */
   10.83 -    } else {
   10.84 -        printf("xu-xcs: sent! fd: %d, type: %u\n", xcs_ctrl_fd, msg->type);
   10.85 -    }
   10.86      return ret;
   10.87  }
   10.88  
   10.89 -int xcs_data_read(xcs_msg_t *msg)
   10.90 +static int xcs_data_read(xcs_msg_t *msg)
   10.91  {
   10.92      int ret;
   10.93      
   10.94      ret = read(xcs_data_fd, msg, sizeof(xcs_msg_t));
   10.95 -    if (ret != sizeof(xcs_msg_t)) {
   10.96 -        printf("xu-xcs: ctrl read error (%d)\n", errno);
   10.97 -        /* TODO: set xcs_fd to -1 if the connection has been dropped. */
   10.98 -    }
   10.99      return ret;
  10.100  }
  10.101  
  10.102 -int xcs_data_send(xcs_msg_t *msg)
  10.103 +static int xcs_data_send(xcs_msg_t *msg)
  10.104  {
  10.105      int ret;
  10.106      
  10.107      ret = send(xcs_data_fd, msg, sizeof(xcs_msg_t), 0);
  10.108 -    if (ret != sizeof(xcs_msg_t) )
  10.109 -    {
  10.110 -        printf("xu-xcs: ctrl send error(%d)\n", errno);
  10.111 -        /* TODO: set xcs_fd to -1 if the connection has been dropped. */
  10.112 -    }
  10.113      return ret;
  10.114  }
  10.115  
  10.116 @@ -302,7 +263,6 @@ static PyObject *xu_notifier_read(PyObje
  10.117  
  10.118      if ( !PyArg_ParseTuple(args, "") )
  10.119          return NULL;
  10.120 -    printf("xu_notifier_read()\n");
  10.121           
  10.122      while ((!REQ_RING_FULL) && (!RSP_RING_FULL))
  10.123      {
  10.124 @@ -318,7 +278,7 @@ static PyObject *xu_notifier_read(PyObje
  10.125                  break;
  10.126              return PyErr_SetFromErrno(PyExc_IOError);
  10.127          }
  10.128 -        printf("notifier got msg type %u\n", ent->msg.type);
  10.129 +        
  10.130          switch (ent->msg.type)
  10.131          {
  10.132          case XCS_REQUEST:
  10.133 @@ -337,26 +297,21 @@ static PyObject *xu_notifier_read(PyObje
  10.134              return PyInt_FromLong(ret);
  10.135  
  10.136          default:
  10.137 -            printf("Throwing away xcs msg type: %u\n", ent->msg.type);
  10.138 +            /*printf("Throwing away xcs msg type: %u\n", ent->msg.type);*/
  10.139              free(ent);
  10.140          }
  10.141      }
  10.142      
  10.143      if (!REQ_RING_EMPTY) 
  10.144      {
  10.145 -        printf("nfy: req: %d\n", 
  10.146 -                REQ_RING_ENT(req_cons)->msg.u.control.local_port);
  10.147          return PyInt_FromLong(REQ_RING_ENT(req_cons)->msg.u.control.local_port); 
  10.148      }
  10.149      
  10.150      if (!RSP_RING_EMPTY) 
  10.151      {
  10.152 -        printf("nfy: rsp: %d\n", 
  10.153 -                RSP_RING_ENT(rsp_cons)->msg.u.control.local_port);
  10.154          return PyInt_FromLong(RSP_RING_ENT(rsp_cons)->msg.u.control.local_port); 
  10.155      }
  10.156      
  10.157 -    printf("nfy: returning None\n");
  10.158      Py_INCREF(Py_None);
  10.159      return Py_None;
  10.160  }
  10.161 @@ -484,7 +439,6 @@ static PyObject *xu_notifier_new(PyObjec
  10.162      xu_notifier_object *xun;
  10.163      int i;
  10.164  
  10.165 -printf("xu_notifier_new()\n");
  10.166      if ( !PyArg_ParseTuple(args, "") )
  10.167          return NULL;
  10.168  
  10.169 @@ -506,6 +460,7 @@ static PyObject *xu_notifier_getattr(PyO
  10.170  
  10.171  static void xu_notifier_dealloc(PyObject *self)
  10.172  {
  10.173 +    xcs_disconnect();
  10.174      PyObject_Del(self);
  10.175  }
  10.176  
  10.177 @@ -1119,9 +1074,6 @@ static PyObject *xu_port_read_request(Py
  10.178      if ((ent == NULL) ||
  10.179          (ent->msg.u.control.remote_dom != xup->remote_dom)) 
  10.180          goto none;
  10.181 -    
  10.182 -printf("read request (%d:%d)\n", ent->msg.u.control.msg.type, 
  10.183 -        ent->msg.u.control.msg.subtype);
  10.184  
  10.185      cmsg = &ent->msg.u.control.msg;
  10.186      xum = PyObject_New(xu_message_object, &xu_message_type);
  10.187 @@ -1138,7 +1090,6 @@ printf("read request (%d:%d)\n", ent->ms
  10.188      return (PyObject *)xum;
  10.189      
  10.190  none:
  10.191 -printf("read request - NO REQUEST!\n");
  10.192      Py_INCREF(Py_None);
  10.193      return Py_None;
  10.194      
  10.195 @@ -1187,9 +1138,6 @@ static PyObject *xu_port_read_response(P
  10.196      if ((ent == NULL) ||
  10.197          (ent->msg.u.control.remote_dom != xup->remote_dom))
  10.198           goto none;
  10.199 -    
  10.200 -printf("read response (%d:%d)\n", ent->msg.u.control.msg.type, 
  10.201 -        ent->msg.u.control.msg.subtype);
  10.202  
  10.203      cmsg = &ent->msg.u.control.msg;
  10.204      xum = PyObject_New(xu_message_object, &xu_message_type);
  10.205 @@ -1206,7 +1154,6 @@ printf("read response (%d:%d)\n", ent->m
  10.206      return (PyObject *)xum;
  10.207      
  10.208  none:
  10.209 -printf("read response - NO RESPONSE!\n");
  10.210      Py_INCREF(Py_None);
  10.211      return Py_None;
  10.212      
  10.213 @@ -1242,8 +1189,7 @@ static PyObject *xu_port_request_to_read
  10.214      xcs_msg_ent_t    *ent;
  10.215      int               found = 0;
  10.216      unsigned          i;
  10.217 -
  10.218 -printf("xu_port_request_to_read()\n");    
  10.219 +  
  10.220      if ( !PyArg_ParseTuple(args, "") )
  10.221          return NULL;
  10.222  
  10.223 @@ -1274,8 +1220,7 @@ static PyObject *xu_port_response_to_rea
  10.224      xcs_msg_ent_t    *ent;
  10.225      int               found = 0;
  10.226      unsigned          i;
  10.227 -
  10.228 -printf("xu_port_response_to_read()\n");    
  10.229 +  
  10.230      if ( !PyArg_ParseTuple(args, "") )
  10.231          return NULL;
  10.232  
  10.233 @@ -1327,9 +1272,6 @@ static PyObject *xu_port_register(PyObje
  10.234                                        &type) )
  10.235          return NULL;
  10.236      
  10.237 -    printf("REGISTER  : Dom: %3d  Port: %3d  Type:%3d\n",
  10.238 -        xup->remote_dom, xup->local_port, type);
  10.239 -    
  10.240      msg.type = XCS_MSG_BIND;
  10.241      msg.u.bind.port = xup->local_port;
  10.242      msg.u.bind.type = type;
  10.243 @@ -1338,7 +1280,6 @@ static PyObject *xu_port_register(PyObje
  10.244      
  10.245      if (msg.result != XCS_RSLT_OK)
  10.246      {
  10.247 -        printf("          : REGISTRATION FAILED! (%d)\n", msg.result);
  10.248          return PyInt_FromLong(0);
  10.249      }
  10.250      
  10.251 @@ -1357,9 +1298,6 @@ static PyObject *xu_port_deregister(PyOb
  10.252                                        &type) )
  10.253          return NULL;
  10.254      
  10.255 -    printf("DEREGISTER: Dom: %3d  Port: %3d  Type:%3d\n",
  10.256 -        xup->remote_dom, xup->local_port, type);
  10.257 -    
  10.258      msg.type = XCS_MSG_UNBIND;
  10.259      msg.u.bind.port = xup->local_port;
  10.260      msg.u.bind.type = type;
  10.261 @@ -1368,7 +1306,6 @@ static PyObject *xu_port_deregister(PyOb
  10.262      
  10.263      if (msg.result != XCS_RSLT_OK)
  10.264      {
  10.265 -        printf("          : DEREGISTRATION FAILED! (%d)\n", msg.result);
  10.266          return PyInt_FromLong(0);
  10.267      }
  10.268      
    11.1 --- a/tools/vnet/vnet-module/Makefile-2.4	Wed Jan 26 09:53:46 2005 +0000
    11.2 +++ b/tools/vnet/vnet-module/Makefile-2.4	Thu Jan 27 17:33:33 2005 +0000
    11.3 @@ -61,7 +61,6 @@ CFLAGS += -Wno-trigraphs
    11.4  CFLAGS += -Wno-unused-function
    11.5  CFLAGS += -Wno-unused-parameter 
    11.6  
    11.7 -CFLAGS += -g
    11.8  CFLAGS += -O2
    11.9  CFLAGS += -fno-strict-aliasing 
   11.10  CFLAGS += -fno-common 
    12.1 --- a/tools/vnet/vnetd/Makefile	Wed Jan 26 09:53:46 2005 +0000
    12.2 +++ b/tools/vnet/vnetd/Makefile	Thu Jan 27 17:33:33 2005 +0000
    12.3 @@ -21,7 +21,7 @@ all: vnetd
    12.4  #----------------------------------------------------------------------------
    12.5  
    12.6  XEN_ROOT  = ../../..
    12.7 -include $(XEN_ROOT)/tools/Make.defs
    12.8 +include $(XEN_ROOT)/tools/Rules.mk
    12.9  
   12.10  VNETD_INSTALL_DIR = /usr/sbin
   12.11  
   12.12 @@ -42,7 +42,6 @@ INCLUDES += -I$(GC_INCLUDE)
   12.13  CPPFLAGS += -D USE_GC
   12.14  
   12.15  #----------------------------------------------------------------------------
   12.16 -CFLAGS += -g
   12.17  CFLAGS += -Wall
   12.18  CFLAGS += $(INCLUDES) $(LIBS)
   12.19  
    13.1 --- a/tools/x2d2/Makefile	Wed Jan 26 09:53:46 2005 +0000
    13.2 +++ b/tools/x2d2/Makefile	Thu Jan 27 17:33:33 2005 +0000
    13.3 @@ -1,8 +1,8 @@
    13.4  XEN_ROOT=../..
    13.5 -include $(XEN_ROOT)/tools/Make.defs
    13.6 +include $(XEN_ROOT)/tools/Rules.mk
    13.7  
    13.8  CC       = gcc
    13.9 -CFLAGS   = -Wall -Werror -g
   13.10 +CFLAGS  += -Wall -Werror -O3 -fno-strict-aliasing
   13.11  
   13.12  CFLAGS  += -I $(XEN_XC)
   13.13  CFLAGS  += -I $(XEN_LIBXC)
    14.1 --- a/tools/xcs/Makefile	Wed Jan 26 09:53:46 2005 +0000
    14.2 +++ b/tools/xcs/Makefile	Thu Jan 27 17:33:33 2005 +0000
    14.3 @@ -2,7 +2,7 @@
    14.4  # Andrew Warfield, 2004
    14.5  
    14.6  XEN_ROOT=../..
    14.7 -include $(XEN_ROOT)/tools/Make.defs
    14.8 +include $(XEN_ROOT)/tools/Rules.mk
    14.9  
   14.10  XCS_INSTALL_DIR = /usr/sbin
   14.11  
    15.1 --- a/tools/xentrace/Makefile	Wed Jan 26 09:53:46 2005 +0000
    15.2 +++ b/tools/xentrace/Makefile	Thu Jan 27 17:33:33 2005 +0000
    15.3 @@ -4,10 +4,10 @@ INSTALL_DIR	= $(INSTALL) -d -m0755
    15.4  INSTALL_DATA	= $(INSTALL) -m0644
    15.5  
    15.6  XEN_ROOT=../..
    15.7 -include $(XEN_ROOT)/tools/Make.defs
    15.8 +include $(XEN_ROOT)/tools/Rules.mk
    15.9  
   15.10  CC       = gcc
   15.11 -CFLAGS   = -Wall -Werror -O3
   15.12 +CFLAGS  += -Wall -Werror -O3
   15.13  
   15.14  CFLAGS  += -I $(XEN_XC)
   15.15  CFLAGS  += -I $(XEN_LIBXC)
    16.1 --- a/tools/xfrd/Makefile	Wed Jan 26 09:53:46 2005 +0000
    16.2 +++ b/tools/xfrd/Makefile	Thu Jan 27 17:33:33 2005 +0000
    16.3 @@ -9,7 +9,7 @@ INSTALL_PROG	= $(INSTALL) -m0755
    16.4  INSTALL_DIR	= $(INSTALL) -d -m0755
    16.5  
    16.6  XEN_ROOT  = ../..
    16.7 -include $(XEN_ROOT)/tools/Make.defs
    16.8 +include $(XEN_ROOT)/tools/Rules.mk
    16.9  
   16.10  XFRD_INSTALL_DIR = /usr/sbin
   16.11  
   16.12 @@ -36,9 +36,7 @@ endif
   16.13  
   16.14  CC := gcc
   16.15  
   16.16 -CFLAGS += -g
   16.17 -CFLAGS += -Wall
   16.18 -CFLAGS += -Werror
   16.19 +CFLAGS += -Wall -Werror -O3 -fno-strict-aliasing
   16.20  CFLAGS += $(INCLUDES)
   16.21  # Make gcc generate dependencies.
   16.22  CFLAGS += -Wp,-MD,.$(@F).d
    17.1 --- a/xen/Rules.mk	Wed Jan 26 09:53:46 2005 +0000
    17.2 +++ b/xen/Rules.mk	Thu Jan 27 17:33:33 2005 +0000
    17.3 @@ -6,14 +6,15 @@ perfc       ?= n
    17.4  trace       ?= n
    17.5  optimize    ?= y
    17.6  
    17.7 -# Currently supported architectures:
    17.8 -#  {COMPILE,TARGET}_ARCH    := x86
    17.9 -#  {COMPILE,TARGET}_SUBARCH := x86_32 | x86_64
   17.10 -COMPILE_ARCH    := x86
   17.11 -COMPILE_SUBARCH := $(shell uname -m | sed -e s/i.86/x86_32/)
   17.12 +# Currently supported architectures: x86_32, x86_64
   17.13 +COMPILE_ARCH    ?= $(shell uname -m | sed -e s/i.86/x86_32/)
   17.14 +TARGET_ARCH     ?= $(COMPILE_ARCH)
   17.15  
   17.16 -TARGET_ARCH     ?= $(COMPILE_ARCH)
   17.17 -TARGET_SUBARCH  ?= $(COMPILE_SUBARCH)
   17.18 +# Set ARCH/SUBARCH appropriately.
   17.19 +COMPILE_SUBARCH := $(COMPILE_ARCH)
   17.20 +TARGET_SUBARCH  := $(COMPILE_ARCH)
   17.21 +COMPILE_ARCH    := $(patsubst x86%,x86,$(COMPILE_ARCH))
   17.22 +TARGET_ARCH     := $(patsubst x86%,x86,$(TARGET_ARCH))
   17.23  
   17.24  TARGET  := $(BASEDIR)/xen
   17.25  HDRS    := $(wildcard $(BASEDIR)/include/xen/*.h)