mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-12-25 02:49:32 +03:00
Suppress AIO kmem warnings
The new zpl_aio_write() and zpl_aio_read() functions use kmem_alloc() to allocate enough memory to hold the vectorized IO. While this allocation will be small it's been observed in practice to sometimes slightly exceed the 8K warning threshold by a few kilobytes. Therefore, the KM_NODEBUG flag has been added to suppress warning. Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Richard Yao <ryao@gentoo.org> Closes #2774
This commit is contained in:
parent
d94fd5f0de
commit
ba232d8aea
@ -248,7 +248,7 @@ zpl_aio_read(struct kiocb *kiocb, const struct iovec *iovp,
|
||||
size_t count = kiocb->ki_nbytes;
|
||||
ssize_t read;
|
||||
size_t alloc_size = sizeof (struct iovec) * nr_segs;
|
||||
struct iovec *iov_tmp = kmem_alloc(alloc_size, KM_SLEEP);
|
||||
struct iovec *iov_tmp = kmem_alloc(alloc_size, KM_SLEEP | KM_NODEBUG);
|
||||
bcopy(iovp, iov_tmp, alloc_size);
|
||||
|
||||
ASSERT(iovp);
|
||||
@ -325,7 +325,7 @@ zpl_aio_write(struct kiocb *kiocb, const struct iovec *iovp,
|
||||
size_t count = kiocb->ki_nbytes;
|
||||
ssize_t wrote;
|
||||
size_t alloc_size = sizeof (struct iovec) * nr_segs;
|
||||
struct iovec *iov_tmp = kmem_alloc(alloc_size, KM_SLEEP);
|
||||
struct iovec *iov_tmp = kmem_alloc(alloc_size, KM_SLEEP | KM_NODEBUG);
|
||||
bcopy(iovp, iov_tmp, alloc_size);
|
||||
|
||||
ASSERT(iovp);
|
||||
|
Loading…
Reference in New Issue
Block a user