From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f197.google.com (mail-wr0-f197.google.com [209.85.128.197]) by kanga.kvack.org (Postfix) with ESMTP id 9FB19831E3 for ; Wed, 8 Mar 2017 08:05:40 -0500 (EST) Received: by mail-wr0-f197.google.com with SMTP id y90so10778207wrb.1 for ; Wed, 08 Mar 2017 05:05:40 -0800 (PST) Received: from mx2.suse.de (mx2.suse.de. [195.135.220.15]) by mx.google.com with ESMTPS id a66si4825526wmh.36.2017.03.08.05.05.38 for (version=TLS1 cipher=AES128-SHA bits=128/128); Wed, 08 Mar 2017 05:05:39 -0800 (PST) Date: Wed, 8 Mar 2017 14:05:36 +0100 From: Michal Hocko Subject: Re: [PATCH 1/2] mm: use is_migrate_highatomic() to simplify the code Message-ID: <20170308130535.GK11028@dhcp22.suse.cz> References: <58B94F15.6060606@huawei.com> <20170303131808.GH31499@dhcp22.suse.cz> <20170303150619.4011826c7e645c0725efd6ae@linux-foundation.org> <20170306133832.GE27953@dhcp22.suse.cz> <20170306124318.e88843a07c76584bee7689e2@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170306124318.e88843a07c76584bee7689e2@linux-foundation.org> Sender: owner-linux-mm@kvack.org List-ID: To: Andrew Morton Cc: Xishi Qiu , Vlastimil Babka , Mel Gorman , Minchan Kim , Joonsoo Kim , Yisheng Xie , Linux MM , LKML On Mon 06-03-17 12:43:18, Andrew Morton wrote: > On Mon, 6 Mar 2017 14:38:33 +0100 Michal Hocko wrote: > > > On Fri 03-03-17 15:06:19, Andrew Morton wrote: > > > On Fri, 3 Mar 2017 14:18:08 +0100 Michal Hocko wrote: > > > > > > > On Fri 03-03-17 19:10:13, Xishi Qiu wrote: > > > > > Introduce two helpers, is_migrate_highatomic() and is_migrate_highatomic_page(). > > > > > Simplify the code, no functional changes. > > > > > > > > static inline helpers would be nicer than macros > > > > > > Always. > > > > > > We made a big dependency mess in mmzone.h. internal.h works. > > > > Just too bad we have three different header files for > > is_migrate_isolate{_page} - include/linux/page-isolation.h > > is_migrate_cma{_page} - include/linux/mmzone.h > > is_migrate_highatomic{_page} - mm/internal.h > > > > I guess we want all of them in internal.h? > > I suppose so. arch/powerpc/mm/mmu_context_iommu.c is using > is_migrate_cma_page which would need some attention. Ble. I am really wondering whether these helpers actually make the end result really worth all the troubles and the mess. -- Michal Hocko SUSE Labs -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org