lkml.org 
[lkml]   [2008]   [Mar]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: 2.6.25-rc2-mm1: WARNING at arch/x86/mm/ioremap.c:129

* Arjan van de Ven <arjan@linux.intel.com> wrote:

> looks good to me; Ingo please apply (Note: if no legit users show up I
> want to just remove support for mapping ram altogether in 2.6.26 or
> so)

well upstream doesnt have the warning anymore, i queued up the patch
below into x86.git#testing.

Ingo

-------------------->
Subject: x86: warn about RAM pages in ioremap()
From: Ingo Molnar <mingo@elte.hu>
Date: Mon Mar 03 09:37:41 CET 2008
Signed-off-by: Ingo Molnar <mingo@elte.hu>
---
arch/x86/mm/ioremap.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
Index: linux-x86.q/arch/x86/mm/ioremap.c
===================================================================
--- linux-x86.q.orig/arch/x86/mm/ioremap.c
+++ linux-x86.q/arch/x86/mm/ioremap.c
@@ -149,9 +149,11 @@ static void __iomem *__ioremap(unsigned
for (pfn = phys_addr >> PAGE_SHIFT;
(pfn << PAGE_SHIFT) < last_addr; pfn++) {

- if (page_is_ram(pfn) && pfn_valid(pfn) &&
- !PageReserved(pfn_to_page(pfn)))
+ int is_ram = page_is_ram(pfn);
+
+ if (is_ram && pfn_valid(pfn) && !PageReserved(pfn_to_page(pfn)))
return NULL;
+ WARN_ON_ONCE(is_ram);
}

switch (mode) {

\
 
 \ /
  Last update: 2008-03-03 09:49    [W:0.466 / U:0.892 seconds]
©2003-2014 Jasper Spaans. Advertise on this site