From patchwork Tue Sep 4 21:05:17 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Trond Myklebust X-Patchwork-Id: 10587897 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 65123112B for ; Tue, 4 Sep 2018 21:06:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5603A29FC2 for ; Tue, 4 Sep 2018 21:06:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4A1C729FCA; Tue, 4 Sep 2018 21:06:15 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,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 EA6932A0B9 for ; Tue, 4 Sep 2018 21:06:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726211AbeIEBdF (ORCPT ); Tue, 4 Sep 2018 21:33:05 -0400 Received: from mail-it0-f65.google.com ([209.85.214.65]:51641 "EHLO mail-it0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725825AbeIEBdE (ORCPT ); Tue, 4 Sep 2018 21:33:04 -0400 Received: by mail-it0-f65.google.com with SMTP id e14-v6so7032112itf.1 for ; Tue, 04 Sep 2018 14:06:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=wB1vpq+Hf5tAhc6xSDBsSka9UzF0BZ7hMgl4DfIKsP0=; b=Bx7K11UHMa/GwcmUoyniohc0GNDeOLswfZur9cfCR5lFs5+qJzMAyt640X2Pw8a27V gqmRTfYbZVjRf3EKdKl8BWsPGS0CTQCizWFVek234StisjkI0y4CUEPfvyrJBjE1cQWs zlXduU8gcZcVF0uk876AEKfXo3pzIB6mefYVJ6uV6OOo1SdF4qhY2Q2l1tGWCtR7gHum w6Awh918rRbmUjPx3CKILTP4g7q00FOjTtf+szwky7ql7wEw32zbErX/3fpJkaR+B157 PM0X0c3k0ENJ7WNODaBeivYmVK33i821KznTWB+NQUCNfgObz2Q63P30NwaHtOXWA3ts kgyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=wB1vpq+Hf5tAhc6xSDBsSka9UzF0BZ7hMgl4DfIKsP0=; b=Qu9WEfuXBdzMDaznCgKDHqSgYAz/m9AZUcZgSArKsv4q6Cw6cOf8pT9/fjZ7jjGIkd ex0XwzWyRxnlAqgxVwmqWeVWQn0Sw/ZPCfpuFsusE0Pg21ejFmNj3zwBjP9quCdNcGka ueHUq28zetOuFQz1MT4eCoCGcIOXQgUZozUbb/+6Owq9X45fb4g4v8d9p6uXlbwsKMQk eRTzgplm3NjnZoEfYzBFUrPmmIoGn1i6h5jAhPvvkZwlQR+Q9kFHxxBAI3sNNckZVs4B V94BJH0dJP27LLlKreJmIZk1b83kLb5HqkSEHWi+p7P6fIf9SAINCR2o4NhsQRoBiq3N mxRA== X-Gm-Message-State: APzg51C8AUk4Zl8I90p08SZdZ0alHBaUQpNz5YCnDofT2ZyZcUc4C7a5 O98s6lhGs8VYqscbQz6W+nJ/BkQ= X-Google-Smtp-Source: ANB0VdYDeTAI9SdJlqB703ebT8qgnpD9XkvXH1S2s9t03duXIgc1R+aZfu/Y6ndsS+R/bWaKA3oGQg== X-Received: by 2002:a02:a70a:: with SMTP id k10-v6mr23863493jam.47.1536095172633; Tue, 04 Sep 2018 14:06:12 -0700 (PDT) Received: from leira.trondhjem.org.localdomain (c-68-40-195-73.hsd1.mi.comcast.net. [68.40.195.73]) by smtp.gmail.com with ESMTPSA id t64-v6sm172860ita.13.2018.09.04.14.06.11 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 04 Sep 2018 14:06:12 -0700 (PDT) From: Trond Myklebust X-Google-Original-From: Trond Myklebust To: linux-nfs@vger.kernel.org Subject: [PATCH v2 02/34] SUNRPC: If there is no reply expected, bail early from call_decode Date: Tue, 4 Sep 2018 17:05:17 -0400 Message-Id: <20180904210549.81673-3-trond.myklebust@hammerspace.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180904210549.81673-2-trond.myklebust@hammerspace.com> References: <20180904210549.81673-1-trond.myklebust@hammerspace.com> <20180904210549.81673-2-trond.myklebust@hammerspace.com> MIME-Version: 1.0 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 Signed-off-by: Trond Myklebust --- net/sunrpc/clnt.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/net/sunrpc/clnt.c b/net/sunrpc/clnt.c index bc9d020bf71f..4f1ec8013332 100644 --- a/net/sunrpc/clnt.c +++ b/net/sunrpc/clnt.c @@ -2260,6 +2260,11 @@ call_decode(struct rpc_task *task) dprint_status(task); + if (!decode) { + task->tk_action = rpc_exit_task; + return; + } + if (task->tk_flags & RPC_CALL_MAJORSEEN) { if (clnt->cl_chatty) { printk(KERN_NOTICE "%s: server %s OK\n", @@ -2297,13 +2302,11 @@ call_decode(struct rpc_task *task) goto out_retry; return; } - task->tk_action = rpc_exit_task; - if (decode) { - task->tk_status = rpcauth_unwrap_resp(task, decode, req, p, - task->tk_msg.rpc_resp); - } + task->tk_status = rpcauth_unwrap_resp(task, decode, req, p, + task->tk_msg.rpc_resp); + dprintk("RPC: %5u call_decode result %d\n", task->tk_pid, task->tk_status); return;