Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp126943iob; Tue, 17 May 2022 21:07:36 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzMMC3SqdlrQm5zgV/WuP18k8DDPTnfZ5131bmvTJ4J+JUyTf4ASVWOVOP+prgl7HBr2MZ7 X-Received: by 2002:a17:902:758a:b0:15e:ef4f:fed5 with SMTP id j10-20020a170902758a00b0015eef4ffed5mr25388508pll.1.1652846856164; Tue, 17 May 2022 21:07:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652846856; cv=none; d=google.com; s=arc-20160816; b=vy+NI/IziR/neq3RL5JVpHV5Z1+54/1s+5rR9Wtyz5XobH58CyhLiB2zsRLIui0/q9 3MgtY97pXJrBzhCgnzrWhZ1bU/960aqw+H5cH4yz1+SBci9wxoeAk/AzGKH6FsSI70rw mBfInbkAgohKucAG+SycsbIWVO4JQAEoxBVLyJt9RG+St4Ou1MlT+mrvZ8FUK8qB9VjN zxY83tpcizp5UszJQgO6hjNPn0Eh5srVqAVu331LYsRKdjrUC5fPpKJjnv/izzcJBfVo 3rwoglXzURddgaAx744uJ0uAbQN5TsgWVj4GYV4X/Ct5vQgdp+0pdIfJA1Bmi+xOfE1t SSQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:to:content-language:subject:user-agent:mime-version:date :message-id:dkim-signature; bh=D+GhBB0E/wAZK8YXdh6KmBxD6w1txXvNGrzF9TuYaik=; b=juymTOoJBMUCA9HT4OOt44qh7H8ef6stNwVkNRKxXbp7b1omLwG9RRFTeoP75M0FEx cxQsfctx06JkBlVdOTkKuTfluklWaHpIy1yHt5nmpiKWqmNYi/8m4J0mW6MbtMSZ1+tk nE8IysT+lYonuq5xJ+vyuZamQ2A1YL05FRsRTKJmkPMjk5w8fSliuUFRT12zjgbjp8J1 A2L9G7Utxn0ATvKgUD2IUbL55UTZ97X13QaTqTyqiKiQIE3mFUpIU6ZShseDHC/q6F33 95Hw5j9atFQfrMDwbRX7xiK4HNu0z8owBkde3bAWJCdrEE+xBINO8k4UZIJRnEla6gOr 0+5g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b="Z/5JS5xR"; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 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 lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id o26-20020a63921a000000b003c6a5d55413si1262658pgd.114.2022.05.17.21.07.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 May 2022 21:07:36 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b="Z/5JS5xR"; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 586D69CF5F; Tue, 17 May 2022 20:40:44 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231473AbiEQIi5 (ORCPT + 99 others); Tue, 17 May 2022 04:38:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57506 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232605AbiEQIiv (ORCPT ); Tue, 17 May 2022 04:38:51 -0400 Received: from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2102C43AE3; Tue, 17 May 2022 01:38:50 -0700 (PDT) Received: from pps.filterd (m0098420.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 24H8DOhR028628; Tue, 17 May 2022 08:38:45 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=message-id : date : mime-version : subject : to : references : from : in-reply-to : content-type : content-transfer-encoding; s=pp1; bh=D+GhBB0E/wAZK8YXdh6KmBxD6w1txXvNGrzF9TuYaik=; b=Z/5JS5xRoSL0aq/ar4f/bGGm8bt6Lir2Ygge1c4Zr78+JldRpqVIQzovqFYfjGPvKaqg 4NQq8hm958Bh2pIFYdLMB9AuFJ4gLJnpy7zuxnNr/lVevLoqXKTfRSHiJWMxvSiVMPZ9 WZMxyR7Xr6q3y75RBH2z6wegsFZmwFa2JLykhxKv5F/RGvJqoyrVgcSrFI6qbO8EtbIQ uLyvEOrYnl7eN+EZs7ebXOwP4hykd8mfEB2tnAUWrVSMGek9WC31kS0aqtzIgUJ7nQBa zNwtsdvFi62UNtsRdop2qcOoFGjs6TEh2jPyjEk7vWlq86vOZtVKsQXpevwfNspYerHC Bg== Received: from pps.reinject (localhost [127.0.0.1]) by mx0b-001b2d01.pphosted.com (PPS) with ESMTPS id 3g480fghsk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 17 May 2022 08:38:45 +0000 Received: from m0098420.ppops.net (m0098420.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 24H8DqER029695; Tue, 17 May 2022 08:38:44 GMT Received: from ppma06ams.nl.ibm.com (66.31.33a9.ip4.static.sl-reverse.com [169.51.49.102]) by mx0b-001b2d01.pphosted.com (PPS) with ESMTPS id 3g480fghrw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 17 May 2022 08:38:44 +0000 Received: from pps.filterd (ppma06ams.nl.ibm.com [127.0.0.1]) by ppma06ams.nl.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 24H8bvXa027381; Tue, 17 May 2022 08:38:42 GMT Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by ppma06ams.nl.ibm.com with ESMTP id 3g23pjbvu5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 17 May 2022 08:38:42 +0000 Received: from d06av23.portsmouth.uk.ibm.com (d06av23.portsmouth.uk.ibm.com [9.149.105.59]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 24H8cdM118809302 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 17 May 2022 08:38:39 GMT Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 71769A404D; Tue, 17 May 2022 08:38:39 +0000 (GMT) Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id F0475A4053; Tue, 17 May 2022 08:38:38 +0000 (GMT) Received: from [9.145.157.61] (unknown [9.145.157.61]) by d06av23.portsmouth.uk.ibm.com (Postfix) with ESMTP; Tue, 17 May 2022 08:38:38 +0000 (GMT) Message-ID: Date: Tue, 17 May 2022 10:38:38 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH v4 1/2] drivers/s390/char: Add Ultravisor io device Content-Language: en-US To: Steffen Eiden , Greg KH , Heiko Carstens , Alexander Gordeev , Shuah Khan , Christian Borntraeger , Claudio Imbrenda , David Hildenbrand , Nico Boehr , linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, kvm@vger.kernel.org References: <20220510144724.3321985-1-seiden@linux.ibm.com> <20220510144724.3321985-2-seiden@linux.ibm.com> From: Janosch Frank In-Reply-To: <20220510144724.3321985-2-seiden@linux.ibm.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: IvePSA45A9JdpwUE2QI7mL7_ws8NBJoo X-Proofpoint-GUID: eMf4ulNRCT_R6hvh_c7skZQMk-Knyiwi X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.858,Hydra:6.0.486,FMLib:17.11.64.514 definitions=2022-05-17_01,2022-05-16_02,2022-02-23_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 malwarescore=0 mlxlogscore=999 clxscore=1011 spamscore=0 mlxscore=0 adultscore=0 priorityscore=1501 bulkscore=0 suspectscore=0 phishscore=0 lowpriorityscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2202240000 definitions=main-2205170051 X-Spam-Status: No, score=-4.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 On 5/10/22 16:47, Steffen Eiden wrote: > This patch adds a new miscdevice to expose some Ultravisor functions > to userspace. Userspace can send IOCTLs to the uvdevice that will then > emit a corresponding Ultravisor Call and hands the result over to > userspace. The uvdevice is available if the Ultravisor Call facility is > present. > Userspace can call the Retrieve Attestation Measurement > Ultravisor Call using IOCTLs on the uvdevice. > > The uvdevice will do some sanity checks first. > Then, copy the request data to kernel space, build the UVCB, > perform the UV call, and copy the result back to userspace. > > Signed-off-by: Steffen Eiden > Reviewed-by: Janosch Frank I'd like to pick this if I'm allowed to fix the two white space problems below. > --- > MAINTAINERS | 2 + > arch/s390/include/asm/uv.h | 23 ++- > arch/s390/include/uapi/asm/uvdevice.h | 51 +++++ > drivers/s390/char/Kconfig | 10 + > drivers/s390/char/Makefile | 1 + > drivers/s390/char/uvdevice.c | 264 ++++++++++++++++++++++++++ > 6 files changed, 350 insertions(+), 1 deletion(-) > create mode 100644 arch/s390/include/uapi/asm/uvdevice.h > create mode 100644 drivers/s390/char/uvdevice.c > > +#endif /* __S390_ASM_UVDEVICE_H */ There are two spaces between the "endif" and the "/" > diff --git a/drivers/s390/char/Kconfig b/drivers/s390/char/Kconfig > index 6cc4b19acf85..e9b9902abbaf 100644 > --- a/drivers/s390/char/Kconfig > +++ b/drivers/s390/char/Kconfig > @@ -100,6 +100,16 @@ config SCLP_OFB > This option enables the Open-for-Business interface to the s390 > Service Element. > [...] > + * uvio_attestation() does a Retrieve Attestation Measurement Ultravisor Call. Double space > + * It verifies that the given userspace addresses are valid and request sizes > + * are sane. Every other check is made by the Ultravisor (UV) and won't result > + * in a negative return value. It copies the input to kernelspace, builds the > + * request, sends the UV-call, and copies the result to userspace. > + *