From patchwork Mon May 15 16:29:28 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 94271 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp7107837vqo; Mon, 15 May 2023 11:19:29 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4YDyeMHPqt0D4LDCmuLtEztg8Y5UoqS/G/hYizi+4iyuxh4lnok6sx/kftUumLEH8msMHB X-Received: by 2002:a05:6a20:3d10:b0:101:3fe5:8785 with SMTP id y16-20020a056a203d1000b001013fe58785mr28866934pzi.44.1684174768987; Mon, 15 May 2023 11:19:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684174768; cv=none; d=google.com; s=arc-20160816; b=NO8rzPiLVCdYTO+O6Rr1nhvFuiNsZQHbukn8fR9EFvmyHk0OL8F9eDXJI/qZpXRVAI rfFAJmDw7bDBlpstwDqUVsZyGrv6ZkLpc7b/WSu4OZqCQEREH7ULmfbENFWY/jqjlyaX ANxiscxbuqgv8ct6Cu/CclZs8xRREYHl/PK8hkc2wg/FZKEnlM5nr+++JMJ3jYcUdCmF rZsfgUZoCLll38ZMKctrxjpaddVZ4NGmcpHh5Geko5VKGZCFaSgZbwZXi1+w7sel7SZa cR3EZQj/4MeGD3QpZ7Wa1KJolTmTCSxY8AtYGbwjJ1ASs+PVwbF3OSQURNIDt+7AxpS9 +8wQ== 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=FzpsGFAPGkFT+DTUpJ/x5P+S0QYjE/Lkyme2rEmFEBY=; b=j7lTAX5LPy5UsMzekIiNiR+ITZk9QN7Xr4OhdGBFDYx/pKSn2SILWpyThgnaFUsDhG MxoCAX0c7L5VZpRSE4P+OuZv8dvhRebGiftVQa97DoX0wTICF/tl8zEAXDy0/911a/E2 K6hfY/nhWArMW2stcbLmduYmNxNdfDiCqXRYi36iHxSfMLEw8iOSUcNT+3d178yQ0ygt BOMviVp1kKYzNt4IHki3nvlsS7UZRcYqASmHR8hTS81uPNwYTdUh5bE5bZDIBsS3vE23 wch7JRshiMzxWLecyJz36G3nVmvoN74uWjDdx7xGm1WI8w8xprlCDYcFJmq7WiM4BfWU o4cQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="U0B/xg5W"; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b191-20020a6334c8000000b005303b08eb16si17001903pga.631.2023.05.15.11.19.16; Mon, 15 May 2023 11:19:28 -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="U0B/xg5W"; 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 S240909AbjEORzv (ORCPT + 99 others); Mon, 15 May 2023 13:55:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53386 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245124AbjEORzN (ORCPT ); Mon, 15 May 2023 13:55:13 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8CC47120BA; Mon, 15 May 2023 10:53:22 -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 dfw.source.kernel.org (Postfix) with ESMTPS id 53EE662F7A; Mon, 15 May 2023 17:51:00 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 379CBC433D2; Mon, 15 May 2023 17:50:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1684173059; bh=Ty9DPaKzbqBJz2YbO+x5qaO1VH7G0U+WgyWhAR3rbZY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=U0B/xg5WR+Fy5lHdg4IgNNE5WRZsm7aOrz83439xYNPrs2vKcbpWaovZtNrrmcTdT hEaSt4OcNJI4qewocf3zngN+Vjv2d+7AEcB/bmALUPXVHXMyA8+XlsxWeOLZluO6E7 YnfRWK3YRMZsBFQTiM1pypeKXjBAHHZ3U3qcvCyM= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, David Howells , Marc Dionne , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , linux-afs@lists.infradead.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Sasha Levin Subject: [PATCH 5.10 317/381] rxrpc: Fix hard call timeout units Date: Mon, 15 May 2023 18:29:28 +0200 Message-Id: <20230515161751.128690115@linuxfoundation.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230515161736.775969473@linuxfoundation.org> References: <20230515161736.775969473@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1765985242551949891?= X-GMAIL-MSGID: =?utf-8?q?1765985242551949891?= From: David Howells [ Upstream commit 0d098d83c5d9e107b2df7f5e11f81492f56d2fe7 ] The hard call timeout is specified in the RXRPC_SET_CALL_TIMEOUT cmsg in seconds, so fix the point at which sendmsg() applies it to the call to convert to jiffies from seconds, not milliseconds. Fixes: a158bdd3247b ("rxrpc: Fix timeout of a call that hasn't yet been granted a channel") Signed-off-by: David Howells cc: Marc Dionne cc: "David S. Miller" cc: Eric Dumazet cc: Jakub Kicinski cc: Paolo Abeni cc: linux-afs@lists.infradead.org cc: netdev@vger.kernel.org cc: linux-kernel@vger.kernel.org Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- net/rxrpc/sendmsg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/rxrpc/sendmsg.c b/net/rxrpc/sendmsg.c index a670553159abe..1882fea719035 100644 --- a/net/rxrpc/sendmsg.c +++ b/net/rxrpc/sendmsg.c @@ -753,7 +753,7 @@ int rxrpc_do_sendmsg(struct rxrpc_sock *rx, struct msghdr *msg, size_t len) fallthrough; case 1: if (p.call.timeouts.hard > 0) { - j = msecs_to_jiffies(p.call.timeouts.hard); + j = p.call.timeouts.hard * HZ; now = jiffies; j += now; WRITE_ONCE(call->expect_term_by, j);