From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751983Ab0K2TFC (ORCPT ); Mon, 29 Nov 2010 14:05:02 -0500 Received: from mx1.redhat.com ([209.132.183.28]:33117 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750998Ab0K2TE7 (ORCPT ); Mon, 29 Nov 2010 14:04:59 -0500 Date: Mon, 29 Nov 2010 20:03:13 +0100 From: Andrea Arcangeli To: Mel Gorman Cc: linux-mm@kvack.org, Linus Torvalds , Andrew Morton , linux-kernel@vger.kernel.org, Marcelo Tosatti , Adam Litke , Avi Kivity , Hugh Dickins , Rik van Riel , Dave Hansen , Benjamin Herrenschmidt , Ingo Molnar , Mike Travis , KAMEZAWA Hiroyuki , Christoph Lameter , Chris Wright , bpicco@redhat.com, KOSAKI Motohiro , Balbir Singh , "Michael S. Tsirkin" , Peter Zijlstra , Johannes Weiner , Daisuke Nishimura , Chris Mason , Borislav Petkov Subject: Re: [PATCH 28 of 66] _GFP_NO_KSWAPD Message-ID: <20101129190313.GA6118@random.random> References: <20101118131839.GR8135@csn.ul.ie> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20101118131839.GR8135@csn.ul.ie> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Nov 18, 2010 at 01:18:39PM +0000, Mel Gorman wrote: > This is not an exact merge with what's currently in mm. Look at the top > of gfp.h and see "Plain integer GFP bitmasks. Do not use this > directly.". The 0x400000u definition needs to go there and this becomes > > #define __GFP_NO_KSWAPD ((__force_gfp_t)____0x400000u) > > What you have just generates sparse warnings (I believe) so it's > harmless. Agreed. diff --git a/include/linux/gfp.h b/include/linux/gfp.h --- a/include/linux/gfp.h +++ b/include/linux/gfp.h @@ -34,6 +34,7 @@ struct vm_area_struct; #else #define ___GFP_NOTRACK 0 #endif +#define ___GFP_NO_KSWAPD 0x400000u /* * GFP bitmasks.. @@ -81,7 +82,7 @@ struct vm_area_struct; #define __GFP_RECLAIMABLE ((__force gfp_t)___GFP_RECLAIMABLE) /* Page is reclaimable */ #define __GFP_NOTRACK ((__force gfp_t)___GFP_NOTRACK) /* Don't track with kmemcheck */ -#define __GFP_NO_KSWAPD ((__force gfp_t)0x400000u) +#define __GFP_NO_KSWAPD ((__force gfp_t)___GFP_NO_KSWAPD) /* * This may seem redundant, but it's a way of annotating false positives vs. > Other than needing to define ____GFP_NO_KSWAPD 3 underscores. > Acked-by: Mel Gorman Added, thanks! Andrea From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail202.messagelabs.com (mail202.messagelabs.com [216.82.254.227]) by kanga.kvack.org (Postfix) with SMTP id 762076B0087 for ; Mon, 29 Nov 2010 14:04:06 -0500 (EST) Date: Mon, 29 Nov 2010 20:03:13 +0100 From: Andrea Arcangeli Subject: Re: [PATCH 28 of 66] _GFP_NO_KSWAPD Message-ID: <20101129190313.GA6118@random.random> References: <20101118131839.GR8135@csn.ul.ie> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20101118131839.GR8135@csn.ul.ie> Sender: owner-linux-mm@kvack.org To: Mel Gorman Cc: linux-mm@kvack.org, Linus Torvalds , Andrew Morton , linux-kernel@vger.kernel.org, Marcelo Tosatti , Adam Litke , Avi Kivity , Hugh Dickins , Rik van Riel , Dave Hansen , Benjamin Herrenschmidt , Ingo Molnar , Mike Travis , KAMEZAWA Hiroyuki , Christoph Lameter , Chris Wright , bpicco@redhat.com, KOSAKI Motohiro , Balbir Singh , "Michael S. Tsirkin" , Peter Zijlstra , Johannes Weiner , Daisuke Nishimura , Chris Mason , Borislav Petkov List-ID: On Thu, Nov 18, 2010 at 01:18:39PM +0000, Mel Gorman wrote: > This is not an exact merge with what's currently in mm. Look at the top > of gfp.h and see "Plain integer GFP bitmasks. Do not use this > directly.". The 0x400000u definition needs to go there and this becomes > > #define __GFP_NO_KSWAPD ((__force_gfp_t)____0x400000u) > > What you have just generates sparse warnings (I believe) so it's > harmless. Agreed. diff --git a/include/linux/gfp.h b/include/linux/gfp.h --- a/include/linux/gfp.h +++ b/include/linux/gfp.h @@ -34,6 +34,7 @@ struct vm_area_struct; #else #define ___GFP_NOTRACK 0 #endif +#define ___GFP_NO_KSWAPD 0x400000u /* * GFP bitmasks.. @@ -81,7 +82,7 @@ struct vm_area_struct; #define __GFP_RECLAIMABLE ((__force gfp_t)___GFP_RECLAIMABLE) /* Page is reclaimable */ #define __GFP_NOTRACK ((__force gfp_t)___GFP_NOTRACK) /* Don't track with kmemcheck */ -#define __GFP_NO_KSWAPD ((__force gfp_t)0x400000u) +#define __GFP_NO_KSWAPD ((__force gfp_t)___GFP_NO_KSWAPD) /* * This may seem redundant, but it's a way of annotating false positives vs. > Other than needing to define ____GFP_NO_KSWAPD 3 underscores. > Acked-by: Mel Gorman Added, thanks! Andrea -- 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/ . Fight unfair telecom policy in Canada: sign http://dissolvethecrtc.ca/ Don't email: email@kvack.org