From: Andrew Jones Subject: Re: [PATCH v5 03/19] clean root dir of all x86-ness Date: Thu, 12 Jun 2014 12:40:05 +0200 Message-ID: <20140612104005.GA6646@dhcp-27-201.brq.redhat.com> References: <1402495294-30737-1-git-send-email-drjones@redhat.com> <1402495294-30737-4-git-send-email-drjones@redhat.com> <5399819A.2030007@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org, christoffer.dall@linaro.org To: Paolo Bonzini Return-path: Received: from mx1.redhat.com ([209.132.183.28]:4604 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755212AbaFLKkL (ORCPT ); Thu, 12 Jun 2014 06:40:11 -0400 Content-Disposition: inline In-Reply-To: <5399819A.2030007@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Thu, Jun 12, 2014 at 12:31:54PM +0200, Paolo Bonzini wrote: > Il 11/06/2014 16:01, Andrew Jones ha scritto: > >diff --git a/configure b/configure > >index d0c62e24dd1d2..6cfc64943f6e6 100755 > >--- a/configure > >+++ b/configure > >@@ -15,6 +15,7 @@ usage() { > > Usage: $0 [options] > > > > Options include: > >+ --test-dir=DIR the main directory for tests ($arch) > > --arch=ARCH architecture to compile for ($arch) > > --cross-prefix=PREFIX cross compiler prefix > > --cc=CC c compiler to use ($cc) > >@@ -33,6 +34,9 @@ while [[ "$1" = -* ]]; do > > opt="${opt%%=*}" > > fi > > case "$opt" in > >+ --test-dir) > >+ testdir="$arg" > >+ ;; > > --prefix) > > prefix="$arg" > > ;; > >@@ -62,6 +66,18 @@ while [[ "$1" = -* ]]; do > > ;; > > esac > > done > >+if [ -z "$testdir" -a \( "$arch" = "i386" -o "$arch" = "x86_64" \) ]; then > >+ testdir=x86 > >+elif [ -z "$testdir" ]; then > >+ testdir=$arch > >+fi > >+if [ ! -d $testdir ]; then > >+ echo "$testdir does not exist!" > >+ exit 1 > >+fi > >+if [ -f $testdir/run ]; then > >+ ln -fs $testdir/run $testdir-run > >+fi > > Why is --test-dir useful? Can you just use --arch instead? testdir is not always the same as arch, e.g. arch=x86_64, testdir=x86, and setting --arch x86 would lose useful information. We wouldn't know if arch is supposed to be i386 or x86_64. The same argument will apply to arch=arm vs. arch=aarch64. > > >diff --git a/docs/testdev.txt b/docs/testdev.txt > >new file mode 100644 > >index 0000000000000..854fe20d56f66 > >--- /dev/null > >+++ b/docs/testdev.txt > >@@ -0,0 +1,13 @@ > >+This file describes the virtual device of qemu for supporting this > >+test suite. > >+ > >+Services supplied by the testdev device: > >+ serial output: write-only, on io port 0xf1 > >+ exit process: write-only, on io port 0xf4, value used as > >+ the exit code > >+ ram size: read-only, on io port 0xd1, 4 bytes' size > >+ irq line setting: write-only, on io ports 0x2000 - 0x2018, > >+ value to set/clear > >+ simple io: read/write, on io port 0xe0, 1/2/4 bytes > >+ > >+The test device uses a char device for actual output. > > I'm removing this file altogether and adding it to QEMU instead. Most of > the content is obsolete too. Sounds good to me. drew