Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp3184082imm; Thu, 17 May 2018 04:55:34 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpft445pFhRhn5dume5nxh7aq7gioepj0aQrhOCWg3SKFInZP9nB5OOlf5WQ9pTJwKcZzqP X-Received: by 2002:a62:d044:: with SMTP id p65-v6mr4992893pfg.64.1526558134588; Thu, 17 May 2018 04:55:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526558134; cv=none; d=google.com; s=arc-20160816; b=IkFBtN0P2dE5Ly+vB6C2aw6wHhmivefoMvzD6MrWkCoz6+B+1cuAv1izeaObBYldsy LL9vpXil/w+PPPk6vwZ9k/2jW6GPdZLsDtin6W8Hzo6F6J9z+VQZfsgnyYMkud1ffu3k V5Q8LEJlva8Xxm9HRtOQhXf3Lj7afo70h5SdgAXLFrcEbVBeYWSkY986pmkKOQNky+GV hBf2KLeWTosfrEYO4nDIHkZ672GmficeQrqcgxxb9puDQGmeVCgmJgzHC5hJyW+8qmUf G3riORfs1r1uB7ZIVg4yni+6qCQiTHAzCtlMNPTUdXYvgy73X74J1ieix8LzkYTbXwWo g1uQ== 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:dkim-signature:arc-authentication-results; bh=izbkw2c2qWp6Q0FXGNqCTOgaSrH6lNOW7gJpCSuzRWU=; b=M7bRB/87UJeRjvPVaDW+W9m9xWP2QwrjngZRERg5Md/vel3rfhiOCH0Blh04ol+gbM 84NJpvqTg1IuWFCJI+mSH5HfbIJ3hpX8r3aCvznQteJY7h7BzVmWJymMsom1xD9oCovt RNeY55KmwKYKi2ZV8mBy8Bx2yOTVDxz8D5ph+mf+JPvihnrDoN0FHM/a/9D1jom/SY1w eOfR38Vzyr0kMFLeaX0Tkit4ZsPGt4GvlspglZPhYTq2vffNd3f+EU2TOTsFfA6i5ba3 H8WkOS85rRbvv9AbbxGvcFv0jN59bsPA7pOHAoZ0CnWD0Nj5NfnnbXwB1YmZp0ZaPYyp Q16Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=UVgeX84R; 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 q3-v6si3707429pgp.95.2018.05.17.04.55.19; Thu, 17 May 2018 04:55:34 -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; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=UVgeX84R; 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 S1752080AbeEQLxa (ORCPT + 99 others); Thu, 17 May 2018 07:53:30 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:53296 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750826AbeEQLx3 (ORCPT ); Thu, 17 May 2018 07:53:29 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=izbkw2c2qWp6Q0FXGNqCTOgaSrH6lNOW7gJpCSuzRWU=; b=UVgeX84RRABMM47GoOzNu/3VV be7MgAimIuiU+CLwISpKCEB/ycsOLOAWWN8m1GiL0XwRUMLGA7mxNIuUJXQpHucEO429fOjBabA++ Or7YaS72ZXXV4Ji2oQP+5vJh7yHK21NC1ZW/njjFi6srcRe3pT/3H6wHOAlcxiSwSRPDamN9+bxG9 3vp2jD5Avamich+Uaa7QMl43/B8DbkXrTbIA02DkIXojeKLKCPOWlUnBNUUCaZf86uo+T5E3e6I3W 8nA4P5kVcmuvwZa0Y6MaPixsA4IyG0l348NS2w54YgAvsPWsOAR7wA8eK7PS+zJEDLkjYqVXgzhwU h8xU2ofBg==; Received: from willy by bombadil.infradead.org with local (Exim 4.90_1 #2 (Red Hat Linux)) id 1fJHTM-0003Uv-73; Thu, 17 May 2018 11:53:28 +0000 Date: Thu, 17 May 2018 04:53:27 -0700 From: Matthew Wilcox To: Aaron Lu Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Andrew Morton , Huang Ying , Dave Hansen , Kemi Wang , Tim Chen , Andi Kleen , Michal Hocko , Vlastimil Babka , Mel Gorman , Daniel Jordan , Tariq Toukan Subject: Re: [RFC v3 PATCH 1/5] mm/page_alloc: use helper functions to add/remove a page to/from buddy Message-ID: <20180517115327.GB26689@bombadil.infradead.org> References: <20180509085450.3524-1-aaron.lu@intel.com> <20180509085450.3524-2-aaron.lu@intel.com> <20180517114821.GA26689@bombadil.infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180517114821.GA26689@bombadil.infradead.org> User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 17, 2018 at 04:48:21AM -0700, Matthew Wilcox wrote: > On Wed, May 09, 2018 at 04:54:46PM +0800, Aaron Lu wrote: > > +static inline void add_to_buddy_head(struct page *page, struct zone *zone, > > + unsigned int order, int mt) > > +{ > > + add_to_buddy_common(page, zone, order); > > + list_add(&page->lru, &zone->free_area[order].free_list[mt]); > > +} > > Isn't this function (and all of its friends) misnamed? We're not adding > this page to the buddy allocator, we're adding it to the freelist. It > doesn't go to the buddy allocator until later, if at all. No, never mind, I misunderstood. Ignore this please.