From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D8BD8EB64DD for ; Thu, 6 Jul 2023 14:43:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233265AbjGFOnk (ORCPT ); Thu, 6 Jul 2023 10:43:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33792 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232745AbjGFOni (ORCPT ); Thu, 6 Jul 2023 10:43:38 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 87F851732 for ; Thu, 6 Jul 2023 07:43:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=GOGLmZkKS+Mqk0K7P36N7SXDMTDQhhEvNASEsg58n2o=; b=PTV/c2Zrmdwmds7bdhAcrHY4zH c22UfluigfJsNeOabr/Ggma0q600wL2GfaqXeKbwqOn61eEKinslsGqH3i9SLHaHe4D2sfwIK/uxQ EDk5IMtruepRcvFFUnna2vDHk9W/m+Wc81lqsiX5G+7Gt0L+Jq4u/Wh+Zvx/kqL8OgvOTxKNrbmwu BARBHZgcKo/tse1E8cWrhev6j3OKfP8yLzJcxUigwA6B90lw53hr5F3lAxZHlv3HIUgqeTYVNEH45 3QncFqVbuRB4TpOByOFpoNNBZD6c9Wg5rBadUx4J7JNcr5pA80TEKSXxj1WqZ/bki3Y9oYtp2K5lL bpWC3soA==; Received: from hch by bombadil.infradead.org with local (Exim 4.96 #2 (Red Hat Linux)) id 1qHQCV-001tVc-2x; Thu, 06 Jul 2023 14:43:19 +0000 Date: Thu, 6 Jul 2023 07:43:19 -0700 From: Christoph Hellwig To: Bernd Schubert Cc: Hao Xu , fuse-devel@lists.sourceforge.net, miklos@szeredi.hu, linux-fsdevel@vger.kernel.org, Wanpeng Li , cgxu519@mykernel.net, Dharmendra Singh Subject: Re: [RFC] [PATCH] fuse: DIO writes always use the same code path Message-ID: References: <20230630094602.230573-1-hao.xu@linux.dev> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Wed, Jul 05, 2023 at 12:23:40PM +0200, Bernd Schubert wrote: > @@ -1377,37 +1375,10 @@ static ssize_t fuse_cache_write_iter(struct kiocb > *iocb, struct iov_iter *from) > if (err) > goto out; > > - if (iocb->ki_flags & IOCB_DIRECT) { > - loff_t pos = iocb->ki_pos; > - written = generic_file_direct_write(iocb, from); After this generic_file_direct_write becomes unused outside of mm/filemap.c, please add a patch to the series to mark it static. > + written = fuse_perform_write(iocb, mapping, from, iocb->ki_pos); > + if (written >= 0) > + iocb->ki_pos += written; This needs to be updated to the new fuse_perform_write calling conventions in Linus tree.