Re: [RFC] [PATCH] cpuset operations causes Badness at mm/slab.c:777 warning

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Linus Torvalds
Date: Friday, June 1, 2007 - 4:36 pm

On Fri, 1 Jun 2007, Christoph Lameter wrote:

No, I don't think you can do it this way.

At a minimum, you'd need to test that the result is word-aligned. 
Preferably 8-byte aligned. We literally have stuff that knows about these 
things and uses the low bits in the pointer to keep extra data.

(That said, I didn't check whether we actually kmalloc() the data, but I 
think we do - things like "struct key" etc).

Now, maybe those things always have a 8-byte-aligned size, and it works 
out, but I'd be worried.

Of course, there migth be other (even more subtle) cases where we just 
assume certain alignment, and depend on the fact that we just _happen_ to 
get it. Who knows..

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

Messages in current thread:
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Christoph Lameter, (Fri Jun 1, 11:13 am)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Christoph Lameter, (Fri Jun 1, 12:18 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Christoph Lameter, (Fri Jun 1, 12:51 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Jeremy Fitzhardinge, (Fri Jun 1, 1:30 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Jeremy Fitzhardinge, (Fri Jun 1, 1:56 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Linus Torvalds, (Fri Jun 1, 4:36 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Jeremy Fitzhardinge, (Fri Jun 1, 5:41 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Jeremy Fitzhardinge, (Fri Jun 1, 5:43 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Jeremy Fitzhardinge, (Fri Jun 1, 5:46 pm)
Re: [RFC] [PATCH] cpuset operations causes Badness at mm/s ..., Jeremy Fitzhardinge, (Fri Jun 1, 5:59 pm)