Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp5702515imm; Mon, 23 Jul 2018 04:43:32 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcFoQMpxWUU4XciFH/O68UDO39qMNsyxrLX5UVBmzg5rJ1oCj2a7a7Vyx5s4+0Belw8oZOl X-Received: by 2002:a65:52cc:: with SMTP id z12-v6mr11981503pgp.69.1532346212269; Mon, 23 Jul 2018 04:43:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532346212; cv=none; d=google.com; s=arc-20160816; b=Qks39ypzOReDD8I0s8EKfMKasJMbE7LOnOnAmHipnbcpZI2Y42RUsp+inmWuJkgIth o4xNNerwjx4J7iOZl/XFs95ISpsTj3ig671+HIKpxiNv4XLEYunY82f8//+MDaTfElas dT98a4OaltK4lwoWtHwe5n+lNjHTijCwhRWVprnq3AnRNlZMBiwwXBdYdvz8zAuZrJDQ Z+KI87SIJ0p19o1M6Z/g0yKuvhEJ6y4gvGj6fsJzA1z+W/c8OHLbesY4pV179wfHX9ym +sgU5kt2x5EzxKz8cl5Z0G06hv5yeqIRsV2XC5CvTjruu0havgds4kvELQwRtOa08j+7 BfEg== 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:arc-authentication-results; bh=ia8dj8GP0dO3KcoBP71MGqZ7p7UT8Jn2L+gYB5Nml/w=; b=V632iY/1/J/QfHRxeIPNUYej+riN0CMeeIxkXP9DuVWebOVlRjE1prfRdoU66yboy8 BbTu4AkuSZ/+vO1DTvQ7NcFI9ecFWVFf17w/G2QMgwG0gZXYJ2X/L+d+F+OTXZD5D8sB B4xoT7r9NRxDeoQs/CzLgE87tsc2vxMR42sgS/hXPohfqbzSka5m4CFHfQ9uJ7kNyEA9 DMoM6klW2KnfWHfJXA4kFlpSVJVDjKi++HktJY6QedPZcF/5CLjSwmgHvVrA7/dL0bIa ylwuyWrX7nCIxjDGGRsB2Pnh7iV465Ygc3eFlj9YW8I6t5Hdcbb3ixGH2zy8whJxKlSb 3oig== 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 q145-v6si8873044pfq.315.2018.07.23.04.43.17; Mon, 23 Jul 2018 04:43:32 -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 S2388037AbeGWMnP (ORCPT + 99 others); Mon, 23 Jul 2018 08:43:15 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:53590 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387847AbeGWMnP (ORCPT ); Mon, 23 Jul 2018 08:43:15 -0400 Received: by mail-wm0-f67.google.com with SMTP id s9-v6so798773wmh.3 for ; Mon, 23 Jul 2018 04:42:26 -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=ia8dj8GP0dO3KcoBP71MGqZ7p7UT8Jn2L+gYB5Nml/w=; b=ngVfKCcDMIsxm9Y0MnUsAWrPTOnZQ3McDTO1h6Ouzabp+ZGFeif4r7yA4yGh1VExD/ 10xjlb0ygnaoUJJ1wyQqntPISuGwxUGETTuNc6K1PqcS4KK38lnZNVoecqkt1Feg/uT9 KND829GOSX3u21SjzsJcS9RzO3y4WXyxuob34Af7ZbUTYO6Dk5uugNkc2yeBTSntS9GL K04ChdNAKm7f1yy2Y2hR3R78L/773w0f1hfUWssr5aPiugXAA30UWBdWZQmksSmw+t5e lKlYD1szjzxSf74T2G3ah3Bp0FA5F/U10jQ7U8quXBM3k2EZY1Knlx7wlZp8YCdWs/8F tYLg== X-Gm-Message-State: AOUpUlGaeGmntQjz6JMjadZ3ZUK7nrl79pGv8wQuUjNo04KkgTk88wgZ +1r1+LUyXi3f3TosoJ2zdcw= X-Received: by 2002:a1c:93d2:: with SMTP id v201-v6mr7049146wmd.77.1532346146001; Mon, 23 Jul 2018 04:42:26 -0700 (PDT) Received: from techadventures.net (techadventures.net. [62.201.165.239]) by smtp.gmail.com with ESMTPSA id j131-v6sm9239040wmb.25.2018.07.23.04.42.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Jul 2018 04:42:25 -0700 (PDT) Received: by techadventures.net (Postfix, from userid 1000) id B1B0A124257; Mon, 23 Jul 2018 13:42:24 +0200 (CEST) Date: Mon, 23 Jul 2018 13:42:24 +0200 From: Oscar Salvador To: Michal Hocko Cc: akpm@linux-foundation.org, pasha.tatashin@oracle.com, vbabka@suse.cz, aaron.lu@intel.com, iamjoonsoo.kim@lge.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Oscar Salvador Subject: Re: [PATCH v2 3/5] mm/page_alloc: Optimize free_area_init_core Message-ID: <20180723114224.GA7104@techadventures.net> References: <20180719132740.32743-1-osalvador@techadventures.net> <20180719132740.32743-4-osalvador@techadventures.net> <20180719134417.GC7193@dhcp22.suse.cz> <20180719140327.GB10988@techadventures.net> <20180719151555.GH7193@dhcp22.suse.cz> <20180719205235.GA14010@techadventures.net> <20180720100327.GA19478@techadventures.net> <20180723083519.GG17905@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180723083519.GG17905@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 Mon, Jul 23, 2018 at 10:35:19AM +0200, Michal Hocko wrote: > No, I do not think this is much better. Why do we need to separate those > functions out? I think you are too focused on the current function > without a broader context. Think about it. We have two code paths. > Early initialization and the hotplug. The two are subtly different in > some aspects. Maybe reusing free_area_init_core is the wrong thing and > we should have a dedicated subset of this function. This would make the > code more clear probably. You wouldn't have to think which part of > free_area_init_core is special and what has to be done if this function > was to be used in a different context. See my point? Yes, I see your point now. I will think about it with a wider approach. Thanks -- Oscar Salvador SUSE L3