On Fri, Jul 19, 2013 at 01:57:28PM +0000, Christoph Lameter wrote: >On Fri, 19 Jul 2013, Chen Gang F T wrote: > >> Yes, "'max' can roughly mean the same thing", but they are still a >> little different. >> >> 'max' also means: "the caller tells callee: I have told you the >> maximize buffer length, so I need not check the buffer length to be >> sure of no memory overflow, you need be sure of it". >> >> 'size' means: "the caller tells callee: you should use the size which I >> give you, I am sure it is OK, do not care about whether it can cause >> memory overflow or not". > >Ok that makes sense. > >> The diff may like this: > >I am fine with such a patch. > >Ultimately I would like the tracking and debugging technology to be >abstracted from the slub allocator and made generally useful by putting it >into mm/slab_common.c. SLAB has similar things but does not have all the >features. Coincidence, I am doing this work recently and will post patches soon. ;-) Regards, Wanpeng Li > >-- >To unsubscribe, send a message with 'unsubscribe linux-mm' in >the body to majordomo@xxxxxxxxx. For more info on Linux MM, >see: http://www.linux-mm.org/ . >Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a> -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>