From patchwork Wed Jul 6 06:40:23 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Janosch Frank X-Patchwork-Id: 12907387 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B11D4CCA473 for ; Wed, 6 Jul 2022 06:41:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229809AbiGFGlc (ORCPT ); Wed, 6 Jul 2022 02:41:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39022 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230186AbiGFGl1 (ORCPT ); Wed, 6 Jul 2022 02:41:27 -0400 Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2492B1A052; Tue, 5 Jul 2022 23:41:25 -0700 (PDT) Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 26660iYx007085; Wed, 6 Jul 2022 06:41:24 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding; s=pp1; bh=rkCFszO4HVcfP442h1YZfRRIBK9XOz9kZfEC8m4Qtm8=; b=sjN+i1i8eO9nC1bu6g4bFkga2P8ZX2vDKXV2h4RBMkBteJlvgLMNOBew0Evx0q1g4Ppd yIn1L8Yayg725BsLO9S1w64JJ+WMYMKA3nmfH8dfcWrN06iGEjnt8T/BelikOPXiEVsm 0cnP2YcahseQjObjkI1y+AYTeuKbM/a845qVVTwAY4cu0J/MKy3Nm5UxYN5gJLRG17cu pqKkJWsZ+qbBK+Ti2I8imMo97ayCzhFX8foPwf/mss32bthexo9R+sSsjOpkCPLVM+UC jt/opiQ3++IUwFrOGRNPtwUwSlenOmqxiZhBUS7EugTdW7qYA7KQ8unEGeSjR573DBYA SQ== Received: from pps.reinject (localhost [127.0.0.1]) by mx0b-001b2d01.pphosted.com (PPS) with ESMTPS id 3h53n8aagf-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 06 Jul 2022 06:41:24 +0000 Received: from m0098419.ppops.net (m0098419.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 2666O4gs004774; Wed, 6 Jul 2022 06:41:23 GMT Received: from ppma03ams.nl.ibm.com (62.31.33a9.ip4.static.sl-reverse.com [169.51.49.98]) by mx0b-001b2d01.pphosted.com (PPS) with ESMTPS id 3h53n8aafv-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 06 Jul 2022 06:41:23 +0000 Received: from pps.filterd (ppma03ams.nl.ibm.com [127.0.0.1]) by ppma03ams.nl.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 2666LhmY025465; Wed, 6 Jul 2022 06:41:21 GMT Received: from b06avi18626390.portsmouth.uk.ibm.com (b06avi18626390.portsmouth.uk.ibm.com [9.149.26.192]) by ppma03ams.nl.ibm.com with ESMTP id 3h4ujsgjbf-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 06 Jul 2022 06:41:21 +0000 Received: from d06av22.portsmouth.uk.ibm.com (d06av22.portsmouth.uk.ibm.com [9.149.105.58]) by b06avi18626390.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 2666e3RW21365160 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 6 Jul 2022 06:40:03 GMT Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id A7B9F4C040; Wed, 6 Jul 2022 06:41:18 +0000 (GMT) Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id BA7184C050; Wed, 6 Jul 2022 06:41:17 +0000 (GMT) Received: from linux6.. (unknown [9.114.12.104]) by d06av22.portsmouth.uk.ibm.com (Postfix) with ESMTP; Wed, 6 Jul 2022 06:41:17 +0000 (GMT) From: Janosch Frank To: kvm390 mailing list Cc: kvm@vger.kernel.org, linux-s390@vger.kernel.org, imbrenda@linux.ibm.com, thuth@redhat.com, seiden@linux.ibm.com, nrb@linux.ibm.com, scgl@linux.ibm.com Subject: [kvm-unit-tests PATCH v2 7/8] s390x: uv-host: Fence against being run as a PV guest Date: Wed, 6 Jul 2022 06:40:23 +0000 Message-Id: <20220706064024.16573-8-frankja@linux.ibm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220706064024.16573-1-frankja@linux.ibm.com> References: <20220706064024.16573-1-frankja@linux.ibm.com> MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: 8rxfiX_LUF3nt3HaRWSWzgu8SJ9SpXQe X-Proofpoint-GUID: YARXUEcjeZyUx_LM8rn-sbsKVyG9zR82 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.883,Hydra:6.0.517,FMLib:17.11.122.1 definitions=2022-07-06_03,2022-06-28_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 phishscore=0 suspectscore=0 clxscore=1015 priorityscore=1501 bulkscore=0 lowpriorityscore=0 impostorscore=0 adultscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2206140000 definitions=main-2207060022 Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org This test checks the UV host API so we should skip it if we're a PV guest. Signed-off-by: Janosch Frank Reviewed-by: Steffen Eiden --- s390x/uv-host.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/s390x/uv-host.c b/s390x/uv-host.c index af3122a8..1ed8ded1 100644 --- a/s390x/uv-host.c +++ b/s390x/uv-host.c @@ -695,6 +695,10 @@ int main(void) report_skip("Ultravisor call facility is not available"); goto done; } + if (!uv_os_is_host()) { + report_skip("This test needs to be run in a UV host environment"); + goto done; + } test_i3(); test_priv();