From: Russell King <rmk@arm.linux.org.uk>
To: Andrew Morton <akpm@zip.com.au>
Cc: Linus Torvalds <torvalds@transmeta.com>,
lkml <linux-kernel@vger.kernel.org>
Subject: Re: [patch 1/13] minimal rmap
Date: Wed, 17 Jul 2002 09:24:46 +0100 [thread overview]
Message-ID: <20020717092446.A4329@flint.arm.linux.org.uk> (raw)
In-Reply-To: <3D3500AA.131CE2EB@zip.com.au>; from akpm@zip.com.au on Tue, Jul 16, 2002 at 10:29:14PM -0700
On Tue, Jul 16, 2002 at 10:29:14PM -0700, Andrew Morton wrote:
I'm puzzling over this difference:
> --- /dev/null Thu Aug 30 13:30:55 2001
> +++ 2.5.26-akpm/include/asm-arm/proc-armv/rmap.h Tue Jul 16 21:59:40 2002
>...
> +static inline void pgtable_add_rmap(pte_t * ptep, struct mm_struct * mm, unsigned long address)
> +{
> + struct page * page = virt_to_page(ptep);
> +
> + page->mm = mm;
> + page->index = address & ~((PTRS_PER_PTE * PAGE_SIZE) - 1);
> +}
and
> --- /dev/null Thu Aug 30 13:30:55 2001
> +++ 2.5.26-akpm/include/asm-generic/rmap.h Tue Jul 16 21:59:40 2002
> +static inline void pgtable_add_rmap(struct page * page, struct mm_struct * mm, unsigned long address)
> +{
> +#ifdef BROKEN_PPC_PTE_ALLOC_ONE
> + /* OK, so PPC calls pte_alloc() before mem_map[] is setup ... ;( */
> + extern int mem_init_done;
> +
> + if (!mem_init_done)
> + return;
> +#endif
> + page->mapping = (void *)mm;
> + page->index = address & ~((PTRS_PER_PTE * PAGE_SIZE) - 1);
> +}
Note that the ARM one seems to be using page->mm but everything else
uses page->mapping.
Also, this comment:
> + * ARM is different since hardware page tables are smaller than
> + * the page size and Linux uses a "duplicate" one with extra info.
> + * For rmap this means that the first 2 kB of a page are the hardware
> + * page tables and the last 2 kB are the software page tables.
is no longer true for 2.5 (although it is still true for 2.4.)
--
Russell King (rmk@arm.linux.org.uk) The developer of ARM Linux
http://www.arm.linux.org.uk/personal/aboutme.html
next prev parent reply other threads:[~2002-07-17 8:21 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-07-17 5:29 [patch 1/13] minimal rmap Andrew Morton
2002-07-17 8:24 ` Russell King [this message]
2002-07-17 12:10 ` Rik van Riel
2002-07-17 12:21 ` Rik van Riel
2002-07-17 17:57 ` Daniel Phillips
2002-07-17 18:11 ` Robert Love
2002-07-17 18:26 ` Daniel Phillips
2002-07-17 20:37 ` Rik van Riel
2002-07-17 20:42 ` Robert Love
2002-07-17 20:46 ` Daniel Phillips
2002-07-17 20:48 ` Robert Love
2002-07-17 19:31 ` Rik van Riel
2002-07-17 19:38 ` Daniel Phillips
2002-07-17 19:41 ` Rik van Riel
2002-07-17 19:55 ` Daniel Phillips
2002-07-17 20:04 ` Rik van Riel
2002-07-17 20:13 ` Daniel Phillips
2002-07-17 20:25 ` Rik van Riel
2002-07-17 20:25 ` Rik van Riel
2002-07-17 20:36 ` Daniel Phillips
2002-07-17 20:39 ` Rik van Riel
2002-07-17 20:50 ` Dave Jones
2002-07-17 20:53 ` Robert Love
2002-07-22 2:40 ` Andrew Morton
2002-07-17 19:42 ` Robert Love
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=20020717092446.A4329@flint.arm.linux.org.uk \
--to=rmk@arm.linux.org.uk \
--cc=akpm@zip.com.au \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
/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