Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2732087pxb; Tue, 19 Jan 2021 04:56:03 -0800 (PST) X-Google-Smtp-Source: ABdhPJwvp5StTv8sh7iKsGvZxRgmeFUZQU8G8skhikjCJzPNeLeO6mWB7hNzUJaUAKkbNx9oIWmU X-Received: by 2002:aa7:c583:: with SMTP id g3mr495780edq.357.1611060962931; Tue, 19 Jan 2021 04:56:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611060962; cv=none; d=google.com; s=arc-20160816; b=jwDWIJeRelv4FbtsGY0/mjtx4Gdt1mKDr8R6F2VwXu5aMSojPpTPhME9Cv7kcagLPG t7k+uxSRf6QGdyDG/WuXb7ooShIJbt5E+ii/G4aeH856zPyAycWv9SxWi9+6HyEFxuwk +FNXCFDfnb2kgEQoe5DjjYbVdlmLhNMeXk90YYqdZ+8KJquHHIp293tak5yJXI+AjHxT 870tbxjvqy399+zpAT2RGXXVtLymhxguu19a8RB2ejkIasitIbceMwIFOGwhSTFrobTJ ikpRZv30Yrabm7Yt3XEgyhXItU0m6KqiSxW434UmFI/RiJND2dVl0EUK8mnkSNXQNnTG eEGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=dy3egPV1ka/EkZOaPATc7EsNx/78Zw3FYs2vUZuq9OU=; b=u04QiDvsQrr1PDOgFvwBXtpkfd+yQzolXsg//IS+A/N3ETcHjE8b8jhu4/vjSbkVMs A4w8TBp4ixoY/H6ISZ8Gd7L4uNDkKQXk6BaYdMbdjBo+zBtTlfMCEZzMI0x19cXvL2pg tDV9kZA31ZElgJ9K0slBnnK0m2A2fOQYfJpyzYBZTiHn+iJpBQDAZAYePly/R5JyqNy5 f72x7IgLX/Lpbvznte4zWrCYIc++zDhJY+od3cNbhWXZXob14xaAmkRbo9lQwS22K/sP JdJSocMaQ6ZQxzxQ83nSKysXT6kIGfwjBbA0l6GDkhwrgfFkItdRtzSnn6WdwrXTLk36 +h5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@android.com header.s=20161025 header.b=evsZNBcd; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=android.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dk22si7407062ejb.736.2021.01.19.04.55.39; Tue, 19 Jan 2021 04:56:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@android.com header.s=20161025 header.b=evsZNBcd; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=android.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2393346AbhASMlK (ORCPT + 99 others); Tue, 19 Jan 2021 07:41:10 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56154 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405042AbhASMfK (ORCPT ); Tue, 19 Jan 2021 07:35:10 -0500 Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1C50BC061575 for ; Tue, 19 Jan 2021 04:34:27 -0800 (PST) Received: by mail-wr1-x434.google.com with SMTP id 6so12289928wri.3 for ; Tue, 19 Jan 2021 04:34:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=android.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=dy3egPV1ka/EkZOaPATc7EsNx/78Zw3FYs2vUZuq9OU=; b=evsZNBcduUb7qJp65mS6n4i2QPR+xQy4POZWrTwxPx77Y6MwQKoj/e/V8dpgSrQkKf pnDA5+cIudYS6Id24AKDGGnBLZArqWXyf4SpAvDO8ihFDSjmi5S8OS0IXsdeSgEfQhVC dZMyTqT8W3OtlFHmN/j93o2mUX/eBtQObonmgz+5ne8jDjN8gQMebwkmePLHxZrFbXVX LA2rabkrQxfIG2aPLngyRY6T3k4T9zGraCI39n7CokXsRaw2g+L/8mlEHMSR1w7Qnb8U CIWB6r3Znl9bmzXvyI6STcehT80Dga5yGhuJo8zimw+AQGK7+x30Tp88mE3chkhUebPZ BtYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=dy3egPV1ka/EkZOaPATc7EsNx/78Zw3FYs2vUZuq9OU=; b=m8+ZWqjUnvbaiVl9hUWFmweWzwLxNrpBKom3wLXtj3kAi5i0njJ9//J1n924NyNWD0 mVm4BwXlcBsmdsvX5W2IgdrTFNsmPAu/OmfRYZL95+7CA+QjLxb+zvGjNdH6CGjLGEna Arf89lQqR/mHhwPEZwuPKPEAKts/EVODHqqSCal18hLDhPxD3YQHaBLzst2KuNuMFsG4 AtYPQlV7e0xUVRhWI+Nol5DcSSQ1RIzDRU3Q/EmMbFC91TIwPHGHyfNNyJbX3C5SwLr9 fn582ouQDtXVq8VxukMCVIpk6tsD/Lr6NX0f3mQhLKOmAkKxz7Uzdk9ZOZeN6ujzOjRs YyAQ== X-Gm-Message-State: AOAM5302Lx1qI5U90vCiBdlbE4NPEMJqpFx+hmnx7ESQT1tU7ghTDVgl /AKyU8BzMYXt75SOCn1sDqAuhw== X-Received: by 2002:a5d:44c8:: with SMTP id z8mr4160714wrr.366.1611059665813; Tue, 19 Jan 2021 04:34:25 -0800 (PST) Received: from google.com ([2a00:79e0:d:210:41d4:8c90:d38:455d]) by smtp.gmail.com with ESMTPSA id a17sm36904463wrs.20.2021.01.19.04.34.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Jan 2021 04:34:25 -0800 (PST) Date: Tue, 19 Jan 2021 12:34:23 +0000 From: Alessio Balsini To: Rokudo Yan Cc: balsini@android.com, akailash@google.com, amir73il@gmail.com, axboe@kernel.dk, bergwolf@gmail.com, duostefano93@gmail.com, dvander@google.com, fuse-devel@lists.sourceforge.net, gscrivan@redhat.com, jannh@google.com, kernel-team@android.com, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, maco@android.com, miklos@szeredi.hu, palmer@dabbelt.com, paullawrence@google.com, trapexit@spawn.link, zezeozue@google.com Subject: Re: [PATCH RESEND V11 0/7] fuse: Add support for passthrough read/write Message-ID: References: <20210118192748.584213-1-balsini@android.com> <20210119110654.11817-1-wu-yan@tcl.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210119110654.11817-1-wu-yan@tcl.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 19, 2021 at 07:06:54PM +0800, Rokudo Yan wrote: > on Mon, Jan 18, 2021 at 5:27 PM Alessio Balsini wrote: > > > > This is the 11th version of the series, rebased on top of v5.11-rc4. > > Please find the changelog at the bottom of this cover letter. > > > > Add support for file system passthrough read/write of files when enabled > > in userspace through the option FUSE_PASSTHROUGH. > [...] > > > Hi Allesio, > > Could you please add support for passthrough mmap too ? > If the fuse file opened with passthrough actived, and then map (shared) to (another) process > address space using mmap interface. As access the file with mmap will pass the vfs cache of fuse, > but access the file with read/write will bypass the vfs cache of fuse, this may cause inconsistency. > eg. the reader read the fuse file with mmap() and the writer modify the file with write(), the reader > may not see the modification immediately since the writer bypass the vfs cache of fuse. > Actually we have already meet an issue caused by the inconsistency after applying fuse passthrough > scheme to our product. > > Thanks, > yanwu. Hi yanwu, Thank you for your interest in this change. FUSE passthrough for mmap is an extension that is already in my TODO list, together with passthrough for directories. For now I would prefer to keep this series minimal to make the review process leaner and simpler. I will start working on extending this series with new features and addressing more corner cases as soon as these changes get merged, what do you think? Thanks, Alessio