WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] Xm-test HVM network testing is broken. Th

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] Xm-test HVM network testing is broken. The new qemu code doesn't support
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 14 Jul 2006 17:40:42 +0000
Delivery-date: Fri, 14 Jul 2006 10:44:44 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID 89f7faa0c01a507365b4040d4b10b85d95c3acc0
# Parent  612671bd9a54ec9262abd26c4ba7b0c031aab2aa
Xm-test HVM network testing is broken. The new qemu code doesn't support
pcnet32, which is the current default driver loaded onto the disk.img.
This patch changes teh default to the rtl8139, which is xend's default.
This patch also adds a new "--with-network-drv" configuration option so
people can configure different drivers than the default.

Signed-off-by: Daniel Stekloff <dsteklof@xxxxxxxxxx>
---
 tools/xm-test/configure.ac                  |    8 ++++++
 tools/xm-test/ramdisk/Makefile.am           |    9 ++++---
 tools/xm-test/ramdisk/bin/create_disk_image |   33 ++++++++++++++++------------
 3 files changed, 33 insertions(+), 17 deletions(-)

diff -r 612671bd9a54 -r 89f7faa0c01a tools/xm-test/configure.ac
--- a/tools/xm-test/configure.ac        Fri Jul 14 11:48:48 2006 +0100
+++ b/tools/xm-test/configure.ac        Fri Jul 14 11:54:10 2006 +0100
@@ -84,6 +84,14 @@ dnl substitute @DRVDIR@ in all Makefiles
 dnl substitute @DRVDIR@ in all Makefiles
 AC_SUBST(DRVDIR)
 
+NETDRV="8139too.ko"
+AC_ARG_WITH(network-drv,
+       [  --with-network-drv=driver Set network driver to use 
[[default="8139too.ko"]]],
+       [ NETDRV="$withval" ])
+
+dnl substitute @DRVDIR@ in all Makefiles
+AC_SUBST(NETDRV)
+
 AC_SUBST(TENV)
 AC_SUBST(PACKAGE_VERSION)
 
diff -r 612671bd9a54 -r 89f7faa0c01a tools/xm-test/ramdisk/Makefile.am
--- a/tools/xm-test/ramdisk/Makefile.am Fri Jul 14 11:48:48 2006 +0100
+++ b/tools/xm-test/ramdisk/Makefile.am Fri Jul 14 11:54:10 2006 +0100
@@ -51,13 +51,14 @@ disk.img: existing
        chmod a+x $(HVM_SCRIPT)
        @if test ! "$(HVMKERNEL)" = "no" -a ! "$(DRVDIR)" = "no"; then \
                $(HVM_SCRIPT) -r $(XMTEST_VER_IMG) -k $(HVMKERNEL) \
-                       -d $(DRVDIR); \
+                       -d $(DRVDIR) -n $(NETDRV); \
        elif test "$(HVMKERNEL)" = "no" -a ! "$(DRVDIR)" = "no"; then \
-               $(HVM_SCRIPT) -r $(XMTEST_VER_IMG) -d $(DRVDIR); \
+               $(HVM_SCRIPT) -r $(XMTEST_VER_IMG) -d $(DRVDIR) -n $(NETDRV); \
        elif test ! "$(HVMKERNEL)" = "no" -a "$(DRVDIR)" = "no"; then \
-               $(HVM_SCRIPT) -r $(XMTEST_VER_IMG) -k $(HVMKERNEL); \
+               $(HVM_SCRIPT) -r $(XMTEST_VER_IMG) -k $(HVMKERNEL) \
+                       -n $(NETDRV); \
        else \
-               $(HVM_SCRIPT) -r $(XMTEST_VER_IMG); \
+               $(HVM_SCRIPT) -r $(XMTEST_VER_IMG) -n $(NETDRV); \
        fi
 
 existing:
