Re: lib/idr.c: initialize struct idr_layer

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Pekka J Enberg <penberg@...>
Cc: Jim Houston <jim.houston@...>, Ingo Molnar <mingo@...>, Tejun Heo <htejun@...>, Linux Kernel Mailing List <linux-kernel@...>
Date: Sunday, January 27, 2008 - 5:30 pm

On Jan 27, 2008 10:21 PM, Pekka J Enberg <penberg@cs.helsinki.fi> wrote:

I think there's a pretty big chance I'm wrong (or misunderstanding
something) here, so I'll just ask:
setup_object() from mm/slub.c is what calls the ctor. Shouldn't this
be called from slab_alloc() as well? (I'm marking the data
"uninitialized" there before returning the object.) Otherwise you
might get back an object that is initialized with the previous owner's
data. Or is this intentional?

Thanks.

Vegard
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
lib/idr.c: initialize struct idr_layer, Vegard Nossum, (Sun Jan 27, 4:07 pm)
Re: lib/idr.c: initialize struct idr_layer, Pekka Enberg, (Sun Jan 27, 5:00 pm)
Re: lib/idr.c: initialize struct idr_layer, Vegard Nossum, (Sun Jan 27, 5:17 pm)
Re: lib/idr.c: initialize struct idr_layer, Pekka J Enberg, (Sun Jan 27, 5:21 pm)
Re: lib/idr.c: initialize struct idr_layer, Vegard Nossum, (Sun Jan 27, 5:30 pm)
Re: lib/idr.c: initialize struct idr_layer, Pekka Enberg, (Sun Jan 27, 5:35 pm)
Re: lib/idr.c: initialize struct idr_layer, Vegard Nossum, (Sun Jan 27, 5:56 pm)