Re: [kernel-hardening] Re: [PATCH 9/9] mm: SLUB hardened usercopy support
From: Christoph Lameter
Date: Fri Jul 08 2016 - 09:46:10 EST
On Fri, 8 Jul 2016, Michael Ellerman wrote:
> > I wonder if this code should be using size_from_object() instead of s->size?
>
> Hmm, not sure. Who's SLUB maintainer? :)
Me.
s->size is the size of the whole object including debugging info etc.
ksize() gives you the actual usable size of an object.