From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932351Ab2INAIY (ORCPT ); Thu, 13 Sep 2012 20:08:24 -0400 Received: from LGEMRELSE1Q.lge.com ([156.147.1.111]:48364 "EHLO LGEMRELSE1Q.lge.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751333Ab2INAIW (ORCPT ); Thu, 13 Sep 2012 20:08:22 -0400 X-AuditID: 9c93016f-b7c19ae000000e6d-c6-50527574d347 Date: Fri, 14 Sep 2012 09:10:32 +0900 From: Minchan Kim To: Andrew Morton Cc: Geert Uytterhoeven , linux-kernel@vger.kernel.org, linux-mm@kvack.org, Kyungmin Park , Marek Szyprowski , Michal Nazarewicz , Rik van Riel , Mel Gorman , Linux-Next Subject: Re: [PATCH] mm: cma: Discard clean pages during contiguous allocation instead of migration Message-ID: <20120914001032.GD5085@bbox> References: <1347324112-14134-1-git-send-email-minchan@kernel.org> <20120913151922.b8893088.akpm@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20120913151922.b8893088.akpm@linux-foundation.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-Brightmail-Tracker: AAAAAA== Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 13, 2012 at 03:19:22PM -0700, Andrew Morton wrote: > On Thu, 13 Sep 2012 21:17:19 +0200 > Geert Uytterhoeven wrote: > > > On Tue, Sep 11, 2012 at 2:41 AM, Minchan Kim wrote: > > > --- a/mm/vmscan.c > > > +++ b/mm/vmscan.c > > > @@ -674,8 +674,10 @@ static enum page_references page_check_references(struct page *page, > > > static unsigned long shrink_page_list(struct list_head *page_list, > > > struct zone *zone, > > > struct scan_control *sc, > > > + enum ttu_flags ttu_flags, > > > > "enum ttu_flags" is defined on CONFIG_MMU=y only, causing on nommu: > > > > mm/vmscan.c:677:26: error: parameter 4 ('ttu_flags') has incomplete type > > mm/vmscan.c:987:5: error: 'TTU_UNMAP' undeclared (first use in this function) > > mm/vmscan.c:987:15: error: 'TTU_IGNORE_ACCESS' undeclared (first use > > in this function) > > mm/vmscan.c:1312:56: error: 'TTU_UNMAP' undeclared (first use in this function) > > > > E.g. > > http://kisskb.ellerman.id.au/kisskb/buildresult/7191694/ (h8300-defconfig) > > http://kisskb.ellerman.id.au/kisskb/buildresult/7191858/ (sh-allnoconfig) > > hm, OK, the means by which current mainline avoids build errors is > either clever or lucky. > > switch (try_to_unmap(page, TTU_UNMAP)) { > > gets preprocessed into > > switch (2) { > > so the cmopiler never gets to see the TTU_ symbol at all. Because it > happens to be inside the try_to_unmap() call. > > > I guess we can just make ttu_flags visible to NOMMU: I agree. Geert, Andrew Thanks for the reporting and quick fix! -- Kind regards, Minchan Kim