]> Pileus Git - ~andy/linux/commit
RDMA/cxgb4: Fix error handling in create_qp()
authorEmil Goode <emilgoode@gmail.com>
Sun, 19 Aug 2012 17:59:40 +0000 (17:59 +0000)
committerRoland Dreier <roland@purestorage.com>
Mon, 1 Oct 2012 03:32:14 +0000 (20:32 -0700)
commitc079c28714e4d1a0b7cad120f84217e0fcde09a6
tree12349a5ebbdfd7bbf847a76aa413aade7bfcbe5a
parent979570e02981d4a8fc20b3cc8fd651856c98ee9d
RDMA/cxgb4: Fix error handling in create_qp()

The variable ret is assigned return values in a couple of places, but
its value is never returned.  This patch makes use of the ret variable
so that the caller get correct error codes returned.

The following changes are also introduced:

- The alloc_oc_sq function can return -ENOSYS or -ENOMEM so we want to
  get the return value from it.

- Change the label names to improve readability.

Signed-off-by: Emil Goode <emilgoode@gmail.com>
Acked-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/infiniband/hw/cxgb4/qp.c