lkml.org 
[lkml]   [2008]   [May]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] SLQB v2
On Thu, May 01, 2008 at 06:28:57PM -0700, Christoph Lameter wrote:
> On Fri, 2 May 2008, Nick Piggin wrote:
>
> > But overloading struct page values happens in other places too. Putting
> > everything into struct page is not scalable. We could also make kmalloc
>
> Well lets at least attempt to catch the biggest users.

You want to also put slab and slob in there? What about page allocator?
It is ridiculous for the sake of "being easy to inspect with debuggers".
How hard is (struct slub_page *) to type?

Here is a real benefit you get with clearly defined types for struct
page: type checking.


> Also makes code
> clearer if you f.e. use page->first_page instead of page->private for
> compound pages.

compound_page_head() is fine too.


> kmalloc is intended to return an arbitrary type. struct page has a defined
> format that needs to be respected.

So does kmalloc if you take the union of all types it might possibly
be used as.


\
 
 \ /
  Last update: 2008-05-02 03:51    [W:0.036 / U:1.520 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site