All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: Wei Liu <wei.liu2@citrix.com>
Cc: ian.jackson@eu.citrix.com, xen-devel@lists.xen.org
Subject: Re: [PATCH OSSTEST v3] Stubdom test case
Date: Wed, 10 Jun 2015 11:49:19 +0100	[thread overview]
Message-ID: <1433933359.30003.28.camel@citrix.com> (raw)
In-Reply-To: <1433932900-32440-1-git-send-email-wei.liu2@citrix.com>

On Wed, 2015-06-10 at 11:41 +0100, Wei Liu wrote:
> Currently only QEMU traditional supports stubdom, so we only create
> 
> test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64
> test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm
> test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64
> test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm
> 
> Note that stubdom only supports serial='pty'. Piping serial to stderr
> causes stubdom to exit abnormally.
> 
> Signed-off-by: Wei Liu <wei.liu2@citrix.com>

Looks plausible:

Acked-by: Ian Campbell <ian.campbell@citrix.com>

> ---
> Changes in v3:
> 1. Avoid having empty enable_stubdom runvar.
> 
> Changes in v2:
> 1. If stubdom is not defined use toolstack default.
> 2. Don't set stubdom runvar for every test case, use default.
> 
> diff -ub <(sort ../master-runvars) <(sort ../stubdom-runvars) | sed  's/[ \t]*$//' | egrep '^[\+|-]'
> --- /dev/fd/63	2015-06-10 11:40:23.203231476 +0100
> +++ /dev/fd/62	2015-06-10 11:40:23.203231476 +0100
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     all_hostflags               arch-amd64,arch-xen-amd64,suite-wheezy,purpose-test,hvm
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     arch                        amd64
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     bios                        rombios
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     buildjob                    build-amd64
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     debianhvm_image             debian-7.2.0-amd64-CD-1.iso
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     device_model_version        qemu-xen-traditional
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     enable_stubdom              true
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     enable_xsm                  false
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     kernbuildjob                build-amd64-pvops
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     kernkind                    pvops
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     toolstack                   xl
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64     xenbuildjob                 build-amd64
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm all_hostflags               arch-amd64,arch-xen-amd64,suite-wheezy,purpose-test,hvm
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm arch                        amd64
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm bios                        rombios
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm buildjob                    build-amd64-xsm
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm debianhvm_image             debian-7.2.0-amd64-CD-1.iso
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm device_model_version        qemu-xen-traditional
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm enable_stubdom              true
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm enable_xsm                  true
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm kernbuildjob                build-amd64-pvops
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm kernkind                    pvops
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm toolstack                   xl
> +xen-unstable               test-amd64-amd64-xl-qemut-stubdom-debianhvm-amd64-xsm xenbuildjob                 build-amd64-xsm
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      all_hostflags               arch-i386,arch-xen-amd64,suite-wheezy,purpose-test,hvm
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      arch                        i386
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      bios                        rombios
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      buildjob                    build-i386
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      debianhvm_image             debian-7.2.0-amd64-CD-1.iso
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      device_model_version        qemu-xen-traditional
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      enable_stubdom              true
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      enable_xsm                  false
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      kernbuildjob                build-i386-pvops
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      kernkind                    pvops
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      toolstack                   xl
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64      xenbuildjob                 build-amd64
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  all_hostflags               arch-i386,arch-xen-amd64,suite-wheezy,purpose-test,hvm
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  arch                        i386
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  bios                        rombios
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  buildjob                    build-i386-xsm
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  debianhvm_image             debian-7.2.0-amd64-CD-1.iso
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  device_model_version        qemu-xen-traditional
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  enable_stubdom              true
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  enable_xsm                  true
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  kernbuildjob                build-i386-pvops
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  kernkind                    pvops
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  toolstack                   xl
> +xen-unstable               test-amd64-i386-xl-qemut-stubdom-debianhvm-amd64-xsm  xenbuildjob                 build-amd64-xsm
> ---
>  Osstest/TestSupport.pm | 11 ++++++++++-
>  make-flight            | 17 ++++++++++++++---
>  ts-debian-hvm-install  |  6 ++++++
>  3 files changed, 30 insertions(+), 4 deletions(-)
> 
> diff --git a/Osstest/TestSupport.pm b/Osstest/TestSupport.pm
> index 1f3bab2..e91e8e7 100644
> --- a/Osstest/TestSupport.pm
> +++ b/Osstest/TestSupport.pm
> @@ -1648,7 +1648,6 @@ vncdisplay=0
>  vnclisten='$ho->{Ip}'
>  vncpasswd='$passwd'
>  
> -serial='file:/dev/stderr'
>  #
>  boot = 'dc'
>  END
> @@ -1663,6 +1662,16 @@ END
>          $cfg .= "bios='$bios'\n";
>      }
>  
> +    my $stubdom = $xopts{Stubdom};
> +    if (defined $stubdom) {
> +	$cfg .= "device_model_stubdomain_override=$stubdom\n";
> +    }
> +    if (defined $stubdom && $stubdom == 1) {
> +	$cfg .= "serial='pty'";
> +    } else {
> +	$cfg .= "serial='file:/dev/stderr'";
> +    }
> +
>      $xopts{VifType} ||= "ioemu";
>      my $cfgpath= prepareguest_part_xencfg($ho, $gho, $ram_mb, \%xopts, $cfg);
>      target_cmd_root($ho, <<END);
> diff --git a/make-flight b/make-flight
> index 41c7520..138b341 100755
> --- a/make-flight
> +++ b/make-flight
> @@ -214,10 +214,19 @@ do_hvm_debian_test_one () {
>    testname=$1
>    bios=$2
>    xsm=$3
> +  stubdom=$4
>  
> -  job_create_test test-$xenarch$kern-$dom0arch-xl$qemuu_suffix-$testname-amd64\
> +  stubdom_suffix=""
> +  stubdom_runvar=""
> +  if [ x$stubdom != x ]; then
> +      stubdom_suffix="-stubdom"
> +      stubdom_runvar="enable_stubdom=$stubdom"
> +  fi
> +
> +  job_create_test test-$xenarch$kern-$dom0arch-xl$qemuu_suffix$stubdom_suffix-$testname-amd64\
>      test-debianhvm xl $xenarch $dom0arch $qemuu_runvar \
>      enable_xsm=$xsm                             \
> +    $stubdom_runvar                             \
>      debianhvm_image=debian-7.2.0-amd64-CD-1.iso \
>      bios=$bios \
>      all_hostflags=$most_hostflags,hvm
> @@ -238,10 +247,12 @@ do_hvm_debian_tests() {
>      done
>    fi
>  
> -  # QEMU traditional supports rombios
> +  # QEMU traditional supports rombios and stubdom
>    if [ "x$qemuu_suffix" == "x-qemut" ]; then
>      for xsm in $xsms ; do
> -      do_hvm_debian_test_one debianhvm rombios $xsm
> +      for stubdom in true "" ; do
> +        do_hvm_debian_test_one debianhvm rombios $xsm $stubdom
> +      done
>      done
>    fi
>  }
> diff --git a/ts-debian-hvm-install b/ts-debian-hvm-install
> index ea2d1ad..0872288 100755
> --- a/ts-debian-hvm-install
> +++ b/ts-debian-hvm-install
> @@ -178,9 +178,15 @@ sub prep () {
>      }
>      logm("Host has $host_freemem_mb MB free memory, setting guest memory size to $ram_mb MB");
>  
> +    my $enable_stubdom = undef;
> +    if (defined $r{enable_stubdom}) {
> +	$enable_stubdom = ($r{enable_stubdom}//'false') =~ m/true/ ? 1 : 0;
> +    }
> +
>      more_prepareguest_hvm($ho,$gho, $ram_mb, $disk_mb,
>                            OnReboot => 'preserve',
>                            Bios => $r{bios},
> +                          Stubdom => $enable_stubdom,
>                            PostImageHook => sub {
>          my $cmds = iso_copy_content_from_image($gho, $newiso);
>          $cmds .= prepare_initrd($initrddir,$newiso,$preseed_file_path);

  reply	other threads:[~2015-06-10 10:49 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-10 19:40 [PATCH OSSTEST v4 0/2] Stubdom test case Wei Liu
2015-06-10 10:41 ` [PATCH OSSTEST v3] " Wei Liu
2015-06-10 10:49   ` Ian Campbell [this message]
2015-06-10 11:10   ` Ian Jackson
2015-06-10 11:31     ` Ian Campbell
2015-06-10 13:54     ` Wei Liu
2015-06-10 19:40 ` [PATCH OSSTEST v4 1/2] TestSupport: introduce guest_var_boolean Wei Liu
2015-06-11 15:05   ` Ian Jackson
2015-06-10 19:40 ` [PATCH OSSTEST v4 2/2] Stubdom test case Wei Liu
2015-06-15 12:05   ` Ian Jackson
2015-06-15 13:19     ` Wei Liu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1433933359.30003.28.camel@citrix.com \
    --to=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.