On Thu, Feb 13, 2014 at 09:10:52PM +0800, WANG Chao wrote: [..] > diff --git a/kexec/kexec.h b/kexec/kexec.h > index 2bd6e96..753acc5 100644 > --- a/kexec/kexec.h > +++ b/kexec/kexec.h > @@ -121,6 +121,16 @@ do { \ > fprintf(stderr, __VA_ARGS__); \ > } while(0) > > +#define dbgprint_mem_range(prefix, mr, nr_mr) \ > +do { \ > + int i; \ > + dbgprintf(prefix "\n"); \ > + for (i = 0; i < nr_mr; i++) { \ > + dbgprintf("%016llx-%016llx (%d)\n", (mr)[i].start, \ > + (mr)[i].end, (mr)[i].type); \ > + } \ > +} while (0) > + Can we make it a function instead of macro? Vivek