From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C2690C432C2 for ; Thu, 26 Sep 2019 07:38:19 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 9B4632146E for ; Thu, 26 Sep 2019 07:38:19 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9B4632146E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 365086B000A; Thu, 26 Sep 2019 03:38:19 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 315E76B000C; Thu, 26 Sep 2019 03:38:19 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 205926B000D; Thu, 26 Sep 2019 03:38:19 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0112.hostedemail.com [216.40.44.112]) by kanga.kvack.org (Postfix) with ESMTP id F3A676B000A for ; Thu, 26 Sep 2019 03:38:18 -0400 (EDT) Received: from smtpin16.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with SMTP id 950B4181AC9BF for ; Thu, 26 Sep 2019 07:38:18 +0000 (UTC) X-FDA: 75976268676.16.pet88_48820819e4431 X-HE-Tag: pet88_48820819e4431 X-Filterd-Recvd-Size: 2147 Received: from mx1.suse.de (mx2.suse.de [195.135.220.15]) by imf48.hostedemail.com (Postfix) with ESMTP for ; Thu, 26 Sep 2019 07:38:18 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id C65DEAFE8; Thu, 26 Sep 2019 07:38:16 +0000 (UTC) Date: Thu, 26 Sep 2019 09:38:16 +0200 From: Michal Hocko To: David Hildenbrand Cc: Qian Cai , linux-kernel@vger.kernel.org, linux-mm@kvack.org, Andrew Morton , Oscar Salvador , Pavel Tatashin , Dan Williams , Thomas Gleixner Subject: Re: [PATCH v1] mm/memory_hotplug: Don't take the cpu_hotplug_lock Message-ID: <20190926073816.GC20255@dhcp22.suse.cz> References: <1569337401.5576.217.camel@lca.pw> <20190924151147.GB23050@dhcp22.suse.cz> <1569351244.5576.219.camel@lca.pw> <2f8c8099-8de0-eccc-2056-a79d2f97fbf7@redhat.com> <1569427262.5576.225.camel@lca.pw> <20190925174809.GM23050@dhcp22.suse.cz> <1569435659.5576.227.camel@lca.pw> <92bce3d4-0a3e-e157-529d-35aafbc30f3b@redhat.com> <1569443568.5576.231.camel@lca.pw> <17ba6fc6-72ce-992b-7cc4-812acbdedbeb@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <17ba6fc6-72ce-992b-7cc4-812acbdedbeb@redhat.com> User-Agent: Mutt/1.10.1 (2018-07-13) X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Thu 26-09-19 09:26:13, David Hildenbrand wrote: [...] > I'd like to hear what Michal thinks. If we do want the cpu hotplug lock, > we can at least restrict it to the call paths (e.g., online_pages()) > where the lock is really needed and document that. Completely agreed. Conflating cpu and memory hotplug locks was a bad decision. If there are places which need both they should better use both lock explicitly. Now, the reality might turn out more complicated due to locks nesting but hiding the cpu lock into the mem hotplug is just not fixing that. -- Michal Hocko SUSE Labs