From patchwork Tue Jun 26 10:01:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Huth X-Patchwork-Id: 10488549 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 297C860386 for ; Tue, 26 Jun 2018 10:01:31 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2155F28868 for ; Tue, 26 Jun 2018 10:01:31 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 13B2728871; Tue, 26 Jun 2018 10:01:31 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9529228868 for ; Tue, 26 Jun 2018 10:01:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933916AbeFZKB1 (ORCPT ); Tue, 26 Jun 2018 06:01:27 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:50332 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S933870AbeFZKBZ (ORCPT ); Tue, 26 Jun 2018 06:01:25 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 924774067720; Tue, 26 Jun 2018 10:01:24 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-204-33.brq.redhat.com [10.40.204.33]) by smtp.corp.redhat.com (Postfix) with ESMTP id F07032166B5D; Tue, 26 Jun 2018 10:01:22 +0000 (UTC) From: Thomas Huth To: =?UTF-8?q?Radim=20Kr=C4=8Dm=C3=A1=C5=99?= , Paolo Bonzini , kvm@vger.kernel.org Cc: David Hildenbrand , Laurent Vivier , kvm-ppc@vger.kernel.org Subject: [kvm-unit-tests PULL 1/4] s390x: Report missing facilities as "skip", not as "expected failure" Date: Tue, 26 Jun 2018 12:01:16 +0200 Message-Id: <1530007279-26545-2-git-send-email-thuth@redhat.com> In-Reply-To: <1530007279-26545-1-git-send-email-thuth@redhat.com> References: <1530007279-26545-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.7]); Tue, 26 Jun 2018 10:01:24 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.7]); Tue, 26 Jun 2018 10:01:24 +0000 (UTC) for IP:'10.11.54.6' DOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'thuth@redhat.com' RCPT:'' Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Looking at the other architectures, I just recently learnt that it is better to mark missing CPU functionality as SKIP instead of reporting an expected failure. Thus let's replace the report_xfail() calls in the s390x code with report_skip(). Reviewed-by: Janosch Frank Reviewed-by: David Hildenbrand Reviewed-by: Farhan Ali Signed-off-by: Thomas Huth --- s390x/cmm.c | 5 +++-- s390x/gs.c | 5 +++-- s390x/iep.c | 5 +++-- s390x/pfmf.c | 5 +++-- s390x/sthyi.c | 5 +++-- s390x/vector.c | 15 +++++++++------ 6 files changed, 24 insertions(+), 16 deletions(-) diff --git a/s390x/cmm.c b/s390x/cmm.c index 9e6a193..42dfda2 100644 --- a/s390x/cmm.c +++ b/s390x/cmm.c @@ -57,9 +57,10 @@ int main(void) bool has_essa = test_availability(); report_prefix_push("cmm"); - report_xfail("ESSA available", !has_essa, has_essa); - if (!has_essa) + if (!has_essa) { + report_skip("ESSA is not available"); goto done; + } test_priv(); test_params(); diff --git a/s390x/gs.c b/s390x/gs.c index 0cba5dd..bddc2b4 100644 --- a/s390x/gs.c +++ b/s390x/gs.c @@ -158,9 +158,10 @@ int main(void) bool has_gs = test_facility(133); report_prefix_push("gs"); - report_xfail("Guarded storage available", !has_gs, has_gs); - if (!has_gs) + if (!has_gs) { + report_skip("Guarded storage is not available"); goto done; + } test_special(); init(); diff --git a/s390x/iep.c b/s390x/iep.c index e4abc72..8c1ea8f 100644 --- a/s390x/iep.c +++ b/s390x/iep.c @@ -48,9 +48,10 @@ int main(void) bool has_iep = test_facility(130); report_prefix_push("iep"); - report_xfail("DAT IEP available", !has_iep, has_iep); - if (!has_iep) + if (!has_iep) { + report_skip("DAT IEP is not available"); goto done; + } /* Setup DAT 1:1 mapping and memory management */ setup_vm(); diff --git a/s390x/pfmf.c b/s390x/pfmf.c index 838f7bd..2268fd0 100644 --- a/s390x/pfmf.c +++ b/s390x/pfmf.c @@ -125,9 +125,10 @@ int main(void) bool has_edat = test_facility(8); report_prefix_push("pfmf"); - report_xfail("PFMF available", !has_edat, has_edat); - if (!has_edat) + if (!has_edat) { + report_skip("PFMF is not available"); goto done; + } test_priv(); /* Force the buffer pages in */ diff --git a/s390x/sthyi.c b/s390x/sthyi.c index 0b1b4ec..16b8c14 100644 --- a/s390x/sthyi.c +++ b/s390x/sthyi.c @@ -150,9 +150,10 @@ int main(void) report_prefix_push("sthyi"); /* Test for availability */ - report_xfail("STHYI available", !has_sthyi, has_sthyi); - if (!has_sthyi) + if (!has_sthyi) { + report_skip("STHYI is not available"); goto done; + } /* Test register/argument checking. */ test_exception_addr(); diff --git a/s390x/vector.c b/s390x/vector.c index 05b3eca..d40f647 100644 --- a/s390x/vector.c +++ b/s390x/vector.c @@ -60,9 +60,10 @@ static void test_ext1_nand(void) __uint128_t a,b,c; } prm __attribute__((aligned(16))); - report_xfail("Vector extensions 1 available", !has_vext, has_vext); - if (!has_vext) + if (!has_vext) { + report_skip("Vector extensions 1 is not available"); return; + } memset(&prm, 0xff, sizeof(prm)); @@ -85,9 +86,10 @@ static void test_bcd_add(void) __uint128_t a,b,c; } prm __attribute__((aligned(16))); - report_xfail("Vector BCD extensions available", !has_bcd, has_bcd); - if (!has_bcd) + if (!has_bcd) { + report_skip("Vector BCD extensions is not available"); return; + } prm.c = 0; prm.a = prm.b = 0b001000011100; @@ -118,9 +120,10 @@ int main(void) bool has_vregs = test_facility(129); report_prefix_push("vector"); - report_xfail("Basic vector facility available", !has_vregs, has_vregs); - if (!has_vregs) + if (!has_vregs) { + report_skip("Basic vector facility is not available"); goto done; + } init(); test_add();