linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Magnus Damm <magnus.damm@gmail.com>
To: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Magnus Damm <magnus@valinux.co.jp>,
	linux-mm@kvack.org, Magnus Damm <damm@opensource.se>
Subject: Re: [RFC] Removing page->flags
Date: Thu, 9 Feb 2006 12:38:43 +0900	[thread overview]
Message-ID: <aec7e5c30602081938w1d593309h5422abcef597f4bf@mail.gmail.com> (raw)
In-Reply-To: <43EAB395.6000603@jp.fujitsu.com>

On 2/9/06, KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
> Magnus Damm wrote:
> > Hi Kamezawa-san,
> >
> > On 2/9/06, KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
> >> Magnus Damm wrote:
> >>> [RFC] Removing page-flags
> >>>
> >>> Moving type A bits:
> >>>
> >>> Instead of keeping the bits together, we spread them out and store a
> >>> pointer to them from pg_data_t.
> >>>
> >> This will annoy people who has a job to look into crash-dump's vmcore..like me ;)
> >> so, I don't like this idea.
> >
> > Hehe, gotcha. =) I also wonder how well it would work with your zone patches.
> >
> My layout-free-zone patches are not affected by this if you use pgdat/section to
> preserve page-flags.

Ok, good.

> To be honest, I'd like to do this
> ==
> struct zone *page_zone(struct page *page)
> {
>         return page->zone;
> }
> ==
> But this increases size of memmap awfully ;( and I can't.
> Current zone-indexing in page-flags is well saving memory space, I think.

With my proposal (Removing type B bits), if you can guarantee that all
your zones have a start address and a size that is aligned to (1 <<
(PAGE_SHIFT * 2)), then the following code should be possible:

struct zone *page_zone(struct page *page)
{
  struct page *parent = virt_to_page(page);

  return (struct zone *)parent->mapping;
}

This assumes that the first entry in mem_map is aligned to PAGE_SIZE,
and that some code has setup parent->mapping to point to the correct
zone. =)

/ magnus

--
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:[~2006-02-09  3:38 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-02-08  6:46 Magnus Damm
2006-02-08 11:54 ` Nick Piggin
2006-02-09  2:35   ` Magnus Damm
2006-02-09  4:19     ` Nick Piggin
2006-02-09  5:19       ` Magnus Damm
2006-02-09  5:37         ` Nick Piggin
2006-02-11  5:30           ` Marcelo Tosatti
2006-02-10 15:03     ` Rik van Riel
2006-02-08 19:37 ` Dave Hansen
2006-02-09  2:50   ` Magnus Damm
2006-02-09 17:27     ` Dave Hansen
2006-02-09  1:55 ` KAMEZAWA Hiroyuki
2006-02-09  2:57   ` Magnus Damm
2006-02-09  3:14     ` KAMEZAWA Hiroyuki
2006-02-09  3:38       ` Magnus Damm [this message]
2006-02-09  3:51         ` KAMEZAWA Hiroyuki
2006-02-09  5:24           ` Magnus Damm

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=aec7e5c30602081938w1d593309h5422abcef597f4bf@mail.gmail.com \
    --to=magnus.damm@gmail.com \
    --cc=damm@opensource.se \
    --cc=kamezawa.hiroyu@jp.fujitsu.com \
    --cc=linux-mm@kvack.org \
    --cc=magnus@valinux.co.jp \
    /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