Received: by 2002:a05:6500:1b8f:b0:1fa:5c73:8e2d with SMTP id df15csp39091lqb; Tue, 28 May 2024 08:16:20 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVqbg9zCxF8a28+n4VGr4xqCudmjAG7zMGPPpfx+kI7AysevWZnn3nSeEusEqv1Aguvf3suWApc9wl9hVeynCzz2aeDlJ40aT8sVf9Ldg== X-Google-Smtp-Source: AGHT+IFVgQ14PEZFcOAa8BYtNeJG617PZI3vpEcY9dfWyVjtCFvKbnER8EgR0wBi4w31MMj80dxx X-Received: by 2002:a17:90a:68c7:b0:2bd:aad9:b1e1 with SMTP id 98e67ed59e1d1-2bf5e569b7emr10272460a91.27.1716909379851; Tue, 28 May 2024 08:16:19 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716909379; cv=pass; d=google.com; s=arc-20160816; b=pgPdc7HD4Ki2mTNv1UQqYRC/WkeVEAdVJ+A0cVU1PuF5vaOkUELsOG2FxGy6QpQ45t KWEzXPp+6MUC+OxmJ+UEuG7anPZTMhoPnQTqT01IpCoP+ssw8V9IbVo/O6fWC8TLtZ79 nMzQ6XRSNYuqm0XewflmqcD1Dg+JC7vBHyHP1B0r7uwJ8OrM3BkSYHBTygpX1AEK8o0f 76hZ4DmiPoJYtQTz57+CKYNms+DmTKU5N15vcCYfaMeZyZFDL3s0r8xUJGtYB7Nds34m y4mGKPWH7qsD5o5mi/i7TqoDpxiOX2pXyYaUd85SlB0EkfSdQgYg5LLx+pnqT5NHpwEb 4eMg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:date:message-id:dkim-signature; bh=NI8swxaVE12wOFBr8WuIz5f+Yy1rjMYIj9AuE66Nz6Y=; fh=ykplDbjgC8ZEVCJicuktJs8MCCva6uYHyVKwQBJDw+4=; b=cGSQPguNaiSZAuG4Bgc23ItQyEy2IvBHK9F62AwTTfB+enPg9+5HRs0WKrFSic/BLx dN4aEYeANdw7BQsS3tNgTb51wNWXPpvQFTqnjArQcq9vNGJOEnywRfobzw1hIUD0mzsN Gt+K+M69hTg7M/MEIGjy9jQ9WMc0eKyH90W6XDedjqcTmMr/VMmmWgbY/wquDXKevZLh EGW2OtnXojyxK51vrcGzmaQ2sj62t6MyON4nJRGKQTs87FEsj3dZS8tJpjq+IvvW4Kto DhfHqWKglBz3ZIGI/lAuMD73c2CcPFyFDjS0uVQXff7opkp1/ALRi3lpe0EPnTEK6408 ffDA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=OS5NSDMt; arc=pass (i=1 spf=pass spfdomain=linux.ibm.com dkim=pass dkdomain=ibm.com dmarc=pass fromdomain=linux.ibm.com); spf=pass (google.com: domain of linux-kernel+bounces-192639-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-192639-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id 98e67ed59e1d1-2bf5a306563si8204779a91.127.2024.05.28.08.16.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 May 2024 08:16:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-192639-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=OS5NSDMt; arc=pass (i=1 spf=pass spfdomain=linux.ibm.com dkim=pass dkdomain=ibm.com dmarc=pass fromdomain=linux.ibm.com); spf=pass (google.com: domain of linux-kernel+bounces-192639-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-192639-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 1A9B4281D9A for ; Tue, 28 May 2024 15:15:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D4788171E70; Tue, 28 May 2024 15:14:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b="OS5NSDMt" Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B05C91DFEB; Tue, 28 May 2024 15:14:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=148.163.156.1 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716909257; cv=none; b=EdXWM8/Bvc4n8bru97mdLWVjVhMkH/drNlVBNb8Kn0CJVwAE/fG9u/YPg2v17jRpPS80iwIgGJ51SA71wnIdD500X0DeJqCUquDS8QkaHe14y3T4/8ytXK27zGRU8RIe5VKh8hxM6BlBfgBbJc04ylljRb3TrqmHq4BllXofz8w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716909257; c=relaxed/simple; bh=L3+8/gNXDQi/RFa1Yjb445E/6YHPArHC5sNDeBkVjx4=; h=Message-ID:Date:Subject:To:Cc:References:From:In-Reply-To: Content-Type:MIME-Version; b=ZNdDNY+lQQH3mdEH7C8n8Se3nWeKl0TBrPgpuEXRZtiafPm0aVuE1mKEf8L9z93snY9hf6UiZCxxxZFTj4721dIc/KsG3Gy7zfHGoLrgbJSIjY7GSE3PmFZNlqTr4/0B08qU7viPqOlF1EP4eYOiPGXiBosI0ewlvbXUdY8ZTSk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com; spf=pass smtp.mailfrom=linux.ibm.com; dkim=pass (2048-bit key) header.d=ibm.com header.i=@ibm.com header.b=OS5NSDMt; arc=none smtp.client-ip=148.163.156.1 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.ibm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.ibm.com Received: from pps.filterd (m0353726.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 44SEfHR9031950; Tue, 28 May 2024 15:14:15 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=cc : content-transfer-encoding : content-type : date : from : in-reply-to : message-id : mime-version : references : subject : to; s=pp1; bh=NI8swxaVE12wOFBr8WuIz5f+Yy1rjMYIj9AuE66Nz6Y=; b=OS5NSDMtrqu3RToU5J7qE40yRaCxlGO7YHomExjTl/EbCF1I5JYYh4YZkvGiB7aD/Lp9 Gr88cnhahQ+H1PKjTkgHBcqpjilj11v0OEuxPoMb+LkgqeRzNIDVc+pWgw9U61ybzoOb pcmIyMMGYdernlPHG9UMz3whAi7J9OoJD4uQHcSN4/bsZn7Gy7YoJyzotdNQtND82Lwk Vs3LbH/oALchAwxhGeUxkDOPg1HbznhJvXSGuOnn8ZLZ4sa+JSbGRXJgkLJIwuCDavK5 PCfAwzG+jMmsmgu7C4VH9JKzRPLt56FzAxJ2mgN1ADtp0eOWuHRW6z8AQDBvRd7z2Chw hw== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3ydh46r3ta-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 May 2024 15:14:14 +0000 Received: from m0353726.ppops.net (m0353726.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 44SFDFSD032535; Tue, 28 May 2024 15:14:13 GMT Received: from ppma13.dal12v.mail.ibm.com (dd.9e.1632.ip4.static.sl-reverse.com [50.22.158.221]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3ydh46r3t5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 May 2024 15:14:13 +0000 Received: from pps.filterd (ppma13.dal12v.mail.ibm.com [127.0.0.1]) by ppma13.dal12v.mail.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 44SEVnvH027260; Tue, 28 May 2024 15:14:13 GMT Received: from smtprelay06.dal12v.mail.ibm.com ([172.16.1.8]) by ppma13.dal12v.mail.ibm.com (PPS) with ESMTPS id 3ybvhkq5gv-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 May 2024 15:14:12 +0000 Received: from smtpav04.wdc07v.mail.ibm.com (smtpav04.wdc07v.mail.ibm.com [10.39.53.231]) by smtprelay06.dal12v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 44SFE9JQ23921318 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 28 May 2024 15:14:12 GMT Received: from smtpav04.wdc07v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id D37A75805E; Tue, 28 May 2024 15:14:09 +0000 (GMT) Received: from smtpav04.wdc07v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6FED258045; Tue, 28 May 2024 15:14:08 +0000 (GMT) Received: from [9.61.37.147] (unknown [9.61.37.147]) by smtpav04.wdc07v.mail.ibm.com (Postfix) with ESMTP; Tue, 28 May 2024 15:14:08 +0000 (GMT) Message-ID: Date: Tue, 28 May 2024 11:14:07 -0400 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2 3/3] vfio/pci: Enable PCI resource mmap() on s390 and remove VFIO_PCI_MMAP To: Niklas Schnelle , Gerald Schaefer , Heiko Carstens , Vasily Gorbik , Alexander Gordeev , Christian Borntraeger , Sven Schnelle , Alex Williamson , Gerd Bayer , Jason Gunthorpe Cc: linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org References: <20240523-vfio_pci_mmap-v2-0-0dc6c139a4f1@linux.ibm.com> <20240523-vfio_pci_mmap-v2-3-0dc6c139a4f1@linux.ibm.com> Content-Language: en-US From: Matthew Rosato In-Reply-To: <20240523-vfio_pci_mmap-v2-3-0dc6c139a4f1@linux.ibm.com> Content-Type: text/plain; charset=UTF-8 X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: IFvwoo8vCj9ej9WmLFwgVJO6BULiZRmE X-Proofpoint-GUID: B35FC2cMf25FukWBCjiAhmahQ5cQez-5 Content-Transfer-Encoding: 7bit X-Proofpoint-UnRewURL: 0 URL was un-rewritten Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.650,FMLib:17.12.28.16 definitions=2024-05-28_11,2024-05-28_01,2024-05-17_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 spamscore=0 priorityscore=1501 malwarescore=0 bulkscore=0 impostorscore=0 mlxscore=0 lowpriorityscore=0 mlxlogscore=769 phishscore=0 adultscore=0 clxscore=1011 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2405010000 definitions=main-2405280113 On 5/23/24 7:10 AM, Niklas Schnelle wrote: > With the introduction of memory I/O (MIO) instructions enbaled in commit > 71ba41c9b1d9 ("s390/pci: provide support for MIO instructions") s390 > gained support for direct user-space access to mapped PCI resources. > Even without those however user-space can access mapped PCI resources > via the s390 specific MMIO syscalls. Thus mmap() can and should be > supported on all s390 systems with native PCI. Since VFIO_PCI_MMAP > enablement for s390 would make it unconditionally true and thus > pointless just remove it entirely. > > Link: https://lore.kernel.org/all/c5ba134a1d4f4465b5956027e6a4ea6f6beff969.camel@linux.ibm.com/ > Suggested-by: Jason Gunthorpe > Signed-off-by: Niklas Schnelle Reviewed-by: Matthew Rosato Also sanity tested on s390 with mlx, nvme, ISM over vfio-pci (the latter of which triggers the patch 2 scenario).