]> git.baikalelectronics.ru Git - kernel.git/commit
IB/hfi1: Return actual error value from program_rcvarray()
authorMichael J. Ruhl <michael.j.ruhl@intel.com>
Wed, 2 May 2018 13:42:29 +0000 (06:42 -0700)
committerDoug Ledford <dledford@redhat.com>
Wed, 9 May 2018 19:53:29 +0000 (15:53 -0400)
commita2af87211bb7d69d02582ec9cf1811d27ec0cb22
tree39da2e0cd3d4284a22fb1895a11ba8f967040d92
parent1c2c5e3dffb3235b89f80c260bf29954205b4d56
IB/hfi1: Return actual error value from program_rcvarray()

A failure of program_rcvarray() is treated inconsistently by the
calling function.  In one case the error is returned, in a second
case, the error is overwritten with EFAULT.  In both cases the
code path is doing the same thing, allocating memory for groups,
so it should be consistent.

Make the error path consistent and return the error generated by
program_rcvarray().

Reviewed-by: Harish Chegondi <harish.chegondi@intel.com>
Fixes: 032fa89ceb9c ("staging/hfi1: Add TID entry program function body")
Signed-off-by: Michael J. Ruhl <michael.j.ruhl@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/hfi1/user_exp_rcv.c