[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20091206192841.GA23088@frolo.macqel>
Date: Sun, 6 Dec 2009 20:28:41 +0100
From: Philippe De Muyter <phdm@...qel.be>
To: linux-kernel@...r.kernel.org, linux-m68k@...r.kernel.org
Subject: [PATCH m68k resent] allow ioremapping top of memory
Hi Geert and all,
The test in __ioremap to reject memory ranges crossing the 0 boundary
rejects also memory ranges ending at the end of the memory. Fix that.
Signed-off-by: Philippe De Muyter <phdm@...qel.be>
diff --git a/arch/m68k/mm/kmap.c b/arch/m68k/mm/kmap.c
--- a/arch/m68k/mm/kmap.c
+++ b/arch/m68k/mm/kmap.c
@@ -116,7 +115,7 @@ void __iomem *__ioremap(unsigned long ph
/*
* Don't allow mappings that wrap..
*/
- if (!size || size > physaddr + size)
+ if (!size || physaddr > (unsigned long)(-size))
return NULL;
#ifdef CONFIG_AMIGA
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists