The introduction of vm object locking has caused witness to reveal
a long-standing mistake in the way a portion of a pipe's KVA is allocated. Specifically, kmem_alloc_pageable() is inappropriate for use in the "direct" case because it allows a preceding vm map entry and vm object to be extended to support the new KVA allocation. However, the direct case KVA allocation should not have a backing vm object. This is corrected by using kmem_alloc_nofault(). Submitted by: tegge (with the above explanation by me)
This commit is contained in:
parent
7a34a70b8d
commit
93b4c5b707
@ -732,7 +732,7 @@ pipe_build_write_buffer(wpipe, uio)
|
||||
* We need to allocate space for an extra page because the
|
||||
* address range might (will) span pages at times.
|
||||
*/
|
||||
wpipe->pipe_map.kva = kmem_alloc_pageable(kernel_map,
|
||||
wpipe->pipe_map.kva = kmem_alloc_nofault(kernel_map,
|
||||
wpipe->pipe_buffer.size + PAGE_SIZE);
|
||||
atomic_add_int(&amountpipekva,
|
||||
wpipe->pipe_buffer.size + PAGE_SIZE);
|
||||
|
Loading…
Reference in New Issue
Block a user