IB/mlx5: Allow creation of QPs with zero-length work queues
authorEli Cohen <eli@dev.mellanox.co.il>
Tue, 14 Jan 2014 15:45:21 +0000 (17:45 +0200)
committerRoland Dreier <roland@purestorage.com>
Thu, 23 Jan 2014 07:23:53 +0000 (23:23 -0800)
commit9e9c47d07d447e09a66ee528c3ebad9ba359af6a
treeb3bd156928143fe3260c58c550854d1cb716d656
parent05bdb2ab6b09f2306f0afe0f60f4b9abffa7aba4
IB/mlx5: Allow creation of QPs with zero-length work queues

The current code attmepts to call ib_umem_get() even if the length is
zero, which causes a failure. Since the spec allows zero length work
queues, change the code so we don't call ib_umem_get() in those cases.

Signed-off-by: Eli Cohen <eli@mellanox.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/infiniband/hw/mlx5/qp.c