Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2213064pxa; Fri, 7 Aug 2020 06:08:03 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzL8mf2/Wpaf4oKsj+jL+eWxsiPyIv5WRPjuTvzuz0660SPuWgqLMhY84OtT3gpdM2KA2i+ X-Received: by 2002:a17:906:f0cc:: with SMTP id dk12mr8866036ejb.97.1596805683645; Fri, 07 Aug 2020 06:08:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596805683; cv=none; d=google.com; s=arc-20160816; b=bK7o5KAAku6hGguSeoNt+ntJEiVX61j4zpHmAqFbX0qNWujZCAdh+5I0M/sQ9S6RKm 2xi0ljp/oA7OtkQUgtX92w50ABnCnx1HWeH9+W44nQLy64vUAEV3hmaM+kTHXr2RjgWa m0iJbo93st4NGGkdAuJx52AM2LaguvgOQdeYBgKaJ5+jEp6QFcctE/g1aP2MiU0W9iWm LdTAqhgURKpsDeu2sp+eUbWFqP2NJ8ToL+0+/krkGD0s2s/kWDFlB40etWqXeSGCKYWp unPkbeXILRb8XZaWmiDQh40D3zPpcUq9iPvb06ao2KhDClm2vAUVzNfsm3tAx9wXpUdo j95g== 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; bh=UdCLjT3neSFtq69r+TQXuFwARKBxtnsgatv/PZHQQ2Q=; b=wVxoQL/eLEseT78N6OrRf7iZ6pk5H2s2YrZ+tKOzifNG3Kq9cOUiIKQYpolmtQMnfE ZF7OYCa9wlxjVJgEYPRvI+Mh40OpY5lrpGzrGP3W95By5wfRhBNRNSKRLHx/AdDgXJ1M rgAnnVcaBwNXSEGS+ssaYIOHphOVt29d1QZxm/vPHgjoi0yrf+qGUrXzs8oaAH8MbZ2v nA+4VJQTf6nskzgGywYUuquQoBrD6T5G08dntgQVliAXMDsBRoC0EordHn5LeV782dBA 1Fxy51LYMjJJToerTcsMidPPL/5ikZoascen5Iy074YOMFgTj6bfiOihOfjsLhcdLSap Mr5w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=iUKMa9Ra; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ga10si5225784ejb.372.2020.08.07.06.07.40; Fri, 07 Aug 2020 06:08:03 -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=@redhat.com header.s=mimecast20190719 header.b=iUKMa9Ra; 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=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726030AbgHGNGI (ORCPT + 99 others); Fri, 7 Aug 2020 09:06:08 -0400 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:28505 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725872AbgHGNGI (ORCPT ); Fri, 7 Aug 2020 09:06:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1596805567; h=from:from:reply-to:subject:subject: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=UdCLjT3neSFtq69r+TQXuFwARKBxtnsgatv/PZHQQ2Q=; b=iUKMa9RaGvGIBRyqS/sjyVjfXRhbzOyczViecokupS+LGYyXCJPt9aIAFvPUPZCRrOMfA4 TvH74Q2pv2VdIcyLJHEEIlcmwGFjPDGMUwBLBkX94jFNPnzq2qcElO60J2QG6DRoW6EqF8 MZ81teQ1ewLhInkoO8JpBXIJnbXDm6E= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-222-NTFWSP8nOaKLSGY3vnFADA-1; Fri, 07 Aug 2020 09:06:05 -0400 X-MC-Unique: NTFWSP8nOaKLSGY3vnFADA-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 0873F102C848; Fri, 7 Aug 2020 13:06:04 +0000 (UTC) Received: from localhost (ovpn-12-31.pek2.redhat.com [10.72.12.31]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 67FE170596; Fri, 7 Aug 2020 13:06:03 +0000 (UTC) Date: Fri, 7 Aug 2020 21:06:00 +0800 From: Baoquan He To: Wei Yang Cc: mike.kravetz@oracle.com, akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 07/10] mm/hugetlb: a page from buddy is not on any list Message-ID: <20200807130600.GR14854@MiWiFi-R3L-srv> References: <20200807091251.12129-1-richard.weiyang@linux.alibaba.com> <20200807091251.12129-8-richard.weiyang@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200807091251.12129-8-richard.weiyang@linux.alibaba.com> User-Agent: Mutt/1.10.1 (2018-07-13) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 08/07/20 at 05:12pm, Wei Yang wrote: > The page allocated from buddy is not on any list, so just use list_add() > is enough. > > Signed-off-by: Wei Yang > --- > mm/hugetlb.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/mm/hugetlb.c b/mm/hugetlb.c > index fb09e5a83c39..b8e844911b5a 100644 > --- a/mm/hugetlb.c > +++ b/mm/hugetlb.c > @@ -2430,7 +2430,7 @@ struct page *alloc_huge_page(struct vm_area_struct *vma, > h->resv_huge_pages--; > } > spin_lock(&hugetlb_lock); > - list_move(&page->lru, &h->hugepage_activelist); > + list_add(&page->lru, &h->hugepage_activelist); Looks good to me. Reviewed-by: Baoquan He > /* Fall through */ > } > hugetlb_cgroup_commit_charge(idx, pages_per_huge_page(h), h_cg, page); > -- > 2.20.1 (Apple Git-117) > >