Message ID | 20180726195429.31960-2-borntraeger@de.ibm.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <kvm-owner@kernel.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 05883174A for <patchwork-kvm@patchwork.kernel.org>; Thu, 26 Jul 2018 19:54:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DE3B22860A for <patchwork-kvm@patchwork.kernel.org>; Thu, 26 Jul 2018 19:54:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D24CE2BD1E; Thu, 26 Jul 2018 19:54:40 +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 74E0428801 for <patchwork-kvm@patchwork.kernel.org>; Thu, 26 Jul 2018 19:54:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731545AbeGZVNA (ORCPT <rfc822;patchwork-kvm@patchwork.kernel.org>); Thu, 26 Jul 2018 17:13:00 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:56396 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731392AbeGZVNA (ORCPT <rfc822;kvm@vger.kernel.org>); Thu, 26 Jul 2018 17:13:00 -0400 Received: from pps.filterd (m0098393.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w6QJsPN6049753 for <kvm@vger.kernel.org>; Thu, 26 Jul 2018 15:54:38 -0400 Received: from e06smtp05.uk.ibm.com (e06smtp05.uk.ibm.com [195.75.94.101]) by mx0a-001b2d01.pphosted.com with ESMTP id 2kfjk0nfry-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for <kvm@vger.kernel.org>; Thu, 26 Jul 2018 15:54:37 -0400 Received: from localhost by e06smtp05.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for <kvm@vger.kernel.org> from <borntraeger@de.ibm.com>; Thu, 26 Jul 2018 20:54:35 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) by e06smtp05.uk.ibm.com (192.168.101.135) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 26 Jul 2018 20:54:32 +0100 Received: from d06av23.portsmouth.uk.ibm.com (d06av23.portsmouth.uk.ibm.com [9.149.105.59]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w6QJsVMK36045022 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 26 Jul 2018 19:54:31 GMT Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 92CA9A4055; Thu, 26 Jul 2018 22:54:44 +0100 (BST) Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 7E547A4057; Thu, 26 Jul 2018 22:54:44 +0100 (BST) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av23.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 26 Jul 2018 22:54:44 +0100 (BST) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id B315B20F5B5; Thu, 26 Jul 2018 21:54:30 +0200 (CEST) From: Christian Borntraeger <borntraeger@de.ibm.com> To: Janosch Frank <frankja@linux.ibm.com>, alex.williamson@redhat.com, Kirti Wankhede <kwankhede@nvidia.com> Cc: KVM <kvm@vger.kernel.org>, Cornelia Huck <cohuck@redhat.com>, Christian Borntraeger <borntraeger@de.ibm.com>, David Hildenbrand <david@redhat.com>, linux-s390@vger.kernel.org, freude@de.ibm.com, schwidefsky@de.ibm.com, pmorel@linux.vnet.ibm.com, Halil Pasic <pasic@linux.ibm.com>, Tony Krowiak <akrowiak@linux.ibm.com>, Michael Mueller <mimu@linux.ibm.com>, buendgen@de.ibm.com, Boris Fiuczynski <fiuczy@linux.vnet.ibm.com>, jjherne@linux.ibm.com, Farhan Ali <alifm@linux.ibm.com>, berrange@redhat.com Subject: [PATCH v7 01/22] s390/zcrypt: Add ZAPQ inline function. Date: Thu, 26 Jul 2018 21:54:08 +0200 X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180726195429.31960-1-borntraeger@de.ibm.com> References: <20180726195429.31960-1-borntraeger@de.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 18072619-0020-0000-0000-000002AC7904 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18072619-0021-0000-0000-000020F88068 Message-Id: <20180726195429.31960-2-borntraeger@de.ibm.com> Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-07-26_05:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=768 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1806210000 definitions=main-1807260204 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: <kvm.vger.kernel.org> X-Mailing-List: kvm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
Series |
vfio-ap: guest dedicated crypto adapters
|
expand
|
diff --git a/drivers/s390/crypto/ap_asm.h b/drivers/s390/crypto/ap_asm.h index 16b59ce5e01d..b22d30aaf810 100644 --- a/drivers/s390/crypto/ap_asm.h +++ b/drivers/s390/crypto/ap_asm.h @@ -69,6 +69,25 @@ static inline struct ap_queue_status ap_rapq(ap_qid_t qid) return reg1; } +/** + * ap_pqap_zapq(): Reset and zeroize adjunct processor queue. + * @qid: The AP queue number + * + * Returns AP queue status structure. + */ +static inline struct ap_queue_status ap_zapq(ap_qid_t qid) +{ + register unsigned long reg0 asm ("0") = qid | (2UL << 24); + register struct ap_queue_status reg1 asm ("1"); + + asm volatile( + ".long 0xb2af0000" /* PQAP(ZAPQ) */ + : "=d" (reg1) + : "d" (reg0) + : "cc"); + return reg1; +} + /** * ap_aqic(): Control interruption for a specific AP. * @qid: The AP queue number