Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp4868779yba; Wed, 10 Apr 2019 06:40:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqyxoON1AAvOTVLAZ7BCvdTTF4gugE4N5PvTmPkzxreeykgA0E/85xWNb9yE/ua9Z/tGliWm X-Received: by 2002:a63:494f:: with SMTP id y15mr41482939pgk.56.1554903602416; Wed, 10 Apr 2019 06:40:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554903602; cv=none; d=google.com; s=arc-20160816; b=KzE188IpDbUtcF4gzwNKNTTrveB/sFGOeu7ta/GrsAds+efvEyhPNuK6X8Z3qT2Wxy 3jYHneqsx79CYz6GdWO1uDolBf7knMBMwPUlT83i4VuGCOa+S/FAFOcT3AW1hKWxjojQ FJgEnf/Ji7FxLNipbk0f8Q4NAvGgj5/r2RhEA3MjlFNRDFDjxO4MCrYPzzF3xmTXqs+3 0oTfuUjXKb3tbHOQcwLl56jmllzRHVQexbUVyywoEHXLNVrB2Ur9Yg7nbhUojYKILqka 9lkNtxU9l6x0WRiPNGn8UwEKgfVZ368ItWAO2phyPuvMSMSGHbyIdiKrMnLWxBLU7BU8 QyGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=MJjOw7gLRA9Z0EsZtzhG/ZGdJ47pG0jq45MOivKigF4=; b=LveF/ikjABiaA8Qfoh4J/8RwMXAg9DMtx3w/PwP9FD5nUCcSCLnrBq/KY3yFWWFGQN RdsxHu8nAnLru8Gox9KhSkpFo6uW44aX+TvKkCxl9bkb1g6OPxp/KRZv3jxCogFmRef6 SI44HsVx2JG5nA9fKQrFHitLHOCbAz7BD5+t0WpgBBfx6sjtq97b741emq+QwO6c+g3p lHqE+dmApVNQ0LdF5HVnGRH6oH5vp1N5PAdzt+GOAZCqxcAvWhBXAh1ucWk88wxViL0+ SKbRJcMYKgu/5PqfIP5zyaKnXxxDb6pidf3snW4AOvACuemeqrE2Y/zWvRhnUiv4J1wd 3FmQ== 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 k24si31746274pfk.284.2019.04.10.06.39.46; Wed, 10 Apr 2019 06:40:02 -0700 (PDT) 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 S1732353AbfDJNMl (ORCPT + 99 others); Wed, 10 Apr 2019 09:12:41 -0400 Received: from mx1.redhat.com ([209.132.183.28]:48182 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729013AbfDJNMl (ORCPT ); Wed, 10 Apr 2019 09:12:41 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id F0C982D7ED; Wed, 10 Apr 2019 13:12:40 +0000 (UTC) Received: from localhost (ovpn-117-202.ams2.redhat.com [10.36.117.202]) by smtp.corp.redhat.com (Postfix) with ESMTP id 123511062225; Wed, 10 Apr 2019 13:12:32 +0000 (UTC) Date: Wed, 10 Apr 2019 14:12:28 +0100 From: Stefan Hajnoczi To: Dongli Zhang Cc: linux-scsi@vger.kernel.org, virtualization@lists.linux-foundation.org, linux-block@vger.kernel.org, mst@redhat.com, jasowang@redhat.com, axboe@kernel.dk, jejb@linux.ibm.com, martin.petersen@oracle.com, cohuck@redhat.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH 2/2] scsi: virtio_scsi: limit number of hw queues by nr_cpu_ids Message-ID: <20190410131228.GB8210@stefanha-x1.localdomain> References: <1553682995-5682-1-git-send-email-dongli.zhang@oracle.com> <1553682995-5682-3-git-send-email-dongli.zhang@oracle.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="BwCQnh7xodEAoBMC" Content-Disposition: inline In-Reply-To: <1553682995-5682-3-git-send-email-dongli.zhang@oracle.com> User-Agent: Mutt/1.11.3 (2019-02-01) X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Wed, 10 Apr 2019 13:12:41 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --BwCQnh7xodEAoBMC Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Mar 27, 2019 at 06:36:35PM +0800, Dongli Zhang wrote: > When tag_set->nr_maps is 1, the block layer limits the number of hw queues > by nr_cpu_ids. No matter how many hw queues are used by virtio-scsi, as it > has (tag_set->nr_maps =3D=3D 1), it can use at most nr_cpu_ids hw queues. >=20 > In addition, specifically for pci scenario, when the 'num_queues' specifi= ed > by qemu is more than maxcpus, virtio-scsi would not be able to allocate > more than maxcpus vectors in order to have a vector for each queue. As a > result, it falls back into MSI-X with one vector for config and one shared > for queues. >=20 > Considering above reasons, this patch limits the number of hw queues used > by virtio-scsi by nr_cpu_ids. >=20 > Signed-off-by: Dongli Zhang > --- > drivers/scsi/virtio_scsi.c | 1 + > 1 file changed, 1 insertion(+) Reviewed-by: Stefan Hajnoczi --BwCQnh7xodEAoBMC Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEcBAEBAgAGBQJcreu8AAoJEJykq7OBq3PIvCcIAJk0lXKMxHlM2G2cGbmwHZh+ Vg/WLG3lMPI+4bn8Ze+aH4LqvwJWaFbd9hjs0hQ4UuDZ2obQi8neJYeUx1ZD0Wii dOnHvCtFxvhEOKGNv9aW8EUbMrV1Aytji+inw1Cf6xawY5G8qg1LEBKd4a341Zkm jEMguwG9Rt1fBQbd9jP14Nbj2VyD/qAxDQVC8Cd0DfLEmfjl35HEu+bvHcMnUFw5 h/WsViGOWzKmk/3YVOLzSXrbf8kgdBu30knaYhYWR/OkJkTDqGiy5kf2eqdWSLcD RWtZxZzpMM0hoh4GwExjnCBhw0G8npzermidU/6a1j9zk74CEUvBGj0H2RfzXEA= =kK0F -----END PGP SIGNATURE----- --BwCQnh7xodEAoBMC--