linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "yunfeng zhang" <zyf.zeroos@gmail.com>
To: "Pekka Enberg" <penberg@cs.helsinki.fi>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Improvement on memory subsystem
Date: Wed, 19 Jul 2006 11:21:53 +0800	[thread overview]
Message-ID: <4df04b840607182021hecef3b6v24c4794444a8e53c@mail.gmail.com> (raw)
In-Reply-To: <84144f020607180925s62e6a7abvbaf66c672849170b@mail.gmail.com>

2006/7/19, Pekka Enberg <penberg@cs.helsinki.fi>:
> On 7/18/06, yunfeng zhang <zyf.zeroos@gmail.com> wrote:
> > 3. All slabs are all off-slab type. Store slab instance in page structure.
>
> Not sure what you mean. We need much more than sizeof(struct page) for
> slab management. Hmm?
>

Current page struct is just like this
struct page {
	unsigned long flags;
	atomic_t _count;
	atomic_t _mapcount;
	union {
		struct {
			unsigned long private;
			struct address_space *mapping;
		};
#if NR_CPUS >= CONFIG_SPLIT_PTLOCK_CPUS
		spinlock_t ptl;
#endif
	};
	pgoff_t index;
	struct list_head lru;
#if defined(WANT_PAGE_VIRTUAL)
	void *virtual;
#endif /* WANT_PAGE_VIRTUAL */
};
Most fields in the page structure is used for user page, to a core
slab page, these aren't touched at all.
So I think we should define a union
struct page {
	unsigned long flags;
	struct slab {
		struct list_head list;
		unsigned long colouroff;
		void *s_mem;
		unsigned int inuse;
		kmem_bufctl_t free;
		unsigned short nodeid;
	};
};

  reply	other threads:[~2006-07-19  3:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-18 10:03 Improvement on memory subsystem yunfeng zhang
2006-07-18 12:18 ` Valdis.Kletnieks
2006-07-19  3:44   ` yunfeng zhang
2006-07-19  9:18   ` Ian Stirling
2006-07-19 14:56     ` Valdis.Kletnieks
2006-07-18 16:25 ` Pekka Enberg
2006-07-19  3:21   ` yunfeng zhang [this message]
2006-07-19  8:30     ` Pekka Enberg
2006-07-19 10:13       ` yunfeng zhang
2006-07-19 10:35         ` Pekka Enberg
2006-07-24  9:01 ` yunfeng zhang
2006-07-24 14:55   ` David Lang
2006-07-25  8:33     ` yunfeng zhang
2006-08-23 10:39 ` yunfeng zhang

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=4df04b840607182021hecef3b6v24c4794444a8e53c@mail.gmail.com \
    --to=zyf.zeroos@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=penberg@cs.helsinki.fi \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).