From patchwork Thu Jun 14 18:34:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Huth X-Patchwork-Id: 10464983 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 6582360532 for ; Thu, 14 Jun 2018 18:34:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5324528B3C for ; Thu, 14 Jun 2018 18:34:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 45E6B28BD7; Thu, 14 Jun 2018 18:34:07 +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 D52BC28B3C for ; Thu, 14 Jun 2018 18:34:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754758AbeFNSeE (ORCPT ); Thu, 14 Jun 2018 14:34:04 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:47880 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754660AbeFNSeD (ORCPT ); Thu, 14 Jun 2018 14:34:03 -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 553797D83A; Thu, 14 Jun 2018 18:34:03 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-116-79.ams2.redhat.com [10.36.116.79]) by smtp.corp.redhat.com (Postfix) with ESMTP id 9F73220284D6; Thu, 14 Jun 2018 18:34:02 +0000 (UTC) From: Thomas Huth To: kvm@vger.kernel.org Cc: David Hildenbrand , frankja@linux.ibm.com Subject: [kvm-unit-tests PATCH] s390x: Report missing facilities as "skip", not as "expected failure" Date: Thu, 14 Jun 2018 20:34:01 +0200 Message-Id: <1529001241-4187-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.2]); Thu, 14 Jun 2018 18:34:03 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.2]); Thu, 14 Jun 2018 18:34:03 +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(). Signed-off-by: Thomas Huth Reviewed-by: Janosch Frank Reviewed-by: David Hildenbrand Reviewed-by: Farhan Ali --- 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();