Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp1962875imm; Thu, 27 Sep 2018 05:26:03 -0700 (PDT) X-Google-Smtp-Source: ACcGV63HG0jbTAk1Fxi0VaZwHX/7YNbyh8KSgDlZGZVJgAZueB6ZIQGRq9jAZhMtp4ywmE1lkiTf X-Received: by 2002:a62:46c8:: with SMTP id o69-v6mr11316949pfi.21.1538051163761; Thu, 27 Sep 2018 05:26:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538051163; cv=none; d=google.com; s=arc-20160816; b=ww9qm8rEoH0wzHVumLs5A8qppFMJy+xx5jIc72ptQx4emt7X5rCE+g7VGBAfxvGzQy NhsmN5Q0u5ShdhjGwhwBcehZhzOGjXp63eKRtukdldRSDeRh2OB0vHP5fRN0NhdFzT4S 3GrR7pDlxXr7nE5Il7rRrbZxWoWvQKDjY/nwtD64aQtwHMLZ1gqxOD+EmrxGjgGRl9/+ MF3vnjW62E4vqiP3wniJ4J/UQDXxhkcrYQCll7ZHtVm8UL6dmVnp+Q2leS4ScEMom4U9 L2irj45OHKcEzhcwr+G4+jbKw0w89YcdJFFCxhzRcn6lw3GAmHOnUHF9LnPa6DE4FnTE JJAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=b88dDxTrGoai73Q1rgb8VsJ3rxjPkVTsNfjYYRh81Us=; b=ijah/rJGrIEeKq+gQyjHy5lVKU+cKr+tN/VMnwTbXh2ds7r3+ys2wc36vo5zRrvf0y 0J+n0npJxx/TLnrDKzV0WHl6IpX+S3N4HmvumSftJ6YpnhSXjbFCDG/eSVyJSOEcsoD3 CBECef/RqM+pDdjqSC28vSGdlv4KDFuXqR3t+mA0lY63f93kp4ZVjLPiDctIHaDanBY3 KqF+6+ZxGRuk1V3Yw74zeZYZv/jkIRNeOqHXiizuA7bGsXS68F9Bft8FKYd3FFOxmx5t QmuyJkk79qAhDRhqsegi9Da1XkHJv8rWyJkxURHzF3eOQ3swQf4A3cs15eZveAr6A8ke NkfA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t123-v6si1891385pgc.662.2018.09.27.05.25.47; Thu, 27 Sep 2018 05:26:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727262AbeI0Snn (ORCPT + 99 others); Thu, 27 Sep 2018 14:43:43 -0400 Received: from mail-wm1-f66.google.com ([209.85.128.66]:36961 "EHLO mail-wm1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727062AbeI0Snn (ORCPT ); Thu, 27 Sep 2018 14:43:43 -0400 Received: by mail-wm1-f66.google.com with SMTP id y26-v6so5165834wma.2 for ; Thu, 27 Sep 2018 05:25:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=b88dDxTrGoai73Q1rgb8VsJ3rxjPkVTsNfjYYRh81Us=; b=MuWzWp8FgBa4+m0PqkfYggzHR9LkZwvmKRmJUDVLAdrJJxm5KUcuy5DQw/7bpHEZk5 n/AKK7NC1X+X5BJR3XcYfMxqQyTgp3jQzVcR2sBHtkFBLWzWpdLT8fSJ9fn/Qq9AE7xb dkQxiaft6lf3MT9N3I+3r8tevnNKG4qzT9/zYTbZOfEIOyaJCs2vbYBsBv0j+Xcpi3eJ E6dmZKJXUd96zGM98j4tVsPXAjzPbbNs1u7qWv4s8LrHdBAME2zYEZQQLzXna++KR6NS rAtMDXJ+Fzx7yNjvPqWZYxiBrWgUzw33Ym9rOtvGwrzfrRajhChGRt/oW/kbl9BxDgxA a4yA== X-Gm-Message-State: ABuFfoj2GclnMd3y0AYQ57cASyQy8ezp2fKRSHgbuVAOds4fQ+d1uWH6 SjXN62GUdg7aV6F8joMszGU= X-Received: by 2002:a1c:8dd1:: with SMTP id p200-v6mr7780067wmd.145.1538051138864; Thu, 27 Sep 2018 05:25:38 -0700 (PDT) Received: from techadventures.net (techadventures.net. [62.201.165.239]) by smtp.gmail.com with ESMTPSA id s10-v6sm1753831wrw.35.2018.09.27.05.25.37 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 27 Sep 2018 05:25:37 -0700 (PDT) Received: by techadventures.net (Postfix, from userid 1000) id 45B21125618; Thu, 27 Sep 2018 14:25:37 +0200 (CEST) Date: Thu, 27 Sep 2018 14:25:37 +0200 From: Oscar Salvador To: Michal Hocko Cc: Alexander Duyck , linux-mm@kvack.org, akpm@linux-foundation.org, linux-kernel@vger.kernel.org, linux-nvdimm@lists.01.org, pavel.tatashin@microsoft.com, dave.jiang@intel.com, dave.hansen@intel.com, jglisse@redhat.com, rppt@linux.vnet.ibm.com, dan.j.williams@intel.com, logang@deltatee.com, mingo@kernel.org, kirill.shutemov@linux.intel.com Subject: Re: [PATCH v5 4/4] mm: Defer ZONE_DEVICE page initialization to the point where we init pgmap Message-ID: <20180927122537.GA20378@techadventures.net> References: <20180925200551.3576.18755.stgit@localhost.localdomain> <20180925202053.3576.66039.stgit@localhost.localdomain> <20180926075540.GD6278@dhcp22.suse.cz> <6f87a5d7-05e2-00f4-8568-bb3521869cea@linux.intel.com> <20180927110926.GE6278@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180927110926.GE6278@dhcp22.suse.cz> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 27, 2018 at 01:09:26PM +0200, Michal Hocko wrote: > > So there were a few things I wasn't sure we could pull outside of the > > hotplug lock. One specific example is the bits related to resizing the pgdat > > and zone. I wanted to avoid pulling those bits outside of the hotplug lock. > > Why would that be a problem. There are dedicated locks for resizing. True is that move_pfn_range_to_zone() manages the locks for pgdat/zone resizing, but it also takes care of calling init_currently_empty_zone() in case the zone is empty. Could not that be a problem if we take move_pfn_range_to_zone() out of the lock? -- Oscar Salvador SUSE L3