Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp146093pxk; Thu, 24 Sep 2020 01:44:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwxN6lasj3kVZSWRYxEuYhWmHbjdv79JG92Jl+OcuJwsXt0sxXVg7as2vQtpsF91HkROGeU X-Received: by 2002:a17:906:6a50:: with SMTP id n16mr3411978ejs.107.1600937077509; Thu, 24 Sep 2020 01:44:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600937077; cv=none; d=google.com; s=arc-20160816; b=sDkpJN1AcKjWejzM1HRrSS0fLkbQJeUs48llXeDMMzjY/oY+YOc0iwbt0y96TGd6vi l4KvlZOQYZU9q+5xTUOZfE81saI5OBnDE7rt6387AmTP9BrHcyAgrZNIzDtfeO06C2Ay iHDB6MZm2icj3DMkqWxszv6SHhY/cXwn4X7AN/pOmW+0PMCYnCcSYzi85KQJEsQ9o1L1 RvauGOnw7DR6+txxlcUJSB+6767/LSDIg8n5uL2KIWjf6KE0EDid/QokjQcrb0wIA803 /yYN1UUxLwM9Bq8gVU/3B6E639YHmIfxACetYqiI5r9lpwX4PNxBOPelMUxHnQyyw2sv 5pAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=BYGaYeZy7O/cE9jnxvRSsyfEoRwhvx5uKucxB91Jbto=; b=cNwEyPR5m6uO3NPcSiZ/1rWRJzeFK1aG2Lkg/YcEvfTt8HEhC3ueu3GcnHmouVXPRe N4LpMlQMLbpC6pORCKZEG86uj9LRnvCmOW6+hjuIOqzIBYCH5BW8A6ScTFdwclcjZaHx 2l2bd3ecfXJ0Ss8pp4pIrHOC5x1I6g3+Av0MiRDeaU05O9rRlTdONeKkta5M5WX2AwWu GMtkooKjerRD0jlCVg6oAIaDgd2XxQxab2cB1a4k5EIUBsHStkFn4K6z3HOTGpsk1FeQ DU96oyp+DjkS7MEJjEcj1yfRTOYwP/poq7OrnTTLmW6LnPdjffLz7pDcfrSVkcku4Dul qbWw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=NQrDryyM; 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 d25si1951746edn.340.2020.09.24.01.44.13; Thu, 24 Sep 2020 01:44:37 -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; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=NQrDryyM; 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 S1727308AbgIXIk4 (ORCPT + 99 others); Thu, 24 Sep 2020 04:40:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726837AbgIXIkz (ORCPT ); Thu, 24 Sep 2020 04:40:55 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 71F44C0613CE; Thu, 24 Sep 2020 01:40:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=BYGaYeZy7O/cE9jnxvRSsyfEoRwhvx5uKucxB91Jbto=; b=NQrDryyM8/8XWZLoL/bHX/5Jf4 EqZRkl8SqHwUThU2gImt+rOyXz3dbu8OajVRhBk7JQl8mqMnMJCJZfrVLVRuUapGjxQXXFzvNXOOM vC9fxEiDmran95ioWVWVIRveiU0HsfDxm+vi3XMoX1sD5Zxxw8TL0YNUEH+16xBv1oDLir61ZX7dV AwoJgZuQHxy2xz/mMol0i3EDAtAcRhXywT+5le1YHmVaCC9Pu4FJk/mDcTdFpZiAjfHcMA3dtt7bd /Bx3r6thN6q6dJJaQ93L3zqeSNh7U4iDSGZjTO43IUgGTHqOtKnPCkSQIEfA/81M46D4qfjiy/rNH 4KXFAQRw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1kLMnp-00084D-Is; Thu, 24 Sep 2020 08:40:33 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 4FD5C3007CD; Thu, 24 Sep 2020 10:40:30 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id E59382BC141EA; Thu, 24 Sep 2020 10:40:29 +0200 (CEST) Date: Thu, 24 Sep 2020 10:40:29 +0200 From: peterz@infradead.org To: Nitesh Narayan Lal Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-pci@vger.kernel.org, intel-wired-lan@lists.osuosl.org, frederic@kernel.org, mtosatti@redhat.com, sassmann@redhat.com, jesse.brandeburg@intel.com, lihong.yang@intel.com, helgaas@kernel.org, jeffrey.t.kirsher@intel.com, jacob.e.keller@intel.com, jlelli@redhat.com, hch@infradead.org, bhelgaas@google.com, mike.marciniszyn@intel.com, dennis.dalessandro@intel.com, thomas.lendacky@amd.com, jerinj@marvell.com, mathias.nyman@intel.com, jiri@nvidia.com, mingo@redhat.com, juri.lelli@redhat.com, vincent.guittot@linaro.org Subject: Re: [PATCH v2 1/4] sched/isolation: API to get housekeeping online CPUs Message-ID: <20200924084029.GC1362448@hirez.programming.kicks-ass.net> References: <20200923181126.223766-1-nitesh@redhat.com> <20200923181126.223766-2-nitesh@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200923181126.223766-2-nitesh@redhat.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Sep 23, 2020 at 02:11:23PM -0400, Nitesh Narayan Lal wrote: > Introduce a new API hk_num_online_cpus(), that can be used to > retrieve the number of online housekeeping CPUs that are meant to handle > managed IRQ jobs. > > This API is introduced for the drivers that were previously relying only > on num_online_cpus() to determine the number of MSIX vectors to create. > In an RT environment with large isolated but fewer housekeeping CPUs this > was leading to a situation where an attempt to move all of the vectors > corresponding to isolated CPUs to housekeeping CPUs were failing due to > per CPU vector limit. > > Signed-off-by: Nitesh Narayan Lal > --- > include/linux/sched/isolation.h | 13 +++++++++++++ > 1 file changed, 13 insertions(+) > > diff --git a/include/linux/sched/isolation.h b/include/linux/sched/isolation.h > index cc9f393e2a70..2e96b626e02e 100644 > --- a/include/linux/sched/isolation.h > +++ b/include/linux/sched/isolation.h > @@ -57,4 +57,17 @@ static inline bool housekeeping_cpu(int cpu, enum hk_flags flags) > return true; > } > > +static inline unsigned int hk_num_online_cpus(void) This breaks with the established naming of that header.