Prev: [PATCH-RFC] cfq: Disable low_latency by default for 2.6.32
Next: [PATCH RFC v0 1/3] cgroup: implement eventfd-based generic API for notifications
From: Oleg Nesterov on 26 Nov 2009 12:00 On 11/26, Masami Hiramatsu wrote: > > $ grep -r DUMP_WRITE arch/*/include > arch/ia64/include/asm/elf.h: DUMP_WRITE(&phdr, sizeof(phdr)); \ > arch/ia64/include/asm/elf.h: DUMP_WRITE((void *) gate_phdrs[\ arch/um/sys-i386/asm/elf.h uses DUMP_WRITE() too. > Oops, certainly, that's a problem. > IMHO, we should not do like that, all parameter required by a macro should be > specified explicitly, since it reduces readability so much... > I think we'd better make those macros inline function, check it's return value > for error handling. Agreed, DUMP_WRITE() in its current form should die. Not only it has implicit parameter, it does "goto" from the macro body and it has multiple definitions withing the same file. But perhaps this needs a separate patch? It is not trivial to kill DUMP_WRITE(), you can fix this patch if you change DUMP_WRITE() to use cprm->file instead of file. Oleg. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo(a)vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ |