From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751832AbcGRIBN (ORCPT ); Mon, 18 Jul 2016 04:01:13 -0400 Received: from szxga01-in.huawei.com ([58.251.152.64]:23159 "EHLO szxga01-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751713AbcGRIBL (ORCPT ); Mon, 18 Jul 2016 04:01:11 -0400 Message-ID: <578C8C8A.8000007@huawei.com> Date: Mon, 18 Jul 2016 16:00:10 +0800 From: Xishi Qiu User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:12.0) Gecko/20120428 Thunderbird/12.0.1 MIME-Version: 1.0 To: Joonsoo Kim CC: David Rientjes , Andrew Morton , Vlastimil Babka , "Naoya Horiguchi" , Linux MM , LKML Subject: Re: [PATCH 1/2] mem-hotplug: use GFP_HIGHUSER_MOVABLE in, alloc_migrate_target() References: <57884EAA.9030603@huawei.com> <20160718055150.GF9460@js1304-P5Q-DELUXE> In-Reply-To: <20160718055150.GF9460@js1304-P5Q-DELUXE> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.177.25.179] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A090205.578C8C9A.0008,ss=1,re=0.000,recu=0.000,reip=0.000,cl=1,cld=1,fgs=0, ip=0.0.0.0, so=2013-06-18 04:22:30, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: e8f0f32f795eafedfa3e02c78ac068ad Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2016/7/18 13:51, Joonsoo Kim wrote: > On Fri, Jul 15, 2016 at 10:47:06AM +0800, Xishi Qiu wrote: >> alloc_migrate_target() is called from migrate_pages(), and the page >> is always from user space, so we can add __GFP_HIGHMEM directly. > > No, all migratable pages are not from user space. For example, > blockdev file cache has __GFP_MOVABLE and migratable but it has no > __GFP_HIGHMEM and __GFP_USER. > Hi Joonsoo, So the original code "gfp_t gfp_mask = GFP_USER | __GFP_MOVABLE;" is not correct? > And, zram's memory isn't GFP_HIGHUSER_MOVABLE but has __GFP_MOVABLE. > Can we distinguish __GFP_MOVABLE or GFP_HIGHUSER_MOVABLE when doing mem-hotplug? Thanks, Xishi Qiu > Thanks. > > > . >