From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756266AbcIGCHp (ORCPT ); Tue, 6 Sep 2016 22:07:45 -0400 Received: from cn.fujitsu.com ([59.151.112.132]:14618 "EHLO heian.cn.fujitsu.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1755923AbcIGCHo (ORCPT ); Tue, 6 Sep 2016 22:07:44 -0400 X-IronPort-AV: E=Sophos;i="5.22,518,1449504000"; d="scan'208";a="10687195" Subject: Re: [PATCH] x86: Put the num_processors++ code in a more suitable position To: David Rientjes References: <1473139887-27587-1-git-send-email-douly.fnst@cn.fujitsu.com> CC: , , , , From: Dou Liyang Message-ID: <5f72de39-4e4e-ccc3-5167-d5c498830dcf@cn.fujitsu.com> Date: Wed, 7 Sep 2016 10:07:40 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.167.226.106] X-yoursite-MailScanner-ID: 12D104042407.A7DE3 X-yoursite-MailScanner: Found to be clean X-yoursite-MailScanner-From: douly.fnst@cn.fujitsu.com Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi David, At 09/07/2016 05:23 AM, David Rientjes wrote: > On Tue, 6 Sep 2016, Dou Liyang wrote: > >> This is a code optimization. >> > > Not sure that it's optimization, it's just for correctness. Yes, I see. I will improve it in next version. Thanks, Dou > >> If checking the topology package map of apicid and cpu is failure, >> it will stop generating the processor info for that apicid and the >> disabled_cpus will plus one. However, the num-processors has already >> been added one above. That may cause the number of processors incorrect. >> >> Just put the num_processors++ code in the more suitable position. >> it makes sure that the num-processors will not conflict with the >> disabled_cpus. >> >> Signed-off-by: Dou Liyang > > Acked-by: David Rientjes > >