linux/arch/um/kernel
Jason Lunz af84eab208 [PATCH] uml: fix LVM crash
Permit lvm to create logical volumes without crashing UML.

When device-mapper's DM_DEV_CREATE_CMD ioctl is called to create a new device,
dev_create()->dm_create()->alloc_dev()-> blk_queue_bounce_limit(md->queue,
BLK_BOUNCE_ANY) is called.

blk_queue_bounce_limit(BLK_BOUNCE_ANY) calls init_emergency_isa_pool() if
blk_max_pfn < blk_max_low_pfn.  This is the case on UML, but
init_emergency_isa_pool() hits BUG_ON(!isa_page_pool) because there doesn't
seem to be a dma zone on UML for mempool_create() to allocate from.

Most architectures seem to have max_low_pfn == max_pfn, but UML doesn't
because of the uml_reserved chunk it keeps for itself.  From what I can see,
max_pfn and max_low_pfn don't get much use after the bootmem-allocator stops
being used anyway, except that they initialize the block layer's
blk_max_low_pfn/blk_max_pfn.

This ensures init_emergency_isa_pool() doesn't crash uml in this situation by
setting max_low_pfn == max_pfn in mem_init().

Signed-off-by: Jason Lunz <lunz@falooley.org>
Signed-off-by: Jeff Dike <jdike@linux.intel.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Alasdair G Kergon <agk@redhat.com>
Cc: Jens Axboe <jens.axboe@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-03-29 08:22:24 -07:00
..
skas [PATCH] uml: remove code controlled by non-existent config option 2007-02-11 10:51:23 -08:00
tt [PATCH] uml: mconsole locking 2007-02-11 10:51:21 -08:00
Makefile [PATCH] uml: delete unused file 2007-02-11 10:51:22 -08:00
asm-offsets.c [PATCH] uml: fix missing KBUILD_BASENAME 2006-01-11 18:42:09 -08:00
config.c.in Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
dyn.lds.S [PATCH] uml: add _text definition to linker scripts 2006-10-31 08:07:00 -08:00
exec.c [PATCH] uml: Kill a compilation warning 2007-02-11 10:51:22 -08:00
exitcode.c [PATCH] uml: locking documentation 2006-09-29 09:18:04 -07:00
gmon_syms.c [PATCH] uml: fix gcov support 2006-09-27 08:26:16 -07:00
gprof_syms.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
init_task.c Remove all inclusions of <linux/config.h> 2006-10-04 03:38:54 -04:00
initrd.c [PATCH] uml: initrd cleanup 2005-05-20 15:48:18 -07:00
irq.c [PATCH] uml: activate_fd: return ENOMEM only when appropriate 2007-03-08 07:38:21 -08:00
ksyms.c Remove all inclusions of <linux/config.h> 2006-10-04 03:38:54 -04:00
mem.c [PATCH] uml: fix LVM crash 2007-03-29 08:22:24 -07:00
physmem.c [PATCH] uml: mem.c and physmem.c formatting fixes 2007-02-11 10:51:22 -08:00
process.c [PATCH] uml: split memory allocation prototypes out of user.h 2006-10-20 10:26:36 -07:00
ptrace.c [PATCH] uml: x86_64 ptrace fixes 2007-02-11 10:51:24 -08:00
reboot.c [PATCH] uml: Use ARRAY_SIZE more assiduously 2006-09-26 08:49:05 -07:00
sigio.c [PATCH] uml: SIGIO formatting fixes 2007-02-11 10:51:23 -08:00
signal.c [PATCH] uml: fix formatting violations in signal delivery code 2007-03-06 09:30:26 -08:00
smp.c Remove all inclusions of <linux/config.h> 2006-10-04 03:38:54 -04:00
syscall.c [PATCH] uml: remove unused variable and function 2007-02-11 10:51:22 -08:00
sysrq.c [PATCH] uml: const a variable 2007-02-11 10:51:22 -08:00
time.c [PATCH] uml: make time data per-cpu 2007-02-11 10:51:22 -08:00
tlb.c [PATCH] uml: Whitespace fixes 2006-09-26 08:49:06 -07:00
trap.c [PATCH] uml: make signal handlers static 2007-02-11 10:51:22 -08:00
uaccess.c [PATCH] uml: separate libc-dependent uaccess code 2005-11-07 07:53:31 -08:00
um_arch.c [PATCH] Dynamic kernel command-line: fixups 2007-02-12 09:48:39 -08:00
umid.c [PATCH] uml: umid tidying 2007-02-11 10:51:24 -08:00
uml.lds.S [PATCH] uml: add _text definition to linker scripts 2006-10-31 08:07:00 -08:00
vmlinux.lds.S [PATCH] uml: tidy biarch gcc support 2006-07-14 21:53:52 -07:00