From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Miller Subject: Re: [PATCH][net-next] net: replace num_possible_cpus with nr_cpu_ids Date: Sun, 08 Jul 2018 13:04:22 +0900 (KST) Message-ID: <20180708.130422.1348974189124299562.davem@davemloft.net> References: <1530869616-3572-1-git-send-email-lirongqing@baidu.com> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org To: lirongqing@baidu.com Return-path: Received: from shards.monkeyblade.net ([23.128.96.9]:38026 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750729AbeGHEEY (ORCPT ); Sun, 8 Jul 2018 00:04:24 -0400 In-Reply-To: <1530869616-3572-1-git-send-email-lirongqing@baidu.com> Sender: netdev-owner@vger.kernel.org List-ID: From: Li RongQing Date: Fri, 6 Jul 2018 17:33:36 +0800 > The return of num_possible_cpus() is same as nr_cpu_ids, but > nr_cpu_ids can reduce cpu computation > > Signed-off-by: Li RongQing These two numbers are not the same, in fact num_possible_cpus() can be and often is smaller than nr_cpu_ids.