diff options
author | Roman Zippel <zippel@linux-m68k.org> | 2006-06-25 05:46:55 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-25 10:00:56 -0700 |
commit | a7b1a1a3089aaf1168e3b68a40e98532063d7811 (patch) | |
tree | 7d30cea5bbc3bdd1acddb2ac383922cc973dc499 /arch/m68k/mm/kmap.c | |
parent | 6bf9f755c3f30c81df17fce7d2f8dda11b9516a4 (diff) | |
download | linux-a7b1a1a3089aaf1168e3b68a40e98532063d7811.tar.gz linux-a7b1a1a3089aaf1168e3b68a40e98532063d7811.tar.bz2 linux-a7b1a1a3089aaf1168e3b68a40e98532063d7811.zip |
[PATCH] m68k: fix __iounmap for 030
Ignore empty pmd entry during iomap (these are the holes between the
mappings).
Signed-off-by: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/m68k/mm/kmap.c')
-rw-r--r-- | arch/m68k/mm/kmap.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/m68k/mm/kmap.c b/arch/m68k/mm/kmap.c index 85ad19a0ac79..43ffab048724 100644 --- a/arch/m68k/mm/kmap.c +++ b/arch/m68k/mm/kmap.c @@ -259,13 +259,15 @@ void __iounmap(void *addr, unsigned long size) if (CPU_IS_020_OR_030) { int pmd_off = (virtaddr/PTRTREESIZE) & 15; + int pmd_type = pmd_dir->pmd[pmd_off] & _DESCTYPE_MASK; - if ((pmd_dir->pmd[pmd_off] & _DESCTYPE_MASK) == _PAGE_PRESENT) { + if (pmd_type == _PAGE_PRESENT) { pmd_dir->pmd[pmd_off] = 0; virtaddr += PTRTREESIZE; size -= PTRTREESIZE; continue; - } + } else if (pmd_type == 0) + continue; } if (pmd_bad(*pmd_dir)) { |