Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp3053001rwe; Mon, 29 Aug 2022 05:11:42 -0700 (PDT) X-Google-Smtp-Source: AA6agR4Skjx1pX/G9rVj/NeT05ws0ksCKVtri9uYNjjcWtHO59G0HFvEHFJVt9UfaoyLwXwU8Moy X-Received: by 2002:a17:903:22c4:b0:16f:a93:9197 with SMTP id y4-20020a17090322c400b0016f0a939197mr16108925plg.134.1661775101882; Mon, 29 Aug 2022 05:11:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661775101; cv=none; d=google.com; s=arc-20160816; b=tzH5QfHKoN7iEUoCM9W3NnRwPWEsnzsSgPbwsBZn/ZvwJ0k8SYrRe2spwLfgnYNJp6 p78YJQSM0G6Y0qtIoibOrULvufD62nQZu3570R5a6tq7SQlIC0KETdmdtTJA9aW2N1H4 HZyDLDmSs6/9n6cTuqKWE28gi9E7PSU9UcxXngJDY3Oiv1xr33e1NEgFwcqfeTgVf+G5 Kmzw+Kviy/GFQw2BhgGkDapu6hg6qNRlLUV16nOCNdCdATCnMMr2Izq/kwDgl6/ODzWK eBJ+AM2S2TvgOQGdefROHK/FIdXSAEXxRcXEU8bwUJsFevjvyKZShdgsAa1LSBXxy+lA +R3g== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=I9KEbY/ZghIQ47jcX//hhK+XiYzA6Ufou2L24qWcFpI=; b=U0RCL3F9MUqQ2wpaT7YB3d2ZAjFyy8wGEryl0ut+7zD5mv270lpbKsjUXdWZVpkLK6 EIyraV0z5m3r6q1LUDVionYhZCpLMbi3V96wwEAgk5qaIAWRoVXWGQ3lZsKbgl6cZcDh BES6r0nToXXRDWrh5vqXIm1YDrg7JObiL4goJmHMiLxNRKgEg7rjv7DSy4gvYpw5e/ZE 5GiSlK4NaRNKewLA+4365FRqkW/eDJWxL9ozU6KaSHtTuhmg7Mu3q1D0e9Mq9gj+gjHs 9AqMlKDCJd8bQPq/ES23D/iNJIXoqZpYvOp+zu3apCcVoHDXJKGUdmNfwr8ejzPkXZNL WDXg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=AdYMmUww; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x10-20020aa793aa000000b00535ed30d44esi9042342pff.78.2022.08.29.05.11.30; Mon, 29 Aug 2022 05:11:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=AdYMmUww; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231837AbiH2LZo (ORCPT + 99 others); Mon, 29 Aug 2022 07:25:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40562 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231989AbiH2LXu (ORCPT ); Mon, 29 Aug 2022 07:23:50 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4EE811260D; Mon, 29 Aug 2022 04:15:12 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id A5642B80F03; Mon, 29 Aug 2022 11:04:42 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DE4AAC433C1; Mon, 29 Aug 2022 11:04:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1661771081; bh=/2TgZp9/QnELkEnYvXdcofmDRuWGi0Sg490D9xcwBWI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=AdYMmUww0Kg/LyiS6AslzoMbp2EpywNReTzrZyK3qPcQKGkpBrY/rVSfszJKjlMjI 5wAcLsFGzUjrcNgOtrnh3u6BkcHf7lLIbIV9fAqkFEJ2/YDRRoui2+pSx0lbPDov4S SQaWKt2oa0ZyQ8T8+w+jz0tn8gB9Tmc19M1BZtu8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Trond Myklebust , Sasha Levin Subject: [PATCH 5.10 18/86] SUNRPC: RPC level errors should set task->tk_rpc_status Date: Mon, 29 Aug 2022 12:58:44 +0200 Message-Id: <20220829105757.266541903@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220829105756.500128871@linuxfoundation.org> References: <20220829105756.500128871@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, 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-kernel@vger.kernel.org From: Trond Myklebust [ Upstream commit ed06fce0b034b2e25bd93430f5c4cbb28036cc1a ] Fix up a case in call_encode() where we're failing to set task->tk_rpc_status when an RPC level error occurred. Fixes: 9c5948c24869 ("SUNRPC: task should be exit if encode return EKEYEXPIRED more times") Signed-off-by: Trond Myklebust Signed-off-by: Sasha Levin --- net/sunrpc/clnt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/sunrpc/clnt.c b/net/sunrpc/clnt.c index c5af31312e0cf..78c6648af7827 100644 --- a/net/sunrpc/clnt.c +++ b/net/sunrpc/clnt.c @@ -1867,7 +1867,7 @@ call_encode(struct rpc_task *task) break; case -EKEYEXPIRED: if (!task->tk_cred_retry) { - rpc_exit(task, task->tk_status); + rpc_call_rpcerror(task, task->tk_status); } else { task->tk_action = call_refresh; task->tk_cred_retry--; -- 2.35.1