From patchwork Thu Oct 18 19:01:49 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Coddington X-Patchwork-Id: 10647931 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0FF9A157A for ; Thu, 18 Oct 2018 19:01:53 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 01B192909F for ; Thu, 18 Oct 2018 19:01:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E592D2909D; Thu, 18 Oct 2018 19:01:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9236429098 for ; Thu, 18 Oct 2018 19:01:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726424AbeJSDEO (ORCPT ); Thu, 18 Oct 2018 23:04:14 -0400 Received: from mx1.redhat.com ([209.132.183.28]:51026 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726843AbeJSDEN (ORCPT ); Thu, 18 Oct 2018 23:04:13 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 73DD23082B56; Thu, 18 Oct 2018 19:01:51 +0000 (UTC) Received: from bcodding.csb (ovpn-66-2.rdu2.redhat.com [10.10.66.2]) by smtp.corp.redhat.com (Postfix) with ESMTP id 346B2100034B; Thu, 18 Oct 2018 19:01:51 +0000 (UTC) Received: by bcodding.csb (Postfix, from userid 24008) id C6EDD10C30FF; Thu, 18 Oct 2018 15:01:49 -0400 (EDT) From: Benjamin Coddington To: Anna Schumaker , Trond Myklebust Cc: linux-nfs@vger.kernel.org Subject: [PATCH 2/2 v2] nfs: remove redundant call to nfs_context_set_write_error() Date: Thu, 18 Oct 2018 15:01:49 -0400 Message-Id: <0963d6fa00685c2810cd1d5996eb4853a2949057.1539889215.git.bcodding@redhat.com> In-Reply-To: <1da7a5e6280feaf3fe24673cbcf8138571e26fa4.1539889215.git.bcodding@redhat.com> References: <1da7a5e6280feaf3fe24673cbcf8138571e26fa4.1539889215.git.bcodding@redhat.com> In-Reply-To: <1da7a5e6280feaf3fe24673cbcf8138571e26fa4.1539889215.git.bcodding@redhat.com> References: <1da7a5e6280feaf3fe24673cbcf8138571e26fa4.1539889215.git.bcodding@redhat.com> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.45]); Thu, 18 Oct 2018 19:01:51 +0000 (UTC) Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP We don't need to call this in the direct, read, or pnfs resend paths and the only other caller is the write path in nfs_page_async_flush() which already checks and sets the pg_error on the context. Signed-off-by: Benjamin Coddington --- fs/nfs/pagelist.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/fs/nfs/pagelist.c b/fs/nfs/pagelist.c index 7e6425791388..a592abb62873 100644 --- a/fs/nfs/pagelist.c +++ b/fs/nfs/pagelist.c @@ -1174,10 +1174,6 @@ int nfs_pageio_add_request(struct nfs_pageio_descriptor *desc, return 1; out_failed: - /* remember fatal errors */ - if (nfs_error_is_fatal(desc->pg_error)) - nfs_context_set_write_error(req->wb_context, - desc->pg_error); nfs_pageio_error_cleanup(desc); return 0; }