Messages in this thread | | | Date | Thu, 11 Dec 2008 15:37:14 -0800 | From | "H. Peter Anvin" <> | Subject | Re: [PATCH] Fix VMI crash on boot in 2.6.27, 2.6.28 kernels |
| |
Greg KH wrote: >> +#else >> +#define vmi_init() >> +#define vmi_activate() >> +#define vmi_bringup() >> +#endif > > static inline please, don't use #defines for function prototypes, it's > not nice. See Andrew's previous rants about this for details :)
And if it is not possible, technically, for whatever reason, the proper forms look like:
#define foo() ((void)0) #define bar(x) ((void)(x)) #define baz(x,y) ((void)((x),(y)))
... which preserve side effects, even if they don't guarantee type safety.
-hpa
| |