Received: by 10.223.185.116 with SMTP id b49csp6527740wrg; Wed, 28 Feb 2018 10:56:41 -0800 (PST) X-Google-Smtp-Source: AH8x2275F9zs+cfG/pb2ddQ8QNMuJ898GQHL7oFG8+9+86d/VhpbKYNIpUSyfeNW9BKAlBBl391d X-Received: by 2002:a17:902:7b95:: with SMTP id w21-v6mr18764625pll.35.1519844201414; Wed, 28 Feb 2018 10:56:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519844201; cv=none; d=google.com; s=arc-20160816; b=hVgigr6vbpx2FLCl4Yh2Vsw7txvV50DvfL5ERg8Gr1xwxcZBUUiP8eaRrgpaTHGYIr ngQ8vrZgpg4jfcIJZc/aH4ze74m0T3jeNbagjfIebCgqkKdE/A+RUFhIwNbVBpQ4nNCB +pSnuIYAw41L4LFOl/I4SbEr1WSEvhC2QcRHvgk/KNke/1vigd0jDoAKMhqx0u9xMBjC hBrzqxfaJb+0pB7jkc6jwmXzv8yktLwPwt4wD6Sl7tZRuLO0IQ/KZcHFtNBUCYsYLkur GLfqg42BplAkImVf81SefNmzu7ssh+Cr9n/FVN+93ghiVbg9HB66/RXlksfsT6nKMX60 fsuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:organization:references :in-reply-to:date:cc:to:from:subject:message-id :arc-authentication-results; bh=3AWKYObkz5iZRWGTWt38XYc77BQggRkyL9SFX/41UfQ=; b=AK3BGUK8x55RL7XtDfBzPKYZUjIldACH3kpjA7DqCZPwMebS6C8G+rIM7os5DQMtat IXgaXCoKEXHkBlrleQjqqxGcnoyNXbOzrT5cVNYyu6QmPgqtJbR+1J6LqjJQ+4W2Q/re z7GiCkL/BMWTV7cfvIdghIZWFuPsZMb8X8ombhjg9x6WU5JxRR8OQUtCrJNrFH3WfVEh +zenACDr3oG/86A1Oq9KFAOmiUAWQNnlzmlZ6BeUBUzxfPKn0JXFPz5yylWKXgEfOUXr PSokR4Zqxuuh2fKDbBA9LGsSanlvf+rnM0MOqmX3iWOnG71/j1pGmBZiyINvKB5bDL/i KEnQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a8-v6si1668038ple.435.2018.02.28.10.56.27; Wed, 28 Feb 2018 10:56:41 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752998AbeB1SzS (ORCPT + 99 others); Wed, 28 Feb 2018 13:55:18 -0500 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:34426 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752601AbeB1SzQ (ORCPT ); Wed, 28 Feb 2018 13:55:16 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id BB04CF042C; Wed, 28 Feb 2018 18:55:15 +0000 (UTC) Received: from haswell-e.xsintricity.com (ovpn-120-89.rdu2.redhat.com [10.10.120.89]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E564D9C056; Wed, 28 Feb 2018 18:55:14 +0000 (UTC) Message-ID: <1519844114.28560.216.camel@redhat.com> Subject: Re: [PATCH] RDMA/core: reduce IB_POLL_BATCH constant From: Doug Ledford To: Max Gurtovoy , Bart Van Assche , Jason Gunthorpe , Sagi Grimberg Cc: Chuck Lever , "arnd@arndb.de" , "linux-kernel@vger.kernel.org" , "leonro@mellanox.com" , "linux-rdma@vger.kernel.org" Date: Wed, 28 Feb 2018 13:55:14 -0500 In-Reply-To: <1e7c373f-21bd-4d45-3dd6-68467bf09d0d@mellanox.com> References: <20180220205924.2035765-1-arnd@arndb.de> <1519161268.3737.12.camel@wdc.com> <0f90134c-3d40-1d24-711f-e4ab32802bd8@mellanox.com> <20180227220958.GA21714@ziepe.ca> <193aaf91-c9d1-38b1-a89f-45f129ca5798@mellanox.com> <1e7c373f-21bd-4d45-3dd6-68467bf09d0d@mellanox.com> Organization: Red Hat, Inc. Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="=-CYAKZfCrWJJbB8XaESeN" Mime-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.11.54.5 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 28 Feb 2018 18:55:15 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 28 Feb 2018 18:55:15 +0000 (UTC) for IP:'10.11.54.5' DOMAIN:'int-mx05.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'dledford@redhat.com' RCPT:'' Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-CYAKZfCrWJJbB8XaESeN Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, 2018-02-28 at 11:50 +0200, Max Gurtovoy wrote: >=20 > On 2/28/2018 2:21 AM, Bart Van Assche wrote: > > On 02/27/18 14:15, Max Gurtovoy wrote: > > > -static int __ib_process_cq(struct ib_cq *cq, int budget, struct ib_w= c=20 > > > *poll_wc) > > > +static int __ib_process_cq(struct ib_cq *cq, int budget, struct ib_w= c=20 > > > *poll_wc, > > > + int batch) > > > { > > > - int i, n, completed =3D 0; > > > - struct ib_wc *wcs =3D poll_wc ? : cq->wc; > > > + int i, n, ib_poll_batch, completed =3D 0; > > > + struct ib_wc *wcs; > > > + > > > + if (poll_wc) { > > > + wcs =3D poll_wc; > > > + ib_poll_batch =3D batch; > > > + } else { > > > + wcs =3D cq->wc; > > > + ib_poll_batch =3D IB_POLL_BATCH; > > > + } > >=20 > > Since this code has to be touched I think that we can use this=20 > > opportunity to get rid of the "poll_wc ? : cq->wc" conditional and=20 > > instead use what the caller passes. That will require to update all=20 > > __ib_process_cq(..., ..., NULL) calls. I also propose to let the caller= =20 > > pass ib_poll_batch instead of figuring it out in this function.=20 > > Otherwise the approach of this patch looks fine to me. >=20 > Thanks Bart. > I'll make these changes and submit. That sounds reasonable to me too, thanks for reworking and resubmitting. --=20 Doug Ledford GPG KeyID: B826A3330E572FDD Key fingerprint =3D AE6B 1BDA 122B 23B4 265B 1274 B826 A333 0E57 2FDD --=-CYAKZfCrWJJbB8XaESeN Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEErmsb2hIrI7QmWxJ0uCajMw5XL90FAlqW+xIACgkQuCajMw5X L92yoBAAoX6ppzz3BTC8UJViwV+8KOklKRhAcs7HQ6+oxxRBLTQrwkARXIEAVUSD w4/rQIp9T4UPIIrtzqmLIji5QStlABbpIko02BMUsZ0zw3t6PTNX0QkbyCXeXxdn FDP7tHATdQue1ONhqsNM3YLDy2qeazxCiYQsqvzx+YmkVkmaoeKF5bK9BTjnuDQa UsBD20RBDUEhm911fYTP0ah8JrVWfaiafhdZAzp/vSWzP2Wrqb+crblWjZ0N0x3f d5Z4ESq0HAlv0OhiBklxyLrws3MjMyJrDeOJ06s3btr7dqIjbnBeveDO8vGJSUGx Bd/maWQ1AKobevvys2oPc5cNO7eXZPWk6wjGa8ZqOmfTm5X0V6V71v0kB7hGks+e K1bJcbQvfO4M+HqbGdbDdHVA1KtWBhbqCUIkVixrPi4g2JKfunwBwih6DEVuAMOj CqX3semucdFc8v8q0/AQlFZmkgZfVEuig2N5OUdVzKihOL1jeIDbsaM4DzZK8V41 aLAAbVuHZ/8MJ0USUvZskvEUfbhA3JUEkKpqrwdaA5EvFLTNwDoEZri+JXPYQ3Tr +fV3pcPtvPtsOjM8nCdTKVWmiYc1/iTEATtMk86/K58V78LUV4rUxb1QboDr+Gcv XbGQPWQDCfxTLPnJ4c/g2jrMqLIMt9Bgf2SIgawRcwHAsNyvZfE= =pUan -----END PGP SIGNATURE----- --=-CYAKZfCrWJJbB8XaESeN--