Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp435724pxp; Sat, 5 Mar 2022 07:43:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJxdrst1W2Ew7FsQ2WUyXlskTMogixQmmwwr+PlCvc9WYMDBlcBjOKfJJvJ10+AWs/aHDHU7 X-Received: by 2002:a17:90a:dc81:b0:1bd:2d28:4bf4 with SMTP id j1-20020a17090adc8100b001bd2d284bf4mr4347575pjv.206.1646495035926; Sat, 05 Mar 2022 07:43:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1646495035; cv=none; d=google.com; s=arc-20160816; b=e3II2ViaZVNQZV5vTvyNMI+8oCUjFlX3wS/Ku1X+xvvorFe4jmb7o1Hf9fTKCew0pH JJvh7snucUi1wIEcROkRAPC82OeLRLcukBcCnlVALSwdiGR3AGrDHU96RMcK1id5Ec58 FDL2M60EQZBxBpFT5stIZdDvXB/ib35gB5gvGluvE6aSG8ZehtLK1UNbk4IsMmTNthgu nRxigXXsxjfCU5IqpFoU0ZtnwoziZ3guAOZFzWyuURYb0dwU8WTOzvNSW1PHSeiQT5zJ f3PBDRHj4T9L4jXIpagnT0lvpmAMdRan7KXFsi3wTf/NJ1d9ZmYedDfU1U8Io2DDtaPn 6xzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=5Q1Z6Q9dTzAKbdIRv3gjgzT821hLgfoHFhJ6aojm1Hs=; b=YhERsPVyNFTRJQ/3U8wmU5sr/vK7zDznPxz+plNAbPsGo3xS63U0tTxOKM8/0JGJYD PzHyPIh2ViUf+S3E/eVZy8k9hqCTdGKOWlGCxk11bYpITsdjM+xkp9H2bDN8AMRVDmml z9BYzkxU7IVcs9YPdJC/VRqIDylLwd6cIuFYU8Q2JkuuKuYZ+l/oE18De+1smsHLldnz hfro+CWNUqdQuwdKI7BNVvM5ho/Gi/Gtun7ynIj3Bn2TJSYY77GlqXoFJ6tM/FzCXvet vwp9Ms98aj+4WpRzTtdhkZKb3HoqtIiDs3qwZ0OADOw4lVrkFiOvwDfBiBzuc+V/pqIA 3R4w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p2-20020a170902780200b0014fdd57e462si7466124pll.498.2022.03.05.07.43.05; Sat, 05 Mar 2022 07:43:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231690AbiCEMc1 (ORCPT + 99 others); Sat, 5 Mar 2022 07:32:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43356 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229568AbiCEMcZ (ORCPT ); Sat, 5 Mar 2022 07:32:25 -0500 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1694323F3DF; Sat, 5 Mar 2022 04:31:35 -0800 (PST) Received: from kwepemi100015.china.huawei.com (unknown [172.30.72.55]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4K9kVc4yKpzbcBG; Sat, 5 Mar 2022 20:26:48 +0800 (CST) Received: from kwepemm600015.china.huawei.com (7.193.23.52) by kwepemi100015.china.huawei.com (7.221.188.125) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Sat, 5 Mar 2022 20:31:32 +0800 Received: from huawei.com (10.175.127.227) by kwepemm600015.china.huawei.com (7.193.23.52) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Sat, 5 Mar 2022 20:31:31 +0800 From: ChenXiaoSong To: , , CC: , , , , , Subject: [PATCH -next 0/2] nfs: check writeback errors correctly Date: Sat, 5 Mar 2022 20:46:34 +0800 Message-ID: <20220305124636.2002383-1-chenxiaosong2@huawei.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.127.227] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To kwepemm600015.china.huawei.com (7.193.23.52) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org This series fixes nfs writeback error checking bugs. If there is an error during the writeback process, it should be returned when user space calls close() or fsync(). filemap_sample_wb_err() will return 0 if nobody has seen the error yet, then filemap_check_wb_err() will return the unchanged writeback error. ChenXiaoSong (2): nfs: nfs{,4}_file_flush should consume writeback error nfs: nfs_file_write() check writeback errors correctly fs/nfs/file.c | 8 +++----- fs/nfs/nfs4file.c | 4 +--- 2 files changed, 4 insertions(+), 8 deletions(-) -- 2.31.1