Skip to content
Commit bfd2793c authored by Yann Droneaud's avatar Yann Droneaud Committed by David S. Miller
Browse files

RDMA/cxgb4: set error code on kmalloc() failure



If kmalloc() fails in c4iw_alloc_ucontext(), the function
leaves but does not set an error code in ret variable:
it will return 0 to the caller.

This patch set ret to -ENOMEM in such case.

Cc: Steve Wise <swise@opengridcomputing.com>
Cc: Steve Wise <swise@chelsio.com>
Signed-off-by: default avatarYann Droneaud <ydroneaud@opteya.com>
Acked-by: default avatarSteve Wise <swise@opengridcomputing.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent f3c9ec05
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment