Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp295755rdg; Thu, 12 Oct 2023 06:07:07 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGuJ6UcTM2zI1g0UJgJSw/fmzcOzY+HtPTc4uVbxN+L7jZI4E0q3On+hP8agFG0UiC6UNJ/ X-Received: by 2002:a05:6a00:1d09:b0:692:6417:728a with SMTP id a9-20020a056a001d0900b006926417728amr24692750pfx.14.1697116026519; Thu, 12 Oct 2023 06:07:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697116026; cv=none; d=google.com; s=arc-20160816; b=RiNmuYU3xHRQ9xhrQdn2rlG9D+abtKpiP0+EpW4uKacYDH7GfFlPrCnNvcA80wI9fc ld4moBAfUFf7I6o71CixDzyoD8imCC2qcjqAafaZfGmUKu+D+Qr3cmOqEWYc5L/bIjrt VQZIU3RQc55cC32Ez0svMOHHBqfMy9cqsjyQDTZIhDo1aiOs/yzjhwBNF0l/xrQvVES7 pHDXADhmKjxzEdAqc6X9L8Uwf3FYCX/sjdK8bqp9A+RfFQ6htWn8aUQw6RmFLrzuc4lC fLJkvrl5KzF175kP0WbeOuVsdexgJaeedE9LVgSnqkzVuvHJUcbLQlzCSGakFWMiP+Jv /urQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=MdX39D2VCl3WqSbBA2/QodKI3FFA8NAfRhUxo9CYmpI=; fh=YcjYCYkdqzrh4yjEdaj5kF5XXpY23N5k+mjBDgfSrA8=; b=ZsoFY4PWipcyq1G8VdyeWy6de5az9PaCcfTvaXcx1zDWymbkOGt0k4VikkzT1HPIYT JqBRYooXaK/SbLyFJp2k1eV6zg3B13OothLr2bw/RfuNorCsoKi1Sbpe3Quoa8gjTGu+ JyiL2j5sw4fIWnOW9w472vGpcbodC7q+mminCbnOgDnUZoUfgizaINB8mehkpglx1JQu O6n7aiqPBMc8ITY2mR419uG2XLECuRn1epwFffMZI6Qr+swJ3bIa4VRSlAmCCGooncTT zXqZcqfZxTWe2qoC03rfkL5COYzxTVGkJhp2cbxgAu7T4mDV69BiSlD9I8yD3logEILe SMRg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=oTVXtGsc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from morse.vger.email (morse.vger.email. [2620:137:e000::3:1]) by mx.google.com with ESMTPS id i75-20020a636d4e000000b005740ab95917si2323850pgc.45.2023.10.12.06.07.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 12 Oct 2023 06:07:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) client-ip=2620:137:e000::3:1; Authentication-Results: mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=oTVXtGsc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:1 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=NONE dis=NONE) header.from=ibm.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 52B29806E4FD; Thu, 12 Oct 2023 06:05:46 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1343805AbjJLNFh (ORCPT + 99 others); Thu, 12 Oct 2023 09:05:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51352 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1343882AbjJLNFf (ORCPT ); Thu, 12 Oct 2023 09:05:35 -0400 Received: from mx0a-001b2d01.pphosted.com (mx0a-001b2d01.pphosted.com [148.163.156.1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C5DA291; Thu, 12 Oct 2023 06:05:32 -0700 (PDT) Received: from pps.filterd (m0353727.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 39CD2FJ9020431; Thu, 12 Oct 2023 13:05:27 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=message-id : date : mime-version : subject : to : cc : references : from : in-reply-to : content-type : content-transfer-encoding; s=pp1; bh=MdX39D2VCl3WqSbBA2/QodKI3FFA8NAfRhUxo9CYmpI=; b=oTVXtGsc/fSE5bnLHCfLaHb+3CiQ0EYzlqWZlfpEN1pl0Fv5F51l7DBuPO+RVr5Kihzf vIqH5vNxL+A0kjC/NIpTUGJmVH6iIoIDLka8nFMH63ZIsNJpCE16xagBHxJ1oPWZMa+G owVex5gq6MFInxQ/BMfkP24ECcQ3hi+tUP/wwsWWsxfr2Ao5zj8IyjjC6zgA3I5lHvg8 dGiwQl82xInT80Ap+s7UH2N5NlZnd4+sN6X6YjXwKtc/OCIqiSU67bSAPu3JV0Mod8nQ 4BCnlw0dlSuWXI5dvK9vOjONUxaJnSiLafgeyikOa4HRKg12X0gK+G/8HGjXfKB9C+rB RQ== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3tphb1r49g-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 12 Oct 2023 13:05:26 +0000 Received: from m0353727.ppops.net (m0353727.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 39CD2HCC020614; Thu, 12 Oct 2023 13:05:26 GMT Received: from ppma21.wdc07v.mail.ibm.com (5b.69.3da9.ip4.static.sl-reverse.com [169.61.105.91]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3tphb1r48n-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 12 Oct 2023 13:05:25 +0000 Received: from pps.filterd (ppma21.wdc07v.mail.ibm.com [127.0.0.1]) by ppma21.wdc07v.mail.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 39CCc1Ys025907; Thu, 12 Oct 2023 13:05:24 GMT Received: from smtprelay06.fra02v.mail.ibm.com ([9.218.2.230]) by ppma21.wdc07v.mail.ibm.com (PPS) with ESMTPS id 3tkjnnqk3d-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 12 Oct 2023 13:05:24 +0000 Received: from smtpav02.fra02v.mail.ibm.com (smtpav02.fra02v.mail.ibm.com [10.20.54.101]) by smtprelay06.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 39CD5LxS44237196 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 12 Oct 2023 13:05:21 GMT Received: from smtpav02.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id EA0A320040; Thu, 12 Oct 2023 13:05:20 +0000 (GMT) Received: from smtpav02.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B633020043; Thu, 12 Oct 2023 13:05:20 +0000 (GMT) Received: from [9.152.224.54] (unknown [9.152.224.54]) by smtpav02.fra02v.mail.ibm.com (Postfix) with ESMTP; Thu, 12 Oct 2023 13:05:20 +0000 (GMT) Message-ID: <5b54a227-2e18-46d5-9b15-aea9709cf2a5@linux.ibm.com> Date: Thu, 12 Oct 2023 15:05:20 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH net] net/smc: return the right falback reason when prefix checks fail To: Dust Li , Karsten Graul , Wenjia Zhang , Jan Karcher , "D. Wythe" , Tony Lu , Wen Gu , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni Cc: linux-s390@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20231012123729.29307-1-dust.li@linux.alibaba.com> Content-Language: en-US From: Alexandra Winter In-Reply-To: <20231012123729.29307-1-dust.li@linux.alibaba.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-TM-AS-GCONF: 00 X-Proofpoint-ORIG-GUID: MBfSyhAb_8tj5JP09lTYfO1AzGohvjlX X-Proofpoint-GUID: W2eDNxbKHD0fOckijwWojFYiy3FjFkAU X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.267,Aquarius:18.0.980,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-10-12_05,2023-10-12_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 lowpriorityscore=0 mlxlogscore=999 phishscore=0 clxscore=1015 malwarescore=0 suspectscore=0 bulkscore=0 adultscore=0 priorityscore=1501 impostorscore=0 mlxscore=0 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2309180000 definitions=main-2310120107 X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Thu, 12 Oct 2023 06:05:46 -0700 (PDT) On 12.10.23 14:37, Dust Li wrote: > In the smc_listen_work(), if smc_listen_prfx_check() failed, > the real reason: SMC_CLC_DECL_DIFFPREFIX was dropped, and > SMC_CLC_DECL_NOSMCDEV was returned. > > Althrough this is also kind of SMC_CLC_DECL_NOSMCDEV, but return > the real reason is much friendly for debugging. > > Fixes: e49300a6bf62 ("net/smc: add listen processing for SMC-Rv2") > Signed-off-by: Dust Li As you point out the current code is not really wrong. So I am not sure, whether this should be a fix for net, or rather a debug improvement for net-next. > --- > net/smc/af_smc.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/net/smc/af_smc.c b/net/smc/af_smc.c > index bacdd971615e..21d4476b937b 100644 > --- a/net/smc/af_smc.c > +++ b/net/smc/af_smc.c > @@ -2361,7 +2361,7 @@ static int smc_listen_find_device(struct smc_sock *new_smc, > smc_find_ism_store_rc(rc, ini); > return (!rc) ? 0 : ini->rc; > } > - return SMC_CLC_DECL_NOSMCDEV; > + return prfx_rc; > } > > /* listen worker: finish RDMA setup */ For the code change: Reviewed-by: Alexandra Winter