> > On Tue, Apr 12, 2011 at 10:12 AM, KOSAKI Motohiro > > <kosaki.motohiro@xxxxxxxxxxxxxx> wrote: > > > After next year? All developers don't have to ignore compiler warnings! > > > > At least add vm_flags_t which is sparse-checked, just like we do with gfp_t. > > Good idea. Alexy, I have to deeply thank you. Your suggestion help to find two hidden vm_flags usage. (I'll post them as reply of this mail) Now, i386 allyesconfig build doesn't detect nocast violation. Then, I believe we don't have a big overlooking anymore. >From 254787536ac871d313a02db5dfe8c539e0bbf605 Mon Sep 17 00:00:00 2001 From: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx> Date: Wed, 13 Apr 2011 09:26:37 +0900 Subject: [PATCH 1/3] mm: add __nocast attribute to vm_flags Now, We are converting vm_flags to 64bit. so nocast attribute help to find hidden wrong vm_flags usage. Suggested-by: Alexey Dobriyan <adobriyan@xxxxxxxxx> Signed-off-by: KOSAKI Motohiro <kosaki.motohiro@xxxxxxxxxxxxxx> --- include/linux/mm_types.h | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h index 4b0b990..ca01ab2 100644 --- a/include/linux/mm_types.h +++ b/include/linux/mm_types.h @@ -109,7 +109,7 @@ struct page { */ struct vm_region { struct rb_node vm_rb; /* link in global region tree */ - unsigned long long vm_flags; /* VMA vm_flags */ + unsigned long long __nocast vm_flags; /* VMA vm_flags */ unsigned long vm_start; /* start address of region */ unsigned long vm_end; /* region initialised to here */ unsigned long vm_top; /* region allocated to here */ @@ -137,7 +137,7 @@ struct vm_area_struct { struct vm_area_struct *vm_next, *vm_prev; pgprot_t vm_page_prot; /* Access permissions of this VMA. */ - unsigned long long vm_flags; /* Flags, see mm.h. */ + unsigned long long __nocast vm_flags; /* Flags, see mm.h. */ struct rb_node vm_rb; -- 1.7.3.1 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxxx For more info on Linux MM, see: http://www.linux-mm.org/ . Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/ Don't email: <a href