IB/mlx5: Fix error code in get_port_caps()
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 12 Jan 2015 08:56:58 +0000 (11:56 +0300)
committerRoland Dreier <roland@purestorage.com>
Tue, 17 Feb 2015 18:22:59 +0000 (10:22 -0800)
commitf614fc15ae39ceb531586e3969f2b99fd23182a0
treee16ee8b0bca811affd161434c0d3b19d34064f70
parentbfa76d49576599a4b9f9b7a71f23d73d6dcff735
IB/mlx5: Fix error code in get_port_caps()

The current code returns success when kmalloc() fails.  It should
return an error code, -ENOMEM.

Fixes: e126ba97dba9 ("mlx5: Add driver for Mellanox Connect-IB adapters")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/infiniband/hw/mlx5/main.c