Merge branch 'svn-trunk'

This commit is contained in:
Bart Van Assche
2017-05-24 20:59:12 -07:00
2 changed files with 7 additions and 2 deletions

View File

@@ -1695,7 +1695,7 @@ static int tx_padding(struct iscsi_cmnd *cmnd, int state)
TRACE_DBG("Sending %d padding bytes (cmd %p)", rest, cmnd);
iov.iov_base = (char *)(&padding) + (sizeof(uint32_t) - rest);
iov.iov_base = (char *)&padding;
iov.iov_len = rest;
res = kernel_sendmsg(cmnd->conn->sock, &msg, &iov, 1, rest);

View File

@@ -1649,7 +1649,12 @@ struct sgv_pool *sgv_pool_create_node(const char *name,
}
}
pool = kmem_cache_alloc_node(sgv_pool_cachep, GFP_KERNEL, nodeid);
/*
* __sgv_shrink() takes sgv_pools_mutex, so, to prevent deadlock with it
* if this allocation will try to reclaim memory, GFP_NOFS has to be used
* here.
*/
pool = kmem_cache_alloc_node(sgv_pool_cachep, GFP_KERNEL|GFP_NOFS, nodeid);
if (pool == NULL) {
PRINT_ERROR("Allocation of sgv_pool failed (size %zd)",
sizeof(*pool));