Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp814775pxb; Thu, 21 Apr 2022 10:54:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxbpg0I8D5bb/b5SAKAE0hiEFIhWrTMiVsI82fo82jsDkRL2cs+dmBrXsvUOnSaN7Gc6VRZ X-Received: by 2002:a17:902:bf07:b0:158:24d9:3946 with SMTP id bi7-20020a170902bf0700b0015824d93946mr459094plb.28.1650563652820; Thu, 21 Apr 2022 10:54:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650563652; cv=none; d=google.com; s=arc-20160816; b=RDQucmDeLcTM7Oh4p5S1BpDbLTWM9oMQl2SqDDkIywxdzJi3T3JVUTYQX38BVpwjZt FffiRlpleqQtoDB3n2pwnHrah1rke3geEVMR2NgS9E+B77tQ9/UkCSJPY26WeDTDY9uA 1GRWhsogq5pnLX5pwZFft2voBixzEYjovN7+SBmcks0Vtc6nkoou8ET9MbNlVqZtcmFl 9pyT1MtJ9qinR/a8b0aEpdw5PtyZ0HECEkOnTp5qj8CUAkNmftUxXt9M6aT3DFnloEw1 Fo9QXTFk8yRwOFo+yddBwwuSbrdJ3VKML3LMJarGYOK167bsdaROx6Aio+ClcN73+XjR HIyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:references :cc:to:subject:from:user-agent:mime-version:date:message-id; bh=wXOhhNrNASyCwl9KKOekaPm25lpNGi2DEdbWedZ46p8=; b=TtFgkL3rgdOzJ0W1eQDjrLMozWM1XLKs140JnOxoNsyID4IUeO2F2c9mg86qY3SuGB VL1FNcTPn62+pIxweWt8k5OvFcR9kAt0z4+YbLMhZ0lcHyITJUK+8gZlsjZvfyu8Yh/7 ibIjfDIAOJNa/nZok42AqN07LjYkO7lli7PtmhBQsj8Ei0vTJo9clE3iTtzHTqEZ6ZU0 GAmm3fdY29NYxQB0ah32KK3XbnXelxqDm6t0+rU2Yk5jGpduWZt3JEfzbvbAsm9JpRfV RKPwe460/cRZU6lURUPX/b2gHwSjBscmeUnIaJG02oyKmvQoiVl4jdnzXReIiSlCN7tk c2rg== 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 c4-20020a170903234400b001590118e14dsi6211347plh.108.2022.04.21.10.53.38; Thu, 21 Apr 2022 10:54:12 -0700 (PDT) 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 S233689AbiDTIxZ (ORCPT + 99 others); Wed, 20 Apr 2022 04:53:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49808 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1376899AbiDTIxY (ORCPT ); Wed, 20 Apr 2022 04:53:24 -0400 Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F195A33EBE; Wed, 20 Apr 2022 01:50:36 -0700 (PDT) Received: from kwepemi500013.china.huawei.com (unknown [172.30.72.55]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4KjvW21g3Fz1J9sP; Wed, 20 Apr 2022 16:49:50 +0800 (CST) Received: from kwepemm600015.china.huawei.com (7.193.23.52) by kwepemi500013.china.huawei.com (7.221.188.120) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Wed, 20 Apr 2022 16:50:34 +0800 Received: from [10.174.176.52] (10.174.176.52) 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.2375.24; Wed, 20 Apr 2022 16:50:34 +0800 Message-ID: Date: Wed, 20 Apr 2022 16:50:33 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.2.1 From: "chenxiaosong (A)" Subject: Re: [PATCH -next 1/2] nfs: nfs{,4}_file_flush should consume writeback error To: Trond Myklebust , "anna@kernel.org" , "smayhew@redhat.com" CC: "linux-nfs@vger.kernel.org" , "liuyongqiang13@huawei.com" , "linux-kernel@vger.kernel.org" , "yi.zhang@huawei.com" , "zhangxiaoxu5@huawei.com" References: <20220305124636.2002383-1-chenxiaosong2@huawei.com> <20220305124636.2002383-2-chenxiaosong2@huawei.com> <5666cb64-c9e4-0549-6ddb-cfc877c9c071@huawei.com> <037054f5ac2cd13e59db14b12f4ab430f1ddef5d.camel@hammerspace.com> <4a8e21fb-d8bf-5428-67e5-41c47529e641@huawei.com> <0528423f710cd612262666b1533763943c717273.camel@hammerspace.com> <9fc83915a24d7b65d743910dd0f0e5f3d0373596.camel@hammerspace.com> In-Reply-To: <9fc83915a24d7b65d743910dd0f0e5f3d0373596.camel@hammerspace.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.176.52] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To kwepemm600015.china.huawei.com (7.193.23.52) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-8.3 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_PASS 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 在 2022/4/12 22:27, Trond Myklebust 写道: > > It will clear ENOSPC, EDQUOT and EFBIG. It should not clear other > errors that are not supposed to be reported by write(). > > As I keep repeating, that is _documented behaviour_! > Hi Trond: You may mean that write(2) manpage described: > Since Linux 4.13, errors from write-back come with a promise that > they may be reported by subsequent. write(2) requests, and will be > reported by a subsequent fsync(2) (whether or not they were also > reported by write(2)). The manpage mentioned that "reported by a subsequent fsync(2)", your patch[1] clear the wb err on _async_ write(), and wb err will _not_ be reported by subsequent fsync(2), is it documented behaviour? All other filesystems will _not_ clear any wb err on _async_ write(). [1] https://patchwork.kernel.org/project/linux-nfs/patch/20220411213346.762302-4-trondmy@kernel.org/