Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp3267728rwe; Mon, 29 Aug 2022 08:32:52 -0700 (PDT) X-Google-Smtp-Source: AA6agR5Jwj5elp78bVyioOLFJ9kvdaSP+RXzkxuQAHlfoOgN55ugElItWjeSEFsnekyY2hOTIJMs X-Received: by 2002:a05:6402:1041:b0:446:b290:ea94 with SMTP id e1-20020a056402104100b00446b290ea94mr16832294edu.389.1661787172577; Mon, 29 Aug 2022 08:32:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661787172; cv=none; d=google.com; s=arc-20160816; b=qMsotdUNcrH3uOoRAGkF9Qt/3cA7kZAkp9f5dEf8OUFhH8L0sFto+gZgBP0SMeZnBP TCIt9ASocPlfMDJ8tjvgyyYdiN8H+eU/7PP5AM5vn1Yrke58OINbqMivQc5x4mSl1xl0 pa8O3JNkoIk5An5yKXAcJcra7eaKK2G2uE5sCsG5yAB5GHmQ1+6RcwiIXcwrNwskvb4I Yt2d2s4wqsd2iME2fuPhH6/3MPXsAO7Nxy7mLAcNi7v2ZGQAlNpFzDNe1ICg2MLLE5s1 xi9RkCK9b37rJRf6FyZqsNT44SbPJ5RhzWqSrtRMWKj0zrq1mzynJBhKKeo3U3qxptZ2 40rQ== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=GhG/DlSa7OO/qQZrD16bsLuYRkHDvBnWIEG78IaL2eI=; b=rL12KJRgpBAbzW1CTwQpAUEni1UMr9cGJjSXwDbx5ZnPkiN2jUugwqws1c6l1QJzD6 GecoztLmOsWCr5uId6r7CoIB4iUw0dFCR9H1d+w0oH7uD2QB3R8XIzK26CwFJaz+fPoG ERqxWoaRL1khDHoU/EmIRWEKNbDqROcHtScid5dHqUbE4IXlHIHqWCBrSVlJ2Zt08Ncy FdGubHOMCVSttBcH2hsWSpXF62mOGxMadp1IIqRDXuRvpGDbSnRHidGtJrVlydPS7HlU +OMnl9kZElzdFuJ88PGiraVR0D9d2Slu1Jo6N93xwax+nYF94UP2yDwK8ijOuWCvAxJM NkMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@corp.netease.com header.s=s210401 header.b=fJPsJqbw; 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=corp.netease.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r25-20020a50aad9000000b004462c501809si6121626edc.397.2022.08.29.08.32.25; Mon, 29 Aug 2022 08:32:52 -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=@corp.netease.com header.s=s210401 header.b=fJPsJqbw; 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=corp.netease.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229701AbiH2PNN (ORCPT + 99 others); Mon, 29 Aug 2022 11:13:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60732 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229628AbiH2PNL (ORCPT ); Mon, 29 Aug 2022 11:13:11 -0400 X-Greylist: delayed 718 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Mon, 29 Aug 2022 08:13:08 PDT Received: from corp-front10-corp.i.nease.net (corp-front11-corp.i.nease.net [42.186.62.105]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6F0737A752; Mon, 29 Aug 2022 08:13:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=corp.netease.com; s=s210401; h=Received:From:To:Cc:Subject: Date:Message-Id:MIME-Version:Content-Transfer-Encoding; bh=GhG/D lSa7OO/qQZrD16bsLuYRkHDvBnWIEG78IaL2eI=; b=fJPsJqbwbQACg8HiQDBR5 stoiegPZZFYTS8uFZjGdL00FRQCROnSlvdCQAspQvaiITEUA+jmKOFlAOjjxjutY tXu10sWTTKIUutIVXyHcjQun9YDqlfhzEusPYHagIVU3n/dwvjjuU6YCdlHEw4+6 Kal3xs/6jv7otp7yqykjuE= Received: from pubt1-k8s74.yq.163.org (unknown [115.238.122.38]) by corp-front11-corp.i.nease.net (Coremail) with SMTP id aYG_CgBHWzQD0wxj7g8gAA--.36033S2; Mon, 29 Aug 2022 22:53:55 +0800 (HKT) From: liuyacan@corp.netease.com To: kgraul@linux.ibm.com, davem@davemloft.net, wenjia@linux.ibm.com, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com Cc: linux-s390@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, liuyacan Subject: [PATCH net] net/smc: Remove redundant refcount increase Date: Mon, 29 Aug 2022 22:53:29 +0800 Message-Id: <20220829145329.2751578-1-liuyacan@corp.netease.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CM-TRANSID: aYG_CgBHWzQD0wxj7g8gAA--.36033S2 X-Coremail-Antispam: 1UD129KBjvdXoWrZw4xGw15Xr1kAr4fAr4xZwb_yoW3Xwb_Ka 47GF9rGa1YyFWSy3yfC3yfuan2qwn5Gr48XFn5ArZ0y3Wqqw4UArs8Zrn8uw1UCw1UAF13 JrsIqrZYgw12yjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUbtkYjxAI6xCIbckI1I0E57IF64kEYxAxM7AC8VAFwI0_Gr0_Xr1l 1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, DKIM_VALID,DKIM_VALID_AU,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=unavailable 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: liuyacan For passive connections, the refcount increment has been done in smc_clcsock_accept()-->smc_sock_alloc(). Fixes: 3b2dec2603d5("net/smc: restructure client and server code in af_smc") Signed-off-by: liuyacan --- net/smc/af_smc.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/smc/af_smc.c b/net/smc/af_smc.c index 79c1318af..0939cc3b9 100644 --- a/net/smc/af_smc.c +++ b/net/smc/af_smc.c @@ -1855,7 +1855,6 @@ static void smc_listen_out_connected(struct smc_sock *new_smc) { struct sock *newsmcsk = &new_smc->sk; - sk_refcnt_debug_inc(newsmcsk); if (newsmcsk->sk_state == SMC_INIT) newsmcsk->sk_state = SMC_ACTIVE; -- 2.20.1