phys-addr + size = 0
(0xffffd000) (0x3000)
The patch is:
+++ linux-2.1.78c/arch/i386/mm/ioremap.c Tue Jan 20 20:41:53 1998
--- orig/linux-2.1.78/arch/i386/mm/ioremap.c Fri Apr 4 16:52:17 1997
@@ -95,7 +95,7 @@
if (phys_addr & ~PAGE_MASK)
return NULL;
size = PAGE_ALIGN(size);
- if (!size || size > phys_addr + size)
+ if (!size || (size != ~phys_addr+1 && size > phys_addr + size))
return NULL;
area = get_vm_area(size);
if (!area)
I'm sure there's better ways of writing the extra bit in the condition, but it
works.
All the best,
David Howells