Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp4023711pxb; Tue, 2 Nov 2021 02:42:36 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxwvj4nD9lbRXUBx3GIWRjs3S4UiGrbOc0gV/2E8puNTFyrWxrqbV3d56afQv+jInkG4RgO X-Received: by 2002:a02:b807:: with SMTP id o7mr14255535jam.43.1635846156419; Tue, 02 Nov 2021 02:42:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1635846156; cv=none; d=google.com; s=arc-20160816; b=PO4Qy480VD+idmV+6flfSNRItapmQjd5C8p7VblKW/IWLkXPwhu57SDXcqsO9go5Lg QXBNWEP1ngKYG1PogpzQSWtxUGzjOD2DsdEn0tk608aTHn+rXNtxjECdyzY/BPkPkOf4 eKlxGg/guItyol9rrymDFPJvEGNuEvse+ZCblH6didsFb9bLagqy4zkxzc1R6GQ3/X3H xoZwbYfQLoUH/Xv0MgjqCugI5jUbRvhlk5qIHCTP92KeN0oEDdeq7XY+qrQtVfTc80eB ima0eDro17Awhim3PCy9g9cbYeq7jaZ2ROZKEuDGyud7jGUi7uR8CZOD6Wnz0uGgFi0N LBJg== 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=X+zeEJxaxigpF0JmA9P/IlwLz0CIgiUc5xKVn036itk=; b=Rw8PriyX5EwxPBnfCBl3yxAUb7wxYr1xjSTqS6ru8bez9/CmdJbngb4ar/XCb/2Goc 61DDD/iSJnhzKZLtQdieQPpuOxjWAmp/ufsKWsmlQBLJc6QcVI8FuAlrcVdQSpjWkWSB 8cq1YjYj6+XeO3wTiSv1jRomnaTfz30kj45GWYd+Zl3uh8smJbIqSGFrm7K+i3v7c1zL uaVaEXBMEPOFEJRK1otg7GBxVsq61pqdeAP8OpSwEjieOFzAC8/EGaPMT0jlmFam/Vlm 2kvsjsnOWbUS3wjdJImbTm2Y0mS0ZZv7WGZjvTCFhK5Q8PAMhcgyVluv12F3c3b7oEH8 aacQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=dveKC3cJ; 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; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q3si23934492iow.76.2021.11.02.02.42.24; Tue, 02 Nov 2021 02:42:36 -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=@suse.com header.s=susede1 header.b=dveKC3cJ; 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; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229924AbhKBJnU (ORCPT + 99 others); Tue, 2 Nov 2021 05:43:20 -0400 Received: from smtp-out2.suse.de ([195.135.220.29]:53752 "EHLO smtp-out2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229505AbhKBJnT (ORCPT ); Tue, 2 Nov 2021 05:43:19 -0400 Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out2.suse.de (Postfix) with ESMTP id 3BBCD1FD4C; Tue, 2 Nov 2021 09:40:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1635846044; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=X+zeEJxaxigpF0JmA9P/IlwLz0CIgiUc5xKVn036itk=; b=dveKC3cJXF4f0Xb1Qi1GbO2mKhgv1Z2hP9wvUK2RysymAHkKS8dHG0e4H8nO30XeMkBBrR 9Gp6sP3RVMW8puo2lkQF4UfG5kETc+zVQmF9pPnLXRvxdFsMAAd1bSMToobaQ3w6E9VKZ1 0cMWOnvn9XbFOlE98Q3L18SVsbaR+xQ= Received: from suse.cz (unknown [10.100.201.86]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id 0EBC7A3B81; Tue, 2 Nov 2021 09:40:44 +0000 (UTC) Date: Tue, 2 Nov 2021 10:40:43 +0100 From: Michal Hocko To: Alexey Makhalov Cc: David Hildenbrand , "linux-mm@kvack.org" , Andrew Morton , "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" , Oscar Salvador Subject: Re: [PATCH] mm: fix panic in __alloc_pages Message-ID: References: <20211101201312.11589-1-amakhalov@vmware.com> <7136c959-63ff-b866-b8e4-f311e0454492@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 02-11-21 10:04:23, Michal Hocko wrote: [...] > > Is there any reason why try_online_node() resides in cpu_up() and not in add_cpu()? > > I think it would be correct to online node during the CPU hot add to align with > > memory hot add. > > I am not familiar with cpu hotplug, but this doesn't seem to be anything > new so how come this became problem only now? Just looked at the cpu hotplug part. I do not see add_cpu to add much here. Here is what I can see in the current Linus tree add_cpu device_online() # cpu device - cpu_sys_devices with cpu_subsys bus dev->bus->online -> cpu_subsys_online cpu_device_up cpu_up try_online_node So we should be bringing up the node during add_cpu. Unless something fails on the way - e.g. cpu_possible check or something similar. -- Michal Hocko SUSE Labs