[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <511A8922.6050908@zytor.com>
Date: Tue, 12 Feb 2013 10:25:38 -0800
From: "H. Peter Anvin" <hpa@...or.com>
To: "H.J. Lu" <hjl.tools@...il.com>
CC: Linus Torvalds <torvalds@...ux-foundation.org>,
Ingo Molnar <mingo@...nel.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Jamie Lokier <jamie@...reable.org>,
ville.syrjala@...ux.intel.com, Borislav Petkov <bp@...en8.de>,
Russell King - ARM Linux <linux@....linux.org.uk>,
Thomas Gleixner <tglx@...utronix.de>,
linux-tip-commits@...r.kernel.org
Subject: Re: [tip:x86/mm] x86, mm: Use a bitfield to mask nuisance get_user()
warnings
I just thought up this variant, I'm about to test it, but H.J., do you
see any problems with it?
#define itype(x) \
__typeof__(__builtin_choose_expr(sizeof(*(x)) > sizeof(0UL), 0ULL, 0UL))
I tried it out with a small test program (attached), and it seems to
work. Next for using it in the kernel...
-hpa
View attachment "testgcc.c" of type "text/x-csrc" (635 bytes)
Powered by blists - more mailing lists