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=-1.0 required=3.0 tests=MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED 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 D750BC433E0 for ; Thu, 25 Jun 2020 11:54:26 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A4D2920781 for ; Thu, 25 Jun 2020 11:54:26 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A4D2920781 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 2F1766B002E; Thu, 25 Jun 2020 07:54:26 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 2AC076B002F; Thu, 25 Jun 2020 07:54:26 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1923C6B0030; Thu, 25 Jun 2020 07:54:26 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0201.hostedemail.com [216.40.44.201]) by kanga.kvack.org (Postfix) with ESMTP id F1D4F6B002E for ; Thu, 25 Jun 2020 07:54:25 -0400 (EDT) Received: from smtpin21.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 82C1F180AD817 for ; Thu, 25 Jun 2020 11:54:25 +0000 (UTC) X-FDA: 76967576490.21.nest08_6213f5a26e4c Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin21.hostedemail.com (Postfix) with ESMTP id 60411180442D0 for ; Thu, 25 Jun 2020 11:54:25 +0000 (UTC) X-HE-Tag: nest08_6213f5a26e4c X-Filterd-Recvd-Size: 3346 Received: from mail-wr1-f65.google.com (mail-wr1-f65.google.com [209.85.221.65]) by imf09.hostedemail.com (Postfix) with ESMTP for ; Thu, 25 Jun 2020 11:54:24 +0000 (UTC) Received: by mail-wr1-f65.google.com with SMTP id h15so5525280wrq.8 for ; Thu, 25 Jun 2020 04:54:24 -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; bh=KkyD/dCsP/NUyZaxekBryRpKElEY0AMZnqKJIyE/Nxc=; b=PsvW0nqyWxO1jEWYCGBLprm20Zx8/K5vWdxxHuzKGdzG07UMj1p+kagfNp5xroHHTW u/SOX3AwK6ntgOxbkme0Az9UbfVmnuiAn1UrQt9b9OpArEjrOcw23tcEee3fi+dXE8e2 nuOILRriQss6Cv2Z+S4Eivhka5/mHgZbQLeW/ZxPfhgpKu7arraEpJFl0ZtSNrhF3DnY FnnxEHVAE58bryq9a/IQXGiJhd5LEz7gza+MuhZb9ul/D6fNruaLle6seO1zoEWZpf6d KSCtJqXqC7wjoTUgO4E15HJN14pkdilSdlAlaDQhoW6oA1XUZdadqIhuqhO20n9RcKzV RPIA== X-Gm-Message-State: AOAM5316PxxVz7wBxSYKLMHh2zvt8riFpRnfgj24BuzhbscvqvdVmWAh P98orAlvFZTLCksFj2gLyHg= X-Google-Smtp-Source: ABdhPJyYLIWJ0qs3W4JrMU6uNxO0FsVfTw5Yn+cvRovv5F4hHCwbE+Gqtjc0S2QRJWZvDM7N0AXVnw== X-Received: by 2002:a05:6000:111:: with SMTP id o17mr11435758wrx.178.1593086063961; Thu, 25 Jun 2020 04:54:23 -0700 (PDT) Received: from localhost (ip-37-188-168-3.eurotel.cz. [37.188.168.3]) by smtp.gmail.com with ESMTPSA id u84sm8646313wme.42.2020.06.25.04.54.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Jun 2020 04:54:23 -0700 (PDT) Date: Thu, 25 Jun 2020 13:54:22 +0200 From: Michal Hocko To: js1304@gmail.com Cc: Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org, kernel-team@lge.com, Vlastimil Babka , Christoph Hellwig , Roman Gushchin , Mike Kravetz , Naoya Horiguchi , Joonsoo Kim Subject: Re: [PATCH v3 4/8] mm/hugetlb: make hugetlb migration callback CMA aware Message-ID: <20200625115422.GE1320@dhcp22.suse.cz> References: <1592892828-1934-1-git-send-email-iamjoonsoo.kim@lge.com> <1592892828-1934-5-git-send-email-iamjoonsoo.kim@lge.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1592892828-1934-5-git-send-email-iamjoonsoo.kim@lge.com> X-Rspamd-Queue-Id: 60411180442D0 X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam01 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 Tue 23-06-20 15:13:44, Joonsoo Kim wrote: > From: Joonsoo Kim > > new_non_cma_page() in gup.c which try to allocate migration target page > requires to allocate the new page that is not on the CMA area. > new_non_cma_page() implements it by removing __GFP_MOVABLE flag. This way > works well for THP page or normal page but not for hugetlb page. Could you explain why? I mean why cannot you simply remove __GFP_MOVABLE flag when calling alloc_huge_page_nodemask and check for it in dequeue path? Your current calling convention doesn't allow that but as I've said in the reply to previous patch this should be changed and then it would make this one easier as well unless I am missing something. -- Michal Hocko SUSE Labs