Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp3990816iog; Tue, 28 Jun 2022 07:00:15 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tReOEI2LLi/5VtoHJNXYOV2TYmt6NCjNiVciLjjJCwc4hoHTRTYjGcMqSPpZ32FlL6qC7S X-Received: by 2002:a17:90b:1c87:b0:1ca:f4e:4fbe with SMTP id oo7-20020a17090b1c8700b001ca0f4e4fbemr27927891pjb.159.1656424815541; Tue, 28 Jun 2022 07:00:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656424815; cv=none; d=google.com; s=arc-20160816; b=QlhNDbPhF9VcgAjUGwLkuEMoiunrok68eTipA4A2Q0V/vuYshRRhjz3/i8oUwrYIyT ZVYhyqINFE/3expncAACZ972/ljbBrfrvjAuj+vb/UeW/G3OxBQckwZZblwswCHDJrTL EZlzd1+NYbBXkJMJj+ILeVItGyfCoy5TcHjLv6I4etjAlKOYxTQY785TAsUvtv04BEKK 0rrAugUFV9X9f2gnTPE2uQgklAkzWEOFuep1Kb3mRHpRD95BbzBo/MJ8qIIZUvo2igkA XbA2s8gtP/iN68UGgP7QZxVoFk4J6kTM6da+oH1R770bI4Qvdk3taljWHssmdC7plyXh +S5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=qO6cb+ByqwJp4l6+y4GEFWMOf4S4opzTJA7p3TZWIAA=; b=PioBKrCn2cRg0cTYO+KBeMl4RgtuPJvPVfWoX99/6I8R8jeLiU5thGkQxnlgKm3jeX p5dobTo5maFMcAMd/P0OO53UoTlXRDXETWrs7V4HtduYmJCRUC5JxG2lTO/HfPgFpawR BuD4eYrA6jobPeZ6SN3P4crLyjZqrZcHEFqiAR9sD9YxlCYTTug4hzhliPL6rCEzRu5A PztR4lE0OQ8vYpTul4d2zWNjP0Tnlz1GUXrx3IKqV3IxYF4Wrc5rdVOnG8PV21RG2K9J EDPkubf/XU3cbpk7V0oOipvIDxdnsGtqEJeFfQy5RUkHVX8sTLplNBvQhRC/xoiuo602 PyTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=kA0+GXTX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t139-20020a635f91000000b00411415b1092si4932258pgb.278.2022.06.28.07.00.02; Tue, 28 Jun 2022 07:00:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=kA0+GXTX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345757AbiF1N6f (ORCPT + 99 others); Tue, 28 Jun 2022 09:58:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33658 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346926AbiF1N4l (ORCPT ); Tue, 28 Jun 2022 09:56:41 -0400 Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 459AD338B5; Tue, 28 Jun 2022 06:56:33 -0700 (PDT) Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 25SDlRCe019214; Tue, 28 Jun 2022 13:56:33 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=qO6cb+ByqwJp4l6+y4GEFWMOf4S4opzTJA7p3TZWIAA=; b=kA0+GXTXHmAyNztNH+Xtst/ERkB10VEJB0JiVOWU91l54YMqXCogG4GmvCEqqu9HnEm3 /vk1TsO5UNVmP9VmMe+Ez16edhqVj0jeRGa3aYhGrYUsLvPLpI+f+JHX/6Tz2SSegjmk P37oB2CixVKzxC7qTaQrFg03bjKcyvHE9rnZbCp12yW56tvkiqNn6DLRfbJ8QvxZbZnK ilsxcqOOceh2uPeQ1idx3Z0fUBc1YlU/yZQsJ+rQGT4QOm4PXXRYf9dgiW/jojeYSsZ3 mSn4eaMvpBOV5+IDJNIXrp983nz82K/7UmsLe+ckd7LcNj1eQQyGlcTfWHV0I3l81yMc Tg== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3h02u20amq-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 Jun 2022 13:56:32 +0000 Received: from m0098410.ppops.net (m0098410.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 25SDmepa027743; Tue, 28 Jun 2022 13:56:32 GMT Received: from ppma06fra.de.ibm.com (48.49.7a9f.ip4.static.sl-reverse.com [159.122.73.72]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3h02u20ake-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 Jun 2022 13:56:32 +0000 Received: from pps.filterd (ppma06fra.de.ibm.com [127.0.0.1]) by ppma06fra.de.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 25SDol7o030153; Tue, 28 Jun 2022 13:56:30 GMT Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by ppma06fra.de.ibm.com with ESMTP id 3gwsmhuq8k-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 Jun 2022 13:56:29 +0000 Received: from d06av22.portsmouth.uk.ibm.com (d06av22.portsmouth.uk.ibm.com [9.149.105.58]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 25SDuQaY23331182 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 28 Jun 2022 13:56:26 GMT Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 92ECC4C040; Tue, 28 Jun 2022 13:56:26 +0000 (GMT) Received: from d06av22.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 2EBF04C044; Tue, 28 Jun 2022 13:56:26 +0000 (GMT) Received: from p-imbrenda.boeblingen.de.ibm.com (unknown [9.152.224.40]) by d06av22.portsmouth.uk.ibm.com (Postfix) with ESMTP; Tue, 28 Jun 2022 13:56:26 +0000 (GMT) From: Claudio Imbrenda To: kvm@vger.kernel.org Cc: borntraeger@de.ibm.com, frankja@linux.ibm.com, thuth@redhat.com, pasic@linux.ibm.com, david@redhat.com, linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org, scgl@linux.ibm.com, mimu@linux.ibm.com, nrb@linux.ibm.com Subject: [PATCH v12 15/18] KVM: s390: pv: add KVM_CAP_S390_PROTECTED_ASYNC_DISABLE Date: Tue, 28 Jun 2022 15:56:16 +0200 Message-Id: <20220628135619.32410-16-imbrenda@linux.ibm.com> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220628135619.32410-1-imbrenda@linux.ibm.com> References: <20220628135619.32410-1-imbrenda@linux.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-TM-AS-GCONF: 00 X-Proofpoint-GUID: qHPZnZ8KrJOhohkUqpVejWMiCwcULhnJ X-Proofpoint-ORIG-GUID: rG296tdDKIigg_iNNM9yVpPqEQmNEUHU 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-06-28_07,2022-06-28_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 bulkscore=0 malwarescore=0 phishscore=0 priorityscore=1501 mlxlogscore=598 suspectscore=0 lowpriorityscore=0 impostorscore=0 mlxscore=0 spamscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2204290000 definitions=main-2206280057 X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add KVM_CAP_S390_PROTECTED_ASYNC_DISABLE to signal that the KVM_PV_ASYNC_DISABLE and KVM_PV_ASYNC_DISABLE_PREPARE commands for the KVM_S390_PV_COMMAND ioctl are available. Signed-off-by: Claudio Imbrenda Reviewed-by: Nico Boehr --- arch/s390/kvm/kvm-s390.c | 3 +++ include/uapi/linux/kvm.h | 1 + 2 files changed, 4 insertions(+) diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c index 661cf9b6d55a..0b1e45668682 100644 --- a/arch/s390/kvm/kvm-s390.c +++ b/arch/s390/kvm/kvm-s390.c @@ -606,6 +606,9 @@ int kvm_vm_ioctl_check_extension(struct kvm *kvm, long ext) case KVM_CAP_S390_BPB: r = test_facility(82); break; + case KVM_CAP_S390_PROTECTED_ASYNC_DISABLE: + r = async_destroy && is_prot_virt_host(); + break; case KVM_CAP_S390_PROTECTED: r = is_prot_virt_host(); break; diff --git a/include/uapi/linux/kvm.h b/include/uapi/linux/kvm.h index 01b25cbb8b5c..0dadb04fbc47 100644 --- a/include/uapi/linux/kvm.h +++ b/include/uapi/linux/kvm.h @@ -1157,6 +1157,7 @@ struct kvm_ppc_resize_hpt { #define KVM_CAP_VM_TSC_CONTROL 214 #define KVM_CAP_SYSTEM_EVENT_DATA 215 #define KVM_CAP_ARM_SYSTEM_SUSPEND 216 +#define KVM_CAP_S390_PROTECTED_ASYNC_DISABLE 225 #ifdef KVM_CAP_IRQ_ROUTING -- 2.36.1