Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752372AbcLHNEr (ORCPT ); Thu, 8 Dec 2016 08:04:47 -0500 Received: from bombadil.infradead.org ([198.137.202.9]:52055 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752126AbcLHNEq (ORCPT ); Thu, 8 Dec 2016 08:04:46 -0500 Date: Thu, 8 Dec 2016 14:04:34 +0100 From: Peter Zijlstra To: Thomas Gleixner Cc: LKML , x86@kernel.org, Borislav Petkov , "Charles (Chas) Williams" , "M. Vefa Bicakci" , Alok Kataria , Boris Ostrovsky Subject: Re: [PATCH] x86/smpboot: Make logical package management more robust Message-ID: <20161208130434.GR3124@twins.programming.kicks-ass.net> References: <20161208110331.GK3107@twins.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1093 Lines: 23 On Thu, Dec 08, 2016 at 01:49:28PM +0100, Thomas Gleixner wrote: > > > > - if (logical_packages > __max_logical_packages) { > > > - pr_warn("Detected more packages (%u), then computed by BIOS data (%u).\n", > > > - logical_packages, __max_logical_packages); > > > - logical_packages_frozen = true; > > > - __max_logical_packages = logical_packages; > > > > So we'll never 'shrink' the initially computed max; which could result > > in using more memory than strictly needed, otoh it makes physical > > hotplug happier. > > Yes. I was debating that back and forth and at the end decided that making > it simple and robust is a good tradeoff vs. the slightly higher memory > consumption. Though on most systems that's a non issue as number of > possible cpus/packages is the same as the actual available ones. The insane > setups have to suffer - rightfully so. Don't we overestimate by a factor of 2 due to HT? That is, every single socket Intel box will have a max_packages of 2. Not that I care too deeply, and arguably the HT case _is_ insane because its impossible to tell etc..