ia64/xen-unstable

changeset 624:1449562d0ec4

bitkeeper revision 1.339.1.9 (3f12dd84Gykr1oP22loPEr0jPp3VJA)

Detect link-local addresses in xi_vifinit and route them via dom0, not the physical interface
author rac61@labyrinth.cl.cam.ac.uk
date Mon Jul 14 16:42:44 2003 +0000 (2003-07-14)
parents 6c66db2237d6
children e57f48a3d5fb
files BitKeeper/etc/ignore tools/internal/xi_vifinit
line diff
     1.1 --- a/BitKeeper/etc/ignore	Mon Jul 14 16:23:52 2003 +0000
     1.2 +++ b/BitKeeper/etc/ignore	Mon Jul 14 16:42:44 2003 +0000
     1.3 @@ -463,3 +463,7 @@ tools/control/web/pd-l.jsp
     1.4  tools/control/web/pd-r.jsp
     1.5  tools/control/web/pd-rr.jsp
     1.6  tools/control/web/pd.jsp
     1.7 +tools/internal/xi_list
     1.8 +tools/internal/xi_usage
     1.9 +tools/internal/xi_sched_domain
    1.10 +tools/internal/xi_sched_global
     2.1 --- a/tools/internal/xi_vifinit	Mon Jul 14 16:23:52 2003 +0000
     2.2 +++ b/tools/internal/xi_vifinit	Mon Jul 14 16:42:44 2003 +0000
     2.3 @@ -16,7 +16,15 @@ then
     2.4  fi
     2.5  
     2.6  #outbound rule:
     2.7 -echo "ADD ACCEPT srcaddr=$3 srcaddrmask=255.255.255.255 srcdom=$1 srcidx=$2 dst=PHYS proto=any" > /proc/xeno/vfr
     2.8 +echo $3 | grep -q "^169\\.254\\."
     2.9 +if [ $? -eq 0 ];
    2.10 +then
    2.11 +	# If this is a link local address, send to dom0
    2.12 +	echo "ADD ACCEPT srcaddr=$3 srcaddrmask=255.255.255.255 srcdom=$1 srcidx=$2 dstdom=0 dstidx=0 proto=any" > /proc/xeno/vfr
    2.13 +else
    2.14 +	# If this is not, send to wire
    2.15 +	echo "ADD ACCEPT srcaddr=$3 srcaddrmask=255.255.255.255 srcdom=$1 srcidx=$2 dst=PHYS proto=any" > /proc/xeno/vfr
    2.16 +fi
    2.17  
    2.18  #inbound rule:
    2.19  echo "ADD ACCEPT dstaddr=$3 dstaddrmask=255.255.255.255 src=ANY dstdom=$1 dstidx=$2 proto=any" > /proc/xeno/vfr