From patchwork Fri Apr 1 03:44:06 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: ChenXiaoSong X-Patchwork-Id: 12797881 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 264FEC433EF for ; Fri, 1 Apr 2022 03:29:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244567AbiDADb1 (ORCPT ); Thu, 31 Mar 2022 23:31:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59990 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235001AbiDADbZ (ORCPT ); Thu, 31 Mar 2022 23:31:25 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 22D3057B15; Thu, 31 Mar 2022 20:29:34 -0700 (PDT) Received: from kwepemi500002.china.huawei.com (unknown [172.30.72.56]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4KV5GH2JhbzgY8W; Fri, 1 Apr 2022 11:27:51 +0800 (CST) Received: from kwepemm600015.china.huawei.com (7.193.23.52) by kwepemi500002.china.huawei.com (7.221.188.171) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.21; Fri, 1 Apr 2022 11:29:31 +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; Fri, 1 Apr 2022 11:29:30 +0800 From: ChenXiaoSong To: , , CC: , , , , , Subject: [PATCH -next,v2 0/3] nfs: handle writeback errors correctly Date: Fri, 1 Apr 2022 11:44:06 +0800 Message-ID: <20220401034409.256770-1-chenxiaosong2@huawei.com> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 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 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org v1: cover letter: (nfs: check writeback errors correctly) v2: - return more nuanced writeback errors in nfs_file_write(). - return writeback error in close()->flush() without consumed it. - fix: nfs_file_write() will always call nfs_wb_all() even if there is no new writeback error. ChenXiaoSong (3): NFS: return more nuanced writeback errors in nfs_file_write() NFS: nfs{,4}_file_flush() return correct writeback errors Revert "nfs: nfs_file_write() should check for writeback errors" fs/nfs/file.c | 23 ++++++++++------------- fs/nfs/nfs4file.c | 8 ++++---- fs/nfs/write.c | 5 +---- 3 files changed, 15 insertions(+), 21 deletions(-)