From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) (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 81B6B24A08; Mon, 3 Jun 2024 11:39:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=205.220.165.32 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717414784; cv=fail; b=q4wBYxHvu8cEveNHmLQQY+99En/yo3a4aDB68vGvK+LeHr92mB+UIH4C9cZs0haDXs2+NyBY9HYWpqU7i7AZUlA30GIrgfKDXv9D9oQQXfM7TX0MS6aOHJe0WMtTBqK+BpBTkOBfC+oKM1J+kGD5ztbVYDe9hRoRp1hWE21vNBY= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717414784; c=relaxed/simple; bh=qkI/jlHcT21KbZk6DDftpWJfKPh+pvWGEl1yfCwgZ+c=; h=Message-ID:Date:Subject:To:Cc:References:From:In-Reply-To: Content-Type:MIME-Version; b=nS7MyLmQkBimJoAE8B9qMb54otM//LSmFF+J3ijLhRjPSkamkWeiarc4+VOg6e3ReJKyRES6YY9fUOv6W2w+0WPv4em0SJIsxFVTv9n64KICcZLBx2aqi3JcvLym00PJgLb34/CgzKwXF9luQhPuLpPY5iYxLCX8FG9B0gvW1iM= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=oracle.com; spf=pass smtp.mailfrom=oracle.com; arc=fail smtp.client-ip=205.220.165.32 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=oracle.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oracle.com Received: from pps.filterd (m0246617.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 45320nJE029424; Mon, 3 Jun 2024 11:39:08 GMT DKIM-Signature: =?UTF-8?Q?v=3D1;_a=3Drsa-sha256;_c=3Drelaxed/relaxed;_d=3Doracle.com;_h?= =?UTF-8?Q?=3Dcc:content-transfer-encoding:content-type:date:from:in-reply?= =?UTF-8?Q?-to:message-id:mime-version:references:subject:to;_s=3Dcorp-202?= =?UTF-8?Q?3-11-20;_bh=3DEkoTMD07HCxSTEhz/ktl8baaYJ1XX/Rw+8RNhONUcEU=3D;_b?= =?UTF-8?Q?=3DXma4I2iqmCZVAWODDhP0PRNgRQPWKvZ9BOV0TA+uagYwC1qMHZciMb2NoMOv?= =?UTF-8?Q?vF9oij4Q_kg+C/V3/PG/rdF2ns5UYub8MLBDydVveUPaNAM6+d9VwbUvIrGQOKS?= =?UTF-8?Q?qQmiKJQnUe8MES_TzTPGNoj0ag22P23XchKkIB7X3ArCDt37apVWD+nxTyI9v6H?= =?UTF-8?Q?NrVqJ3EwJMrnhEvQMiKx_5F7B6wfKePZbJevhMBBz2egvFjIFQkeufE6XVvz9HY?= =?UTF-8?Q?Nc0IbTNctJemr1XIWWjSQvoCaH_gj8cZVJbQqSUwTqYVVVTFBMID92e7YpnLtLi?= =?UTF-8?Q?PcANezDHSrfUVQPekqeQJu/oirrnf7PJ_2Q=3D=3D_?= Received: from phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta01.appoci.oracle.com [138.1.114.2]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3yfv6u2mj6-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 03 Jun 2024 11:39:07 +0000 Received: from pps.filterd (phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 453AocGc030912; Mon, 3 Jun 2024 11:39:07 GMT Received: from nam10-bn7-obe.outbound.protection.outlook.com (mail-bn7nam10lp2100.outbound.protection.outlook.com [104.47.70.100]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTPS id 3ygrmc1p9g-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 03 Jun 2024 11:39:07 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EVqdm0lFJQMGIq/5L82ltaJYW/KKvAeIW8As659cDcItz3CpqdihzRVnjratZ1k0pt4FupKWpRtdnYGRhNJra/XebKzloIx6HU1AhBJUtIqowylMLHJ5OIdRqeezCw2Z/g09BuQD0MSM8SczF643AeqQraOTcEJruvQ1k2uOigGmH05zjS/WveMPURQVnjGWmKy6QiyfvokEFQgptSiMJw/xsrSbKLVRonrKaamiP7PYEGFtz4DeUY2mwtJxNX7x590E/1Oygslc1iCeEqhgpEenTjQGnoFkk6yFn3IFMYx2NOCqECc7+ydLAsjL/YFU84JCvMEkDACjndREerD04g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=EkoTMD07HCxSTEhz/ktl8baaYJ1XX/Rw+8RNhONUcEU=; b=e2BxCoDSjk/abiqVELZ4I/MO4J2CLUPdHiSRekYw4YOK0WD2s+9S9+o4hOsRNnza7GSbbCq5gRnSmOKseY9wtNrUxyqBh7iMnqwuI1muvACU5oKRW4Uo/doUWG0GAyG7VO6F3DVK+5ON7qYVk+YK1VCtZju5p97p2rhCaWJyaIS0Y9B95FxP2y8AxICFaDhQGKeJ1Q1yShoP6JFmdkXS4QkM+EPgqRkVlHofniyB1EVdjoOf77HhNztmi6BWoEoIKiTUDewKQxCK5Vdg8Iri8eT+DLTBtr8V31OzxY6hrYpPyHyf7j7t/kWWoaL2LwjulFD7Y3Z7fkyTyl1F0+3ZOA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EkoTMD07HCxSTEhz/ktl8baaYJ1XX/Rw+8RNhONUcEU=; b=OU47BqMy/XESL0yk3e2wFRpG2NVVKbTnybNmoWjcfuOePLpHUjA21bWTfUsOvqg2A7hHEjO/3PUbVXtSS9HSD0ShADS8fra9AqLClecxdghXFM0uej/c2OGr4R4Rjwfk+Bl19fRwwj69dDPwkM1zGtTNIxt9MA29R6PC+mvF1Ao= Received: from DM6PR10MB4313.namprd10.prod.outlook.com (2603:10b6:5:212::20) by IA0PR10MB7642.namprd10.prod.outlook.com (2603:10b6:208:481::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7633.24; Mon, 3 Jun 2024 11:39:04 +0000 Received: from DM6PR10MB4313.namprd10.prod.outlook.com ([fe80::4f45:f4ab:121:e088]) by DM6PR10MB4313.namprd10.prod.outlook.com ([fe80::4f45:f4ab:121:e088%5]) with mapi id 15.20.7633.018; Mon, 3 Jun 2024 11:39:04 +0000 Message-ID: Date: Mon, 3 Jun 2024 12:38:57 +0100 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v7 4/9] block: Add core atomic write support To: Hannes Reinecke , axboe@kernel.dk, kbusch@kernel.org, hch@lst.de, sagi@grimberg.me, jejb@linux.ibm.com, martin.petersen@oracle.com, djwong@kernel.org, viro@zeniv.linux.org.uk, brauner@kernel.org, dchinner@redhat.com, jack@suse.cz Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-nvme@lists.infradead.org, linux-fsdevel@vger.kernel.org, tytso@mit.edu, jbongio@google.com, linux-scsi@vger.kernel.org, ojaswin@linux.ibm.com, linux-aio@kvack.org, linux-btrfs@vger.kernel.org, io-uring@vger.kernel.org, nilay@linux.ibm.com, ritesh.list@gmail.com, willy@infradead.org, Himanshu Madhani References: <20240602140912.970947-1-john.g.garry@oracle.com> <20240602140912.970947-5-john.g.garry@oracle.com> <749f9615-2fd2-49a3-9c9e-c725cb027ad3@suse.de> Content-Language: en-US From: John Garry Organization: Oracle Corporation In-Reply-To: <749f9615-2fd2-49a3-9c9e-c725cb027ad3@suse.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-ClientProxiedBy: LO4P265CA0032.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:2ae::18) To DM6PR10MB4313.namprd10.prod.outlook.com (2603:10b6:5:212::20) Precedence: bulk X-Mailing-List: io-uring@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DM6PR10MB4313:EE_|IA0PR10MB7642:EE_ X-MS-Office365-Filtering-Correlation-Id: 5e3e9974-8871-459a-2582-08dc83c1c518 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|1800799015|7416005|376005|366007|921011; X-Microsoft-Antispam-Message-Info: =?utf-8?B?SEoycTBjUTE5QUZnUXhZdXBRZGNkbFNhWUJQOTVuSTZkWWRoRXRNbGhpT0F6?= =?utf-8?B?cGpIZE9uNmN2dTJTWUVjRTFqaGpzc0hZRVVLWFBwaWZvbkV2STVhUy9Ecm5Y?= =?utf-8?B?bUtway9VY2Q0cnozQjVENTNZVExFUEorOFRPd0Q2ZTR5Z29xbGhCOGtMdlBv?= =?utf-8?B?WENuZ2kvckU2bkx6SXZDMUptOXhE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4R1hNays3OTkvc21xeGFCeWIrTEI3UjFTbWxrYUVH?= =?utf-8?B?cjVwT25wVktYNjE4K0p2dFZpY1BkZEVYdVpYWVMxTHdORzZZem80L1hMNUlu?= =?utf-8?B?V0wvK0luUnVQOVBVblRjTEZqS1NDdTdHOVQ3NGFZRmlLWUJlMjdhNEQ2aURh?= =?utf-8?B?VDZPZno4V2tFREJJL2hxT2pDV3dXMUw5eTdXQTF2aDh0eXB5ZXJtd0JKOStk?= =?utf-8?B?WFpUcXM3ZmJxWDNWSEdTVWc4OFpSY3F3VS9HMnFmNkNZSlI4dGFXS3ZvWWdP?= =?utf-8?B?NUVHRXhNSFZ4OWdjSzUzUmxaR3NjVi9oY2hUMGw1OWhlKzlTeExLSzltV3hR?= =?utf-8?B?SVB6NWwrSnA5bnRoZVdhYnlKZGY5NmJaSXlwSERWMUVrOE5Ka0tjZ1prbzkr?= =?utf-8?B?UktzTEhhbGdBYWRIcmxCOHJGYVNDdEtVaExaY0lQRWdDRzNmT2ZSWGliR0Fo?= =?utf-8?B?OU9xMnFQYWJRaU5tWWpvMVNxdnI4VlVWTktIMnNyTFlXbC8wZC9oZ1pVU0VZ?= =?utf-8?B?YnltTFhwZ29mM3V0WGc4YXEvZjRQUWZQOU5Ydk1VYVZYa2VVUlJ4VnBjSW9k?= =?utf-8?B?M3ZqNG1HamZDY05Td3dUV25ubW1kaEMvaTh5akhuSk5BVkdLY01wZTZyd2Ew?= =?utf-8?Q?dnc1KQvQPLKi2C+oRNwPyeheUFAwUuJYnN6icl5?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM6PR10MB4313.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(1800799015)(7416005)(376005)(366007)(921011);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?d0puUWNDTUJYYnByU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yxDJLf2KsGJ1kUsNV744mX6a9VYdgjPw1xG4snvlPXAXXc= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5e3e9974-8871-459a-2582-08dc83c1c518 X-MS-Exchange-CrossTenant-AuthSource: DM6PR10MB4313.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Jun 2024 11:39:04.1191 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: LBFW7QjPhJ1yu4myIomSnUhxbRrRU/+b9sGPDxnaCL+K1us2PmzYF+FPEwJlYDRgHMJAxWDvZy/qL2LJObGNjA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA0PR10MB7642 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-06-03_08,2024-05-30_01,2024-05-17_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 mlxscore=0 malwarescore=0 suspectscore=0 spamscore=0 mlxlogscore=999 adultscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2405010000 definitions=main-2406030097 X-Proofpoint-ORIG-GUID: nLCYjf7xPy-9am-JRuGFDhLmW8vA8vP4 X-Proofpoint-GUID: nLCYjf7xPy-9am-JRuGFDhLmW8vA8vP4 On 03/06/2024 10:26, Hannes Reinecke wrote: >> >> +static bool rq_straddles_atomic_write_boundary(struct request *rq, >> +                    unsigned int front_adjust, >> +                    unsigned int back_adjust) >> +{ >> +    unsigned int boundary = queue_atomic_write_boundary_bytes(rq->q); >> +    u64 mask, start_rq_pos, end_rq_pos; >> + >> +    if (!boundary) >> +        return false; >> + >> +    start_rq_pos = blk_rq_pos(rq) << SECTOR_SHIFT; >> +    end_rq_pos = start_rq_pos + blk_rq_bytes(rq) - 1; >> + >> +    start_rq_pos -= front_adjust; >> +    end_rq_pos += back_adjust; >> + >> +    mask = ~(boundary - 1); >> + >> +    /* Top bits are different, so crossed a boundary */ >> +    if ((start_rq_pos & mask) != (end_rq_pos & mask)) >> +        return true; >> + >> +    return false; >> +} > > But isn't that precisely what 'chunk_sectors' is doing? > IE ensuring that requests never cross that boundary? > > Q1: Shouldn't we rather use/modify/adapt chunk_sectors for this thing? So you are saying that we can re-use blk_chunk_sectors_left() to determine whether merging a bio/req would cross the boundary, right? It seems ok in principle - we would just need to ensure that it is watertight. > Q2: If we don't, shouldn't we align the atomic write boundary to the > chunk_sectors setting to ensure both match up? Yeah, right. But we can only handle what HW tells. The atomic write boundary is only relevant to NVMe. NVMe NOIOB - which we use to set chunk_sectors - is an IO optimization hint, AFAIK. However the atomic write boundary is a hard limit. So if NOIOB is not aligned with the atomic write boundary - which seems unlikely - then the atomic write boundary takes priority. Thanks, John