diff -r 612671bd9a54 -r 89f7faa0c01a tools/xm-test/ramdisk/bin/create_disk_image
--- a/tools/xm-test/ramdisk/bin/create_disk_image       Fri Jul 14 11:48:48 
2006 +0100
+++ b/tools/xm-test/ramdisk/bin/create_disk_image       Fri Jul 14 11:54:10 
2006 +0100
@@ -51,20 +51,21 @@ Usage: $0 [OPTIONS]
 Usage: $0 [OPTIONS]
 
 OPTIONS:
-    -d|--dvrdir <name>       Directory where to fine network driver 
+    -d|--dvrdir <name>       Directory where to find network driver 
                              to use for disk image. 
     -i|--image <name>        Image name to create.
     -k|--kernel <name>       Kernel name to use for disk image.
+    -n|--netdrv <name>       Network driver name to use for disk image.
     -r|--rootfs <image>      Rootfs image to use for disk image.
 
-This script currently only supports the pcnet32 driver for network
-tests. If a dvrdir isn't added on the command-line, it will look
-in /lib/modules/ directory relating to the supplied kernel. If the
+This script defaults to using the 8139too.ko driver for network tests. 
+If a dvrdir isn't added on the command-line, it will look in 
+/lib/modules/ directory relating to the supplied kernel. If the
 network driver is built into the kernel, you can specify the key word
 "builtin" with the -d option and the script will continue.
 
-Note: The pcnet32 driver relies upon mii.ko. This script will look
-for that module in the same location as the pcnet32 driver, either
+Note: Many network drivers rely upon mii.ko. This script will look
+for that module in the same location as the network driver, either
 for the kernel or the location used with the -d option.
 
 EOU
@@ -94,6 +95,7 @@ function initialize_globals()
        IMAGE="disk.img"
        KERNEL=""
        DRVDIR=""
+       NETDRV="8139too.ko"
        LCONF="lilo.conf"
        LOOPD=""    # Loop device for entire disk image
        LOOPP=""    # Loop device for ext partition
@@ -126,6 +128,11 @@ function get_options()
                                KERNEL=${1}
                                shift
                                ;;
+                       -n|--netdrv)
+                               shift
+                               NETDRV=${1}
+                               shift
+                               ;;
                        -r|--rootfs)
                                shift
                                ROOTFS=${1}
@@ -256,23 +263,23 @@ function copy_netdriver_to_image()
                                                                                
 
        mkdir "$MNT/lib/modules"
        if [ -e "$DRVDIR" ]; then
-               if [ -e "$DRVDIR/pcnet32.ko" ]; then
+               if [ -e "$DRVDIR/$NETDRV" ]; then
                        cp $DRVDIR/mii.ko $MNT/lib/modules
-                       cp $DRVDIR/pcnet32.ko $MNT/lib/modules
+                       cp $DRVDIR/$NETDRV $MNT/lib/modules
                else
-                       die "Failed to find pcnet32.ko at $DRVDIR."
+                       die "Failed to find $NETDRV at $DRVDIR."
                fi
-       elif [ -e "$fdir/pcnet32.ko" ]; then
+       elif [ -e "$fdir/$NETDRV" ]; then
                cp $fdir/mii.ko $MNT/lib/modules
-               cp $fdir/pcnet32.ko $MNT/lib/modules
+               cp $fdir/$NETDRV $MNT/lib/modules
        else
-               die "Xm-test requires the pcnet32 driver to run."
+               die "Xm-test requires at minimum the 8139too.ko driver to run."
        fi
 
        # Make sure that modules will be installed
        if [ -e "$MNT/etc/init.d/rcS" ]; then
                echo "insmod /lib/modules/mii.ko" >> $MNT/etc/init.d/rcS
-               echo "insmod /lib/modules/pcnet32.ko" >> $MNT/etc/init.d/rcS
+               echo "insmod /lib/modules/$NETDRV" >> $MNT/etc/init.d/rcS
        else
                die "Failed to add insmod command to rcS file on image."
        fi

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] Xm-test HVM network testing is broken. The new qemu code doesn't support, Xen patchbot-unstable <=