>From 1a303fe8acb3949eb556673744bc5bc89a842b54 Mon Sep 17 00:00:00 2001 From: Konrad Rzeszutek Wilk Date: Wed, 17 May 2017 20:54:07 -0400 Subject: [PATCH v3 3/7] mfi-common: Add an livepatch test and also add job_create_build var. The enable_livepatch=[true|false] is added to the jobs. It should only be enabled for certain Xen versions (4.9) and higher. Signed-off-by: Konrad Rzeszutek Wilk --- v3: New patch --- mfi-common | 28 +++++++++++++++++++++++++--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/mfi-common b/mfi-common index ec31e2e..8cc9e5f 100644 --- a/mfi-common +++ b/mfi-common @@ -76,6 +76,24 @@ branch_wants_xtf_tests () { esac } +branch_wants_livepatch () { + echo $branch + case "$branch" in + osstest*) return 0;; + xen-3.*) return 0;; + xen-4.0*) return 0;; + xen-4.1*) return 0;; + xen-4.2*) return 0;; + xen-4.3*) return 0;; + xen-4.4*) return 0;; + xen-4.5*) return 0;; + xen-4.6*) return 0;; + xen-4.7*) return 0;; + livepatch*) return 0;; + *) return 1;; + esac +} + job_create_build () { job_create_build_filter_callback "$@" || return 0 @@ -104,6 +122,7 @@ create_build_jobs () { local want_xend build_defxend build_extraxend local enable_ovmf local build_hostflags + local enable_livepatch if [ "x$BUILD_LVEXTEND_MAX" != x ]; then BUILD_RUNVARS+=" build_lvextend_max=$BUILD_LVEXTEND_MAX " @@ -196,7 +215,10 @@ create_build_jobs () { want_prevxen=y fi fi - + enable_livepatch=false + if ! branch_wants_livepatch; then + enable_livepatch=true + fi eval " arch_runvars=\"\$ARCH_RUNVARS_$arch\" " @@ -211,7 +233,7 @@ create_build_jobs () { fi job_create_build build-$arch$xsm_suffix build \ arch=$arch enable_xend=$build_defxend enable_ovmf=$enable_ovmf\ - enable_xsm=$enable_xsm \ + enable_xsm=$enable_xsm enable_livepatch=$enable_livepatch \ tree_qemu=$TREE_QEMU \ tree_qemuu=$TREE_QEMU_UPSTREAM \ tree_xen=$TREE_XEN \ @@ -239,7 +261,7 @@ create_build_jobs () { # $REVISION_PREVXEN. job_create_build build-$arch-prev build \ arch=$arch enable_xend=false enable_ovmf=$enable_prevovmf\ - enable_xsm=false \ + enable_xsm=false enable_livepatch=$enable_livepatch \ tree_xen=$TREE_XEN \ $RUNVARS $BUILD_RUNVARS $BUILD_XEN_RUNVARS $arch_runvars \ $hostos_runvars \ -- 2.1.4