All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Lameter <cl@linux.com>
To: Dave Hansen <dave@sr71.net>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	kirill.shutemov@linux.intel.com, Andi Kleen <ak@linux.intel.com>
Subject: Re: [PATCH] [RFC] mm: slab: separate slab_page from 'struct page'
Date: Tue, 10 Dec 2013 21:07:40 +0000	[thread overview]
Message-ID: <00000142de5634af-f92870a7-efe2-45cd-b50d-a6fbdf3b353c-000000@email.amazonses.com> (raw)
In-Reply-To: <20131210204641.3CB515AE@viggo.jf.intel.com>

On Tue, 10 Dec 2013, Dave Hansen wrote:

> At least for slab, this doesn't turn out to be too big of a deal:
> it's only 8 casts.  slub looks like it'll be a bit more work, but
> still manageable.

The single page struct definitions makes it easy to see how a certain
field is being used in various subsystems. If you add a field then you
can see other use cases in other subsystems. If you happen to call
them then you know that there is trouble afoot.

Also if you screw up the sizes then you screw up the page struct for
everything and its very evident that a problem exists.

How do you ensure that the sizes and the locations of the fields in
multiple page structs stay consistent?

As far as I can tell we are trying to put everything into one page struct
to keep track of the uses of various fields and to allow a reference for
newcomes to the kernel.


WARNING: multiple messages have this Message-ID (diff)
From: Christoph Lameter <cl@linux.com>
To: Dave Hansen <dave@sr71.net>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
	kirill.shutemov@linux.intel.com, Andi Kleen <ak@linux.intel.com>
Subject: Re: [PATCH] [RFC] mm: slab: separate slab_page from 'struct page'
Date: Tue, 10 Dec 2013 21:07:40 +0000	[thread overview]
Message-ID: <00000142de5634af-f92870a7-efe2-45cd-b50d-a6fbdf3b353c-000000@email.amazonses.com> (raw)
In-Reply-To: <20131210204641.3CB515AE@viggo.jf.intel.com>

On Tue, 10 Dec 2013, Dave Hansen wrote:

> At least for slab, this doesn't turn out to be too big of a deal:
> it's only 8 casts.  slub looks like it'll be a bit more work, but
> still manageable.

The single page struct definitions makes it easy to see how a certain
field is being used in various subsystems. If you add a field then you
can see other use cases in other subsystems. If you happen to call
them then you know that there is trouble afoot.

Also if you screw up the sizes then you screw up the page struct for
everything and its very evident that a problem exists.

How do you ensure that the sizes and the locations of the fields in
multiple page structs stay consistent?

As far as I can tell we are trying to put everything into one page struct
to keep track of the uses of various fields and to allow a reference for
newcomes to the kernel.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2013-12-10 21:24 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-10 20:46 [PATCH] [RFC] mm: slab: separate slab_page from 'struct page' Dave Hansen
2013-12-10 20:46 ` Dave Hansen
2013-12-10 21:07 ` Christoph Lameter [this message]
2013-12-10 21:07   ` Christoph Lameter
2013-12-10 21:44   ` Dave Hansen
2013-12-10 21:44     ` Dave Hansen
2013-12-10 22:00     ` Christoph Lameter
2013-12-10 22:00       ` Christoph Lameter
2013-12-10 22:21       ` Dave Hansen
2013-12-10 22:21         ` Dave Hansen
2013-12-12 17:37         ` Christoph Lameter
2013-12-12 17:37           ` Christoph Lameter
2013-12-12 19:28           ` Dave Hansen
2013-12-12 19:28             ` Dave Hansen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=00000142de5634af-f92870a7-efe2-45cd-b50d-a6fbdf3b353c-000000@email.amazonses.com \
    --to=cl@linux.com \
    --cc=ak@linux.intel.com \
    --cc=dave@sr71.net \
    --cc=kirill.shutemov@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.