Received: by 2002:a05:6500:1b8f:b0:1fa:5c73:8e2d with SMTP id df15csp173384lqb; Tue, 28 May 2024 12:01:59 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVgvONgK7275z6npoh8YnkaxjVD40JA4146lNbjdsNc+r3LogJVG5qoUv1PlMTJwZSM+BmFy+2C65HWwOultgrkJF+45Wyqbx3Ts7qD7g== X-Google-Smtp-Source: AGHT+IG6RfZe7X3HdJwewKR7egxAPlibvWhnMSiL6wO10B2b8rggxByyunGEMZHncUeta9vUg2Ql X-Received: by 2002:a05:6a21:7888:b0:1b2:565a:4d1c with SMTP id adf61e73a8af0-1b2565a4dd7mr1492035637.24.1716922918995; Tue, 28 May 2024 12:01:58 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716922918; cv=pass; d=google.com; s=arc-20160816; b=pSslQJm+jQ2lSP9sVdEwHk7oKugHCcUG2V5Bq41aZMix60G0VX18TxSlI7uJu6cvOV UEdz15bOjqtjngcQ3mCtB8r9uTt0bI37st9AHbRbMUePV9C44qMTkUqEcefXU8IyHMuD 6yR/NhAmwFQ4lMxa3sekaot+vy+G4AR78xbo0gbGDCMxxjOQdFyFlxIouVuRLbPtU6oF N89ijGXt44baYrse0Q9pQ6PTS96iED+rhPIUXxAD5G+SKb3RV7Xs+Cdwe+VALyIRdSp8 FxCavox74aHlURoRr4QYsi3WfTf+xAskdVD1da8pDGYO1BB6TqXZU/IxTkxwUTjjPNOZ 2Jdw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:cms-type:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:content-transfer-encoding:content-id :content-language:accept-language:in-reply-to:message-id:date :thread-index:thread-topic:subject:cc:to:from:dkim-signature :dkim-filter; bh=HoBAqzCYnFZWUFCnY9A1juVwqBBHmfP+U4Tja7baPBM=; fh=jR2ZdUHAJteJCURDQO/YPBRnwKAqFV63FIAaVRd0ExE=; b=a4K7A2YkE2kgTm7qrYU13w+vMhg+YUrT3FECnQY/5FkN7k8p2fDk0NxiWY43abza/m cUxA/nTkblNYCsjWTcZfwFx2Md3nFwp2NXl/pZIeVk4rYpNepabX76ojXa2jx+KFsrM7 81CophIvfyBFFhAwQHed3GOn1lY6cfn2LjnazdfOd3CqB7HjGfMuw0ePbeDAmhrKqGFk BiffBFh9ZrkVAhE4W6JZUunTm4Jn4orrpTXGOcPdy1fE4eOLXJfF0q37tocdAUdJ7D6p MHuaQBM+vNrCcDsfNxKngcJFNX2UacmvJ2jqsldcxeVfk6TRIuToFEqM8OJx0eXkfawF aFYA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=ttWKuENY; arc=pass (i=1 spf=pass spfdomain=samsung.com dkim=pass dkdomain=samsung.com dmarc=pass fromdomain=samsung.com); spf=pass (google.com: domain of linux-nfs+bounces-3449-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-nfs+bounces-3449-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id 41be03b00d2f7-6aed2c01ed2si1730174a12.300.2024.05.28.12.01.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 May 2024 12:01:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs+bounces-3449-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=ttWKuENY; arc=pass (i=1 spf=pass spfdomain=samsung.com dkim=pass dkdomain=samsung.com dmarc=pass fromdomain=samsung.com); spf=pass (google.com: domain of linux-nfs+bounces-3449-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-nfs+bounces-3449-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 92ECBB215A8 for ; Tue, 28 May 2024 19:01:56 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 24A0944C8C; Tue, 28 May 2024 19:01:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b="ttWKuENY" X-Original-To: linux-nfs@vger.kernel.org Received: from mailout1.w1.samsung.com (mailout1.w1.samsung.com [210.118.77.11]) (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 944C118AF9 for ; Tue, 28 May 2024 19:01:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=210.118.77.11 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716922912; cv=none; b=b/apylZFg6RyBJ0QmWYNbB5iGtmMazd1vv19yCORY07Okp1fE18VE/N5aWMHKpL+PP/VpM3nIbR2qruls6KbgGoi2+3iupZN1qIm5+1wycB+Pot+ErX/gL0+ocyXVBKs1La0ievbyDJIAkrt3k5i3FTstU5ZFIrebscw1RIaEE0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716922912; c=relaxed/simple; bh=szsGN+n4B4xKlfhfk5iJPwEe9R8vejDxpsv0h4Nf7oU=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:Content-Type: MIME-Version:References; b=DiwOmYuxcvkxDr+GIZU0TYpJq+Zs1cHJ19BJGONdGjFkpJMNqLBIK2RHXiRjAUfAb6iMlPGgB+uEDBedoGRmhWeGROHgS0yS2XDN2tJ033/QVK7gKx/8xIm8zTiYvcxMpa4Po6dTWli6U/tosqMd/8ZdcVj42b6kwPo8wtLnsDc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=samsung.com; spf=pass smtp.mailfrom=samsung.com; dkim=pass (1024-bit key) header.d=samsung.com header.i=@samsung.com header.b=ttWKuENY; arc=none smtp.client-ip=210.118.77.11 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=samsung.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=samsung.com Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout1.w1.samsung.com (KnoxPortal) with ESMTP id 20240528190147euoutp01ab377e899ca9301c2cdf9e1d49c43d92~TvEmh6thl2789927899euoutp01r for ; Tue, 28 May 2024 19:01:47 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.w1.samsung.com 20240528190147euoutp01ab377e899ca9301c2cdf9e1d49c43d92~TvEmh6thl2789927899euoutp01r DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1716922907; bh=HoBAqzCYnFZWUFCnY9A1juVwqBBHmfP+U4Tja7baPBM=; h=From:To:CC:Subject:Date:In-Reply-To:References:From; b=ttWKuENYwmCb0DgUfiqwHZ94nEfyl+MY6nkZ+dzYylzJ3U/4vTcfVzKPEAexDaIXS WNZXgCLBrMqgfV3IDxB/4GGO3OI7ue9uprm+GKCuodGt61zEjhpIok7nOPSVInfreE piRnJvzQC4D80NKg6Zikvn4XN2b/2v4WqhsH8Seo= Received: from eusmges1new.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20240528190146eucas1p2299f2e87c3ab0067b02c0a9a943d9f56~TvElcyrX11587915879eucas1p2a; Tue, 28 May 2024 19:01:46 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges1new.samsung.com (EUCPMTA) with SMTP id E6.06.09624.A1A26566; Tue, 28 May 2024 20:01:46 +0100 (BST) Received: from eusmtrp2.samsung.com (unknown [182.198.249.139]) by eucas1p1.samsung.com (KnoxPortal) with ESMTPA id 20240528190145eucas1p1481c99394a28dc2ce06adb60f411b73d~TvElEqUqg2782127821eucas1p13; Tue, 28 May 2024 19:01:45 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eusmtrp2.samsung.com (KnoxPortal) with ESMTP id 20240528190145eusmtrp2ead789bc1e8f3770264c3bfa9898812a~TvElEMaIP0986809868eusmtrp2U; Tue, 28 May 2024 19:01:45 +0000 (GMT) X-AuditID: cbfec7f2-bfbff70000002598-e6-66562a1a5574 Received: from eusmtip2.samsung.com ( [203.254.199.222]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id B4.22.08810.91A26566; Tue, 28 May 2024 20:01:45 +0100 (BST) Received: from CAMSVWEXC01.scsc.local (unknown [106.1.227.71]) by eusmtip2.samsung.com (KnoxPortal) with ESMTPA id 20240528190145eusmtip2b1c04cf777bbc989ac9b037d53b9c4e0~TvEkwDrWx0757207572eusmtip20; Tue, 28 May 2024 19:01:45 +0000 (GMT) Received: from CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) by CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 28 May 2024 20:01:44 +0100 Received: from CAMSVWEXC01.scsc.local ([::1]) by CAMSVWEXC01.scsc.local ([fe80::7d73:5123:34e0:4f73%13]) with mapi id 15.00.1497.012; Tue, 28 May 2024 20:01:44 +0100 From: Daniel Gomez To: Matthew Wilcox CC: Christoph Hellwig , Trond Myklebust , Anna Schumaker , "linux-nfs@vger.kernel.org" , "linux-fsdevel@vger.kernel.org" , "linux-mm@kvack.org" Subject: Re: [PATCH 1/2] filemap: Convert generic_perform_write() to support large folios Thread-Topic: [PATCH 1/2] filemap: Convert generic_perform_write() to support large folios Thread-Index: AQHasRMEv8C0Tteo9UiuY4wdfWDY+LGsy3MAgAAklwA= Date: Tue, 28 May 2024 19:01:43 +0000 Message-ID: In-Reply-To: Accept-Language: en-US, en-GB Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted Content-Type: text/plain; charset="us-ascii" Content-ID: Content-Transfer-Encoding: quoted-printable Precedence: bulk X-Mailing-List: linux-nfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Brightmail-Tracker: H4sIAAAAAAAAA02SaUwTURSF8zpLpzXVoaC9YpBYlyhCxSVaF8QfRuuORk1cEm1kCihUM6W4 olUjKBqExgWqSEEsAoZgBdOqoFZREVzjAiguWIyCmMqigEJlGEj677v33HvPecmjMGkh4UtF aWMZVquOlpNi/PqDzmdBvgFrNcF3LYTyiN2NK/MKygXKW6UVuPLDFTehfH6nklC6q0OVfzvO k/OEqn+Oq0LVtcsBKmv+MVJlbTEKVTdrDKSq1ToyjFwvnhPOREfFMeykuZvFkY8aHMIdOeJd pw+/Iw0olUpCIgroaXAq5bggCYkpKX0ZQXepDeOLNgQNz22IL1oR2E48JQZWLpQWEbyQi6A1 /TvGCX1TqR/ieK5CcH7gbh4CY24L4gSSngBlFVZhEqIoH3o8/Ciews1gdI4APjbUk9yMN70B /jk+97EPvRF6cq7iPM+CpsYyktvF6bGQ3KHm2hJ6GbyxlPe1Rb3hEg0s10a0H9TndQk5xmgZ 1DozBXx+L8g+dwvjeRj03OCdgA6EJ2+diOdgKLlUhvM8Gr7lvCf4O4FgvtlC8jwTnhQ0C3ie CJasJoyP4wUV6U6cexbQ9SK4fvB0v8F8sBov9rM3ND4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4wQtoHE1qX7WCBsZYkXS+6wQszRkViw+xMbhG0pcXb1WyYIW1ti2cLX zBC3CUqcnPmEZQKjzCwkq2chaZ+FpH0WkvZZSNoXMLKuYhRJLS3OTc8tNtQrTswtLs1L10vO z93ECExB24793LyDcd6rj3qHGJk4GA8xSnAwK4nwnpkUmibEm5JYWZValB9fVJqTWnyI0RQY dBOZpUST84FJMK8k3tDMwNTQxMzSwNTSzFhJnNezoCNRSCA9sSQ1OzW1ILUIpo+Jg1OqgSm6 UcjgmGn3cpfPZWtPJhp2HROY+zCExWxq36zeFzO6zGM6Tx7u8SzaPuXhr6dukQ/Ni4/N4jm1 Ov/ZzEiWlh93N+33mrqOSeK8ccb1fXvNmcPvW1b0rWx7saAqJ1flx4SwCs8aleyFH0L27Cmy D9ZyZnoSvm2ZeqLqid91xYvmmy9/pnpX627Ub9VzlSp35Gesinb4HRBnd8Lt/yXNN+UKhb9/ 5H6QE/m8qao5ec/O799/PtlY9nplYVpx6BVOr3n8xUY90ZIvVYRl1SK1j17U1GJIkrov4TdZ 8xrTQavdBzXrAi8v+R9nMG2zwuO0PRbR70WMLBiVGt215+8/47y68MfG61kCi8+mKG+/nqfE UpyRaKjFXFScCADgEUOcygMAAA== X-CMS-MailID: 20240528190145eucas1p1481c99394a28dc2ce06adb60f411b73d X-Msg-Generator: CA X-RootMTR: 20240528152340eucas1p17ba2ad78d8ea869ef44cdeedb2601f80 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20240528152340eucas1p17ba2ad78d8ea869ef44cdeedb2601f80 References: <20240527163616.1135968-1-hch@lst.de> <20240527163616.1135968-2-hch@lst.de> On Tue, May 28, 2024 at 05:50:44PM +0100, Matthew Wilcox wrote: > On Tue, May 28, 2024 at 03:23:39PM +0000, Daniel Gomez wrote: > > I have the same patch for shmem and large folios tree. That was the las= t piece > > needed for getting better performance results. However, it is also need= ed to > > support folios in the write_begin() and write_end() callbacks. >=20 > I don't think it's *needed*. It's nice! But clearly not necessary > since Christoph made nfs work without doing that. I see. We send anyway the length with bytes and the folio allocated inside write_begin() is retrieved with folio_page(). I did test this patch (+mapping_max_folio_size() patch) for shmem an it wor= ks fine for me. >=20 > > In order to avoid > > making them local to shmem, how should we do the transition to folios i= n these > > 2 callbacks? I was looking into aops->read_folio approach but what do y= ou think? >=20 > See the v2 of buffer_write_operations that I just posted. I was waiting > for feedback from Christoph on the revised method for passing fsdata > around, but I may as well just post a v2 and see what happens. Interesting. I think it makes sense to convert tmpfs to buffered_write_operations as well. Can you add me to the v2 so I can add/re= view it for tmpfs? Thanks=