What does "formally specified" mean?
As far as I know, you can count on 16-bytes alignment from
kmalloc. The trouble is that you would have to keep the original
pointer and free that if you have to do the "round" yourself.
I once wrote a kmalloc(*) that would allow you to free any pointer
inside the kmalloc-ed area. This is dangerous as freeing a random
pointer is more likely to "work". But in this case it would be very
convenient.
Roger.
(*) Too buggy for anyone but me.
-- ** R.E.Wolff@BitWizard.nl ** http://www.BitWizard.nl/ ** +31-15-2137555 ** *-- BitWizard writes Linux device drivers for any device you may have! --* * There are old pilots, and there are bold pilots. * There are also old, bald pilots. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/