Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3091140pxj; Mon, 10 May 2021 18:36:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwduxymnTCatjtBeESEYRTKrPBj+1FTKTuc9BUTJ20rqEHZpl1sqiB3PKrnHeqbRxsPIMSP X-Received: by 2002:a02:660e:: with SMTP id k14mr24031547jac.9.1620696967417; Mon, 10 May 2021 18:36:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620696967; cv=none; d=google.com; s=arc-20160816; b=AXu5YEwX75DhLD3IWNuRaIe2qkmixR/Df58aAJHl+OktfZ8MS1uQaCW4qAh4h/nWUz LFqXlVpfA2Fm7wnUWNxMupYd47DeD4Laoag69Cr3BuiW+e6Zx9LnWRjXqKhRRjXXgVep mbYM9DhaWASui6v4Gb3yd8lRRa2hzOGDg5VWauUZ/XiqiUuhPvREjw/VEXVHisB44AKL T5dO55xjnw6a+K3Ymlk7EfWflKsI9QbUwYXfSEkQp+Jue1HG8oT9Uv/RPgL8iJoEIcyC kZ5LvyqM3PO1y4gt5CmDg+m1SeuKbKMCVSjydgnJWMIV613ytUCMkW1cwa/pF7RF5Rir Eckg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:reply-to; bh=8sHXDwSRZoLBw9NfpfCY8TLGb43GnBvQGo04zMMYeRw=; b=Uu21s6RfFhB/VVqPfANKwmM0+TSVnLN7G3O2sOJSu9sPeX2HVkgpFSP7cesJKQofK/ +m8gixbahzGEh1JUkT43PnvkcToHeNmuAoeSAGk62fiJiOx7KZvDIcWd8kIKa59gRBH2 L9bSuku8kjl/GWWMQmH6ZnPGyo/g6Wts1e93IGTY/npZ62pjX9VpTp3qZ5mPtlbLQ6R8 P8NUafSXi+ipxj6uSgX5JdqnXb8p8SyVO6WJQPNnW9wazr0OxrFD79wF+VnnNdahka4U Wk8LDdnTVXzzlH9CJOvubwq9jeMOGyMXpUY+7hi+BVV7HMRgEB1uBpZHBIbO06B2ubpX mePg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t128si6676419iof.16.2021.05.10.18.35.54; Mon, 10 May 2021 18:36:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230332AbhEKBgL (ORCPT + 99 others); Mon, 10 May 2021 21:36:11 -0400 Received: from mail-1.ca.inter.net ([208.85.220.69]:47891 "EHLO mail-1.ca.inter.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229628AbhEKBgJ (ORCPT ); Mon, 10 May 2021 21:36:09 -0400 Received: from localhost (offload-3.ca.inter.net [208.85.220.70]) by mail-1.ca.inter.net (Postfix) with ESMTP id 5992B2EA173; Mon, 10 May 2021 21:35:03 -0400 (EDT) Received: from mail-1.ca.inter.net ([208.85.220.69]) by localhost (offload-3.ca.inter.net [208.85.220.70]) (amavisd-new, port 10024) with ESMTP id 8FcpycSND7un; Mon, 10 May 2021 21:14:00 -0400 (EDT) Received: from [192.168.48.23] (host-45-58-219-4.dyn.295.ca [45.58.219.4]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: dgilbert@interlog.com) by mail-1.ca.inter.net (Postfix) with ESMTPSA id 464DE2EA078; Mon, 10 May 2021 21:35:02 -0400 (EDT) Reply-To: dgilbert@interlog.com Subject: Re: [PATCH] blk-mq: Use request queue-wide tags for tagset-wide sbitmap To: Ming Lei , John Garry Cc: axboe@kernel.dk, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-scsi@vger.kernel.org, kashyap.desai@broadcom.com, chenxiang66@hisilicon.com, yama@redhat.com References: <1620037333-2495-1-git-send-email-john.garry@huawei.com> From: Douglas Gilbert Message-ID: <0faa2ad6-4ae9-02b2-2f34-cf58f1e23c5b@interlog.com> Date: Mon, 10 May 2021 21:35:01 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-CA Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021-05-10 8:52 p.m., Ming Lei wrote: > On Mon, May 03, 2021 at 06:22:13PM +0800, John Garry wrote: >> The tags used for an IO scheduler are currently per hctx. >> >> As such, when q->nr_hw_queues grows, so does the request queue total IO >> scheduler tag depth. >> >> This may cause problems for SCSI MQ HBAs whose total driver depth is >> fixed. >> >> Ming and Yanhui report higher CPU usage and lower throughput in scenarios >> where the fixed total driver tag depth is appreciably lower than the total >> scheduler tag depth: >> https://lore.kernel.org/linux-block/440dfcfc-1a2c-bd98-1161-cec4d78c6dfc@huawei.com/T/#mc0d6d4f95275a2743d1c8c3e4dc9ff6c9aa3a76b >> > > No difference any more wrt. fio running on scsi_debug with this patch in > Yanhui's test machine: > > modprobe scsi_debug host_max_queue=128 submit_queues=32 virtual_gb=256 delay=1 > vs. > modprobe scsi_debug max_queue=128 submit_queues=1 virtual_gb=256 delay=1 > > Without this patch, the latter's result is 30% higher than the former's. > > note: scsi_debug's queue depth needs to be updated to 128 for avoiding io hang, > which is another scsi issue. "scsi_debug: Fix cmd_per_lun, set to max_queue" made it into lk 5.13.0-rc1 as commit fc09acb7de31badb2ea9e85d21e071be1a5736e4 . Is this the issue you are referring to, or is there a separate issue in the wider scsi stack? BTW Martin's 5.14/scsi-queue is up and running with lk 5.13.0-rc1 . Doug Gilbert