From patchwork Thu Mar 23 10:39:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Janosch Frank X-Patchwork-Id: 13185488 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 C6078C76195 for ; Thu, 23 Mar 2023 10:43:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231640AbjCWKnt (ORCPT ); Thu, 23 Mar 2023 06:43:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45412 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230021AbjCWKnZ (ORCPT ); Thu, 23 Mar 2023 06:43:25 -0400 Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7A75E3B3F5 for ; Thu, 23 Mar 2023 03:40:26 -0700 (PDT) Received: from pps.filterd (m0098416.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 32N9DlIt005463 for ; Thu, 23 Mar 2023 10:40:23 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=vJPipkO1S/+VzvZm4zDnIhoEA9gh+lR9TdcD9EFzy4I=; b=l/fNn+t7zhhbx1Wdowy0/gQfRGblKsxxMV9UqVfC6ISgrTadGwjGKHlLTGASV9ZxFAHv zsTvS0R7P/HaSeEimMJdqYi0xQnNOVjkjacWIHQew1NvAqltG1uwpS1h+N1XkgAMR4rV vXguW1X22/HktNs9m2+aXtrK7VydzhQe8iNig5XPqyv6fHmYfi3oo4pXGWBOz7/y6Vc9 Ix8ma6yiuD1jER34T2M4Tac/Ji/3RN7PBg8U5taNrOGJfIKFAjjyCl1f4B/ZHK742RyK Vfw/pavtiUdCo6/ksVbPhZO9ecL8LuxvoD7bOrrDkKn9YhM54oZ7q8hW8VS9dmG1K4lE 1g== Received: from pps.reinject (localhost [127.0.0.1]) by mx0b-001b2d01.pphosted.com (PPS) with ESMTPS id 3pgkxusyre-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 23 Mar 2023 10:40:22 +0000 Received: from m0098416.ppops.net (m0098416.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 32NAB2l4008840 for ; Thu, 23 Mar 2023 10:40:21 GMT Received: from ppma01fra.de.ibm.com (46.49.7a9f.ip4.static.sl-reverse.com [159.122.73.70]) by mx0b-001b2d01.pphosted.com (PPS) with ESMTPS id 3pgkxusyqs-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 23 Mar 2023 10:40:21 +0000 Received: from pps.filterd (ppma01fra.de.ibm.com [127.0.0.1]) by ppma01fra.de.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 32MKq8rq001485; Thu, 23 Mar 2023 10:40:19 GMT Received: from smtprelay07.fra02v.mail.ibm.com ([9.218.2.229]) by ppma01fra.de.ibm.com (PPS) with ESMTPS id 3pd4x6e1xn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 23 Mar 2023 10:40:19 +0000 Received: from smtpav03.fra02v.mail.ibm.com (smtpav03.fra02v.mail.ibm.com [10.20.54.102]) by smtprelay07.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 32NAeFvx23462516 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 23 Mar 2023 10:40:16 GMT Received: from smtpav03.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id CEC3F2007C; Thu, 23 Mar 2023 10:40:15 +0000 (GMT) Received: from smtpav03.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 349672006E; Thu, 23 Mar 2023 10:40:15 +0000 (GMT) Received: from linux6.. (unknown [9.114.12.104]) by smtpav03.fra02v.mail.ibm.com (Postfix) with ESMTP; Thu, 23 Mar 2023 10:40:15 +0000 (GMT) From: Janosch Frank To: kvm@vger.kernel.org, nrb@linux.ibm.com Cc: thuth@redhat.com, imbrenda@linux.ibm.com Subject: [kvm-unit-tests PATCH 2/8] s390x: uv-host: Check for sufficient amount of memory Date: Thu, 23 Mar 2023 10:39:07 +0000 Message-Id: <20230323103913.40720-3-frankja@linux.ibm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230323103913.40720-1-frankja@linux.ibm.com> References: <20230323103913.40720-1-frankja@linux.ibm.com> MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: t3BQYrLahqT0NBJUzTrmpdQH02nqO6dH X-Proofpoint-ORIG-GUID: c8bPZ91r_hMy7O-9ogANbunNXwRYXFJJ X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.254,Aquarius:18.0.942,Hydra:6.0.573,FMLib:17.11.170.22 definitions=2023-03-22_21,2023-03-22_01,2023-02-09_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 bulkscore=0 mlxlogscore=999 adultscore=0 lowpriorityscore=0 spamscore=0 mlxscore=0 phishscore=0 impostorscore=0 priorityscore=1501 malwarescore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2303150002 definitions=main-2303230080 Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org The UV init storage needs to be above 2G so we need a little over 2G of memory when running the test. Signed-off-by: Janosch Frank Reviewed-by: Nico Boehr --- s390x/uv-host.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/s390x/uv-host.c b/s390x/uv-host.c index 68de47e7..e38a9913 100644 --- a/s390x/uv-host.c +++ b/s390x/uv-host.c @@ -715,6 +715,17 @@ int main(void) test_invalid(); test_uv_uninitialized(); test_query(); + + /* + * Some of the UV memory needs to be allocated with >31 bit + * addresses which means we need a lot more memory than other + * tests. + */ + if (get_ram_size() < (SZ_1M * 2200UL)) { + report_skip("Not enough memory. This test needs about 2200MB of memory"); + goto done; + } + test_init(); setup_vmem();