Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp77562rwr; Wed, 19 Apr 2023 03:46:12 -0700 (PDT) X-Google-Smtp-Source: AKy350Ya2i9RutosVv6NQNHd3SZvhD/0DicqVhjgC/t0C7NgFX6D80WjTO/FaP6JOO4HoHfJRZEy X-Received: by 2002:a05:6a00:80d:b0:625:ea57:389b with SMTP id m13-20020a056a00080d00b00625ea57389bmr3526831pfk.5.1681901172056; Wed, 19 Apr 2023 03:46:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681901172; cv=none; d=google.com; s=arc-20160816; b=U9LGfEEjtieWllVXwUgDxwYvs4E8kiQHNHhZmQX/thDwm8TfXuc+xL6cHaUdYeU21L 0X1YeOGCXYqqgIbQySpZk+EskDsL+LYqwUKB2BNuV9r3J+yxkF9HlPoMAC9ZjdKe5pmC WY3bvfksdl0CJiaEkFFRdQmQQdREwY/pnH0o2rx6Ewe5AP5+z+8o8Dxwnwc1/GqU0JRY OTr5cig/sO7xtdWoSkWu/07FD6yzki0r4KQdRjjmyEFuDeRSbaRRNQERan+oCQF2XLwm m9RUrXsCG2+psCqhK/ldm/Ux4aMDKIBONH/JqMPVqBDPsdXWfAZBHtaOPcOA/pYz1sDK ozEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=W4OEHWAdjGNyouDp7WPzL5oQVIukKAIyvltvLfA8gEY=; b=VdtPWXe890+uDn42QJDxZGWIK3iwnWKob1PX42ejf5U67QUFBwu+seNhHCi0eCce3M 5i/Bikyx0bzxBqi66FnU+E4z9gpH4SBvEFRx12UwnxAgHxaHg56hPXPGWmQkIGySWYTy W/kwBgkbj0z+QZ/mhq19SOlBS8FoNZFR+18BBDRTIAt1shORj6tCJJZBrZvmwIE4mH0X vf69BeY5JkiFyOlCxkUNh97JJ/ACbyjgedXr2c+YvYHSRx4IY+neRZJajzf3Toafuqyh M13YTdWdiiR2R/mW7VuG5MFoG1SCtu6qL/dRWbwrROkJz6UbsXb9juvmFo8E/YmjdIEb 1tcA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ionos.com header.s=google header.b=D6Qxt3+I; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=ionos.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 36-20020a631564000000b00502f0ddd50bsi16430737pgv.382.2023.04.19.03.46.00; Wed, 19 Apr 2023 03:46:12 -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=@ionos.com header.s=google header.b=D6Qxt3+I; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=ionos.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232774AbjDSKiP (ORCPT + 99 others); Wed, 19 Apr 2023 06:38:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47272 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232834AbjDSKhu (ORCPT ); Wed, 19 Apr 2023 06:37:50 -0400 Received: from mail-ej1-x631.google.com (mail-ej1-x631.google.com [IPv6:2a00:1450:4864:20::631]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 801FBAD37 for ; Wed, 19 Apr 2023 03:37:44 -0700 (PDT) Received: by mail-ej1-x631.google.com with SMTP id xi5so80327834ejb.13 for ; Wed, 19 Apr 2023 03:37:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ionos.com; s=google; t=1681900663; x=1684492663; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=W4OEHWAdjGNyouDp7WPzL5oQVIukKAIyvltvLfA8gEY=; b=D6Qxt3+Ivw863ySttSPj+hFVUT9Cotn/d1Z7ORCCbcBT5k7XgTCfttOtrF6WaynYcP zB3I2NYIpB/kTmDA0JN6aD6gSRfR7s8P1KCHU+3wCnR/dZ2rXboQBfSrOhtxKjkP9uYb U6Hmxn0HEiMXvGcwHiaawbnIv5fG+rz8ngwUIiLoq0jksJhEVrBXYmlYT0AVfpu2zjU+ G73xvefT3L0/PQg3YaXUokKsx/FenLz8S9YWvb9M9SFWpZ0CTuJhvBAlx/JK1N1mP4YK nLuC2/h5GVkJRIKIZr6q+dq32risIClRD91yLMIYBs17YnFkqtF3hTacjaCV7aOx1Rq+ oAbw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681900663; x=1684492663; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=W4OEHWAdjGNyouDp7WPzL5oQVIukKAIyvltvLfA8gEY=; b=ZOinK0OCJGF7N1OUioqTBCTZchvm2RbFCNKlL70vvjdye8J0ERIOxLIMgJz/S5PtVj 0ye69cE+8fPtCqfMTChjcCZid6//yE5j/oGvu8kMrGdk3/R6MLKC0E5hkguc2h0whO4H V2aD6JuVusv09HBUfTdzO+Vx3uyRdovN+6h8r7Jjvngazm+V0xR4Pzw3rG207dyrh6FN yoWbaiTXiw1wLZgBZd+1ufQPwX2iNXaajU23E/CPBY2yyscX2mYrbawsj7Lbj4ZbhmPT fhmYOfxiHRyYKrW3DKNkl9wl1wF63+yYEIxV9JHzkqRiUKXNUWNIFO85aXgoj29sSrqN tEPw== X-Gm-Message-State: AAQBX9cS6BBCmAUOhUTPbO0soSnCbug+AgO4pEEWHlXbKmmdIxgOVqgf h8iN2de/3m08xUkiCyc8z/h0kqT5twcnyapxgZiC1g== X-Received: by 2002:a17:906:3844:b0:93b:1ca6:6adc with SMTP id w4-20020a170906384400b0093b1ca66adcmr6904385ejc.7.1681900662939; Wed, 19 Apr 2023 03:37:42 -0700 (PDT) MIME-Version: 1.0 References: <1681108984-2-1-git-send-email-lizhijian@fujitsu.com> <1681108984-2-2-git-send-email-lizhijian@fujitsu.com> In-Reply-To: <1681108984-2-2-git-send-email-lizhijian@fujitsu.com> From: Jinpu Wang Date: Wed, 19 Apr 2023 12:37:31 +0200 Message-ID: Subject: Re: [PATCH for-next 1/3] RDMA/rtrs: Remove duplicate cq_num assignment To: Li Zhijian Cc: haris.iqbal@ionos.com, jgg@ziepe.ca, leon@kernel.org, linux-rdma@vger.kernel.org, guoqing.jiang@linux.dev, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 On Mon, Apr 10, 2023 at 8:43=E2=80=AFAM Li Zhijian = wrote: > > line 1701 and 1713 are duplicate: > > 1701 cq_num =3D max_send_wr + max_recv_wr; > 1702 /* alloc iu to recv new rkey reply when server reports flag= s set */ > 1703 if (clt_path->flags & RTRS_MSG_NEW_RKEY_F || con->c.cid =3D= =3D 0) { > 1704 con->rsp_ius =3D rtrs_iu_alloc(cq_num, sizeof(*rsp)= , > 1705 GFP_KERNEL, > 1706 clt_path->s.dev->ib_d= ev, > 1707 DMA_FROM_DEVICE, > 1708 rtrs_clt_rdma_done); > 1709 if (!con->rsp_ius) > 1710 return -ENOMEM; > 1711 con->queue_num =3D cq_num; > 1712 } > > 1713 cq_num =3D max_send_wr + max_recv_wr; > > Signed-off-by: Li Zhijian Thx! Acked-by: Jack Wang > --- > drivers/infiniband/ulp/rtrs/rtrs-clt.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/drivers/infiniband/ulp/rtrs/rtrs-clt.c b/drivers/infiniband/= ulp/rtrs/rtrs-clt.c > index 80abf45a197a..c2065fc33a56 100644 > --- a/drivers/infiniband/ulp/rtrs/rtrs-clt.c > +++ b/drivers/infiniband/ulp/rtrs/rtrs-clt.c > @@ -1710,7 +1710,6 @@ static int create_con_cq_qp(struct rtrs_clt_con *co= n) > return -ENOMEM; > con->queue_num =3D cq_num; > } > - cq_num =3D max_send_wr + max_recv_wr; > cq_vector =3D con->cpu % clt_path->s.dev->ib_dev->num_comp_vector= s; > if (con->c.cid >=3D clt_path->s.irq_con_num) > err =3D rtrs_cq_qp_create(&clt_path->s, &con->c, max_send= _sge, > -- > 2.29.2 >