Re: [PATCH] [RFC] mm: slab: separate slab_page from 'struct page'

From: Dave Hansen
Date: Thu Dec 12 2013 - 14:29:40 EST


On 12/12/2013 09:37 AM, Christoph Lameter wrote:
> On Tue, 10 Dec 2013, Dave Hansen wrote:
>> See? *EVERYTHING* is overridden by at least one of the sl?b allocators
>> except ->flags. In other words, there *ARE* no relationships when it
>> comes to the sl?bs, except for page->flags.
>
> Slab objects can be used for I/O and then the page fields become
> important.

OK, which fields? How are they important? Looking at 'struct page', I
don't see any fields other than ->flags that the slab allocators leave
alone.

I do see some refcounting (page->_count) done on
request_queue->dma_drain_buffer which is kmalloc()'d. Although, I'm a
bit skeptical that this is correct or has been audited because the slabs
do seem to write over this storage. Anything needing to do per-page
could probably be converted over to a raw alloc_pages() anyway because
it couldn't possibly be doing sub-page-size allocations.

What other cases were you thinking of?
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/