Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp36267936rwd; Mon, 10 Jul 2023 21:29:57 -0700 (PDT) X-Google-Smtp-Source: APBJJlE2SosKvReOs9b3s+HOWFW6WP0mdobH1Op5FSnHWen7xs77owX0h1JXonV5c67SGLSZ2msB X-Received: by 2002:a17:90a:bc92:b0:263:43a1:b10a with SMTP id x18-20020a17090abc9200b0026343a1b10amr10248254pjr.27.1689049796649; Mon, 10 Jul 2023 21:29:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689049796; cv=none; d=google.com; s=arc-20160816; b=l2ty0qBFZnocIk6cBUqXWLGSr9h9m+VjrdIpnVp8IT0tM5ZLQ4ltTKeEtuYEucQ2Vi CbuYL/sow1z6buffKjPlLw33+wSx++cnB0E7yXtGM9+PVqRKPoha99gQ1tkCXYcfF6v+ SJEN+mKcbuwJeodZiHtMZl4W/xYwiHQHhqVs82OgxH/E7aEsEdogVSO2vQJHkWmstHRy 3Y0U7eXd+ugsyiMmWVNdT7KWy0UGfTsKXHX0U/vMJi1dMlWZI1vQ+ru3KDnfRC1CLv5D cwgO6OrD4b48J7m1tAZWiY1uIs/UbN5JusTUbOxISSA/rDFKoIBhQSZOsG3KT5GbeCN9 sHSA== 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=Sanp52G7qe4emaxcQItrkn4g0y24nEg66UbSkbqz794=; fh=Z1S2nMge+HjkVkSzYlIEoNsCcz6w6appn6rBtG4W4VA=; b=Ch9XVGBkJMuY7Tmk+iqXHRl/nl2VjCNjqhKJV4J7v5Fvo6gE9rnNsl0/QAdpeY0+v9 4u59MPefimpiW24UcchQEOJ/6h4UIqcRzlo0kG+Vo9oX4nWPozNkzLcqhhkmMMybCCTS HtSwbVDLF4/I8aSC54huuoaQGxJiJfaT9umm/Sc1qy9l0U+DOkBSbA9snMX9HVPUeS8u TlMGpluA6YGJQiqMFBnqU8uljdAyh1auPCC4baQdt3WAGZRk4MzqvnJA9LWl9g+rvC1R 7Xnup3itc5RXCGmEnxQ+v5XPvjBI2WJCGSMPBynbND4Aa83VmWvkHvjilTnwDgUPIN7S kWfQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=e+Z9cLEz; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y6-20020a17090a390600b00263bf1c6dc0si7763342pjb.102.2023.07.10.21.29.44; Mon, 10 Jul 2023 21:29:56 -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=@redhat.com header.s=mimecast20190719 header.b=e+Z9cLEz; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229655AbjGKEG0 (ORCPT + 99 others); Tue, 11 Jul 2023 00:06:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39984 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229583AbjGKEGZ (ORCPT ); Tue, 11 Jul 2023 00:06:25 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4BAB1135 for ; Mon, 10 Jul 2023 21:05:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1689048337; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Sanp52G7qe4emaxcQItrkn4g0y24nEg66UbSkbqz794=; b=e+Z9cLEzq+yZ4M+eUzzHl1G9CV6nL7emo9Qy+kzQciQ9BDP/ymVgNPUOLVUaaisUVpYQED w1yU5zwUEOTdjmAp/6m5g32Y33Y7I3hqd8PZhvt+mTJAExxHB9b2kVvZTUgl94LqRTxsoG JtaYX65U+J+9kvga/ayGgt4vfGpasAI= Received: from mail-qv1-f70.google.com (mail-qv1-f70.google.com [209.85.219.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-459-usLv1MgwPzqyMLFYEeDmjQ-1; Tue, 11 Jul 2023 00:05:36 -0400 X-MC-Unique: usLv1MgwPzqyMLFYEeDmjQ-1 Received: by mail-qv1-f70.google.com with SMTP id 6a1803df08f44-6351121aa10so55607866d6.0 for ; Mon, 10 Jul 2023 21:05:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689048336; x=1691640336; 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=Sanp52G7qe4emaxcQItrkn4g0y24nEg66UbSkbqz794=; b=E6FRnouoEweQig7fswyPWzicvFBr/BO1vnSBn7dKC9zHShraaW9eCcuJHtYReMyqMZ rR1vxwj6GRO5B2sHtRrT6zFnJHDLYYBafFTJLsLIKpf2jdv5loyyjD59IXVOYm3S7qfQ exHpKTaz3rEnRs3NhKJUHpfUh789JFvAwSKdhDGSz73MVBIInfE2iW7mLUxXjHwesewH BmiSxsfd9KeWUnSdmcTmPf5dpvmRB4a+ZWZVYXcMkTHflNRZBWLwi0pgLSgJDF2JW0+g KNmuA8G+vbysbh6OkHDtfEVdDsMXVUoCHgxph+8c/bwRU1TejBo+C45EnSonvpRoNtTP 1hnQ== X-Gm-Message-State: ABy/qLYTZ6bIWhIW7r7xm5p3kcNUo+eGn7VYkLWBeB6R9dKtaim1N89F 4WfFq03v3yncLz36FUOfkLP3auHwf15fyDl/n53rVNZZZcjhZ6FYaxnv5VQ8mz2T39netExrXt3 xHA493AeLYYd4nOSHftBgz6rIs9fDvOgHvKxgAv/w X-Received: by 2002:a0c:e44d:0:b0:62d:ef66:ff1c with SMTP id d13-20020a0ce44d000000b0062def66ff1cmr12076653qvm.24.1689048335874; Mon, 10 Jul 2023 21:05:35 -0700 (PDT) X-Received: by 2002:a0c:e44d:0:b0:62d:ef66:ff1c with SMTP id d13-20020a0ce44d000000b0062def66ff1cmr12076645qvm.24.1689048335643; Mon, 10 Jul 2023 21:05:35 -0700 (PDT) MIME-Version: 1.0 References: <20230708020259.1343736-1-ming.lei@redhat.com> <20230708020259.1343736-3-ming.lei@redhat.com> <20230710064109.GB24519@lst.de> In-Reply-To: From: Pingfan Liu Date: Tue, 11 Jul 2023 12:05:24 +0800 Message-ID: Subject: Re: [PATCH 2/2] nvme-pci: use blk_mq_max_nr_hw_queues() to calculate io queues To: Ming Lei Cc: Christoph Hellwig , Jens Axboe , linux-nvme@lists.infradead.org, linux-block@vger.kernel.org, Wen Xiong , Keith Busch , Dave Young , kexec@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, mpe@ellerman.id.au, Thomas Gleixner 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,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE,SPF_NONE, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham 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 Hi Ming, Having no [PATCH 1/2] blk-mq: add blk_mq_max_nr_hw_queues() in inbox. So I reply here. At first glance, I think that the cpu hot plug callback hook should be the remedy for the newly introduced blk_mq_max_nr_hw_queues(), although it is more complicated. Consider the scene where nr_cpus=3D4, which can speed up the dumping process, the blk_mq_max_nr_hw_queues() can not utilize the other three cpus. Thanks, Pingfan On Mon, Jul 10, 2023 at 5:16=E2=80=AFPM Ming Lei wrot= e: > > On Mon, Jul 10, 2023 at 08:41:09AM +0200, Christoph Hellwig wrote: > > On Sat, Jul 08, 2023 at 10:02:59AM +0800, Ming Lei wrote: > > > Take blk-mq's knowledge into account for calculating io queues. > > > > > > Fix wrong queue mapping in case of kdump kernel. > > > > > > On arm and ppc64, 'maxcpus=3D1' is passed to kdump command line, see > > > `Documentation/admin-guide/kdump/kdump.rst`, so num_possible_cpus() > > > still returns all CPUs. > > > > That's simply broken. Please fix the arch code to make sure > > it does not return a bogus num_possible_cpus value for these > > That is documented in Documentation/admin-guide/kdump/kdump.rst. > > On arm and ppc64, 'maxcpus=3D1' is passed for kdump kernel, and "maxcpu= =3D1" > simply keep one of CPU cores as online, and others as offline. > > So Cc our arch(arm & ppc64) & kdump guys wrt. passing 'maxcpus=3D1' for > kdump kernel. > > > setups, otherwise you'll have to paper over it in all kind of > > drivers. > > The issue is only triggered for drivers which use managed irq & > multiple hw queues. > > > Thanks, > Ming > > > _______________________________________________ > kexec mailing list > kexec@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/kexec >