linux-mips
[Top] [All Lists]

Re: [PATCH] MIPS: fix pfn_valid() for FLAGMEM

To: Wu Zhangjin <wuzhangjin@gmail.com>
Subject: Re: [PATCH] MIPS: fix pfn_valid() for FLAGMEM
From: Ralf Baechle <ralf@linux-mips.org>
Date: Thu, 8 Oct 2009 20:50:12 +0200
Cc: linux-mips@linux-mips.org, "Rafael J. Wysocki" <rjw@sisk.pl>, Pavel Machek <pavel@ucw.cz>
In-reply-to: <1255016760.14496.57.camel@falcon>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <1254992252-15923-1-git-send-email-wuzhangjin@gmail.com> <20091008144230.GA682@linux-mips.org> <1255016760.14496.57.camel@falcon>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.5.19 (2009-01-05)
On Thu, Oct 08, 2009 at 11:46:00PM +0800, Wu Zhangjin wrote:

> > Are the non-memory parts marked as reserved?
> > 
> No, so, is that a need to mark them?

Initially all pages are marked as reserved.

Which seems to be good enough for x86:

$ cat /proc/iomem
00000000-0009efff : System RAM
0009f000-0009ffff : reserved
000c0000-000cffff : pnp 00:0d
000e0000-000fffff : pnp 00:0d
00100000-7fe5b7ff : System RAM
[...]

The 0x9f000 - 0x9ffff range is the good old ISA I/O memory range (classic
MDA/CGA/VGA etc.), that is non-memory yet:

#ifdef CONFIG_FLATMEM
#define pfn_valid(pfn)          ((pfn) < max_mapnr)
#endif /* CONFIG_FLATMEM */

is sufficient on x86 so I think something else must be wrong.

  Ralf

<Prev in Thread] Current Thread [Next in Thread>