* [tip:x86/mm] x86, iomap: Fix wrong page aligned size calculation in ioremapping code
[not found] <201007202219.o6KMJlES021058@imap1.linux-foundation.org>
@ 2010-07-21 0:41 ` tip-bot for Florian Zumbiehl
0 siblings, 0 replies; only message in thread
From: tip-bot for Florian Zumbiehl @ 2010-07-21 0:41 UTC (permalink / raw)
To: linux-tip-commits; +Cc: linux-kernel, florz, hpa, mingo, akpm, tglx, hpa
Commit-ID: 468c30f2bbdf1ba0fbf16667eade23a46eaa8f06
Gitweb: http://git.kernel.org/tip/468c30f2bbdf1ba0fbf16667eade23a46eaa8f06
Author: Florian Zumbiehl <florz@florz.de>
AuthorDate: Tue, 20 Jul 2010 15:19:47 -0700
Committer: H. Peter Anvin <hpa@linux.intel.com>
CommitDate: Tue, 20 Jul 2010 16:56:35 -0700
x86, iomap: Fix wrong page aligned size calculation in ioremapping code
x86 early_iounmap(): fix off-by-one error in page alignment of allocation
size for sizes where size%PAGE_SIZE==1.
Signed-off-by: Florian Zumbiehl <florz@florz.de>
LKML-Reference: <201007202219.o6KMJlES021058@imap1.linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
---
arch/x86/mm/ioremap.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/mm/ioremap.c b/arch/x86/mm/ioremap.c
index d41d3a9..3ba6e06 100644
--- a/arch/x86/mm/ioremap.c
+++ b/arch/x86/mm/ioremap.c
@@ -611,7 +611,7 @@ void __init early_iounmap(void __iomem *addr, unsigned long size)
return;
}
offset = virt_addr & ~PAGE_MASK;
- nrpages = PAGE_ALIGN(offset + size - 1) >> PAGE_SHIFT;
+ nrpages = PAGE_ALIGN(offset + size) >> PAGE_SHIFT;
idx = FIX_BTMAP_BEGIN - NR_FIX_BTMAPS*slot;
while (nrpages > 0) {
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2010-07-21 0:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <201007202219.o6KMJlES021058@imap1.linux-foundation.org>
2010-07-21 0:41 ` [tip:x86/mm] x86, iomap: Fix wrong page aligned size calculation in ioremapping code tip-bot for Florian Zumbiehl
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox