]> Git Repo - linux.git/commitdiff
IB/hfi1: Remove incorrect IS_ERR check
authorDennis Dalessandro <[email protected]>
Tue, 25 Oct 2016 20:12:46 +0000 (13:12 -0700)
committerDoug Ledford <[email protected]>
Tue, 15 Nov 2016 21:18:57 +0000 (16:18 -0500)
Remove IS_ERR check from caching code as the function being called does
not actually return error pointers.

Fixes: f19bd643dbde: "IB/hfi1: Prevent NULL pointer deferences in caching code"
Reported-by: Dan Carpenter <[email protected]>
Reviewed-by: Dean Luick <[email protected]>
Signed-off-by: Dennis Dalessandro <[email protected]>
Signed-off-by: Doug Ledford <[email protected]>
drivers/infiniband/hw/hfi1/user_sdma.c

index a761f804111eea026855bc3c2d033430f4e81807..77697d690f3eb12add14aed6a9fe19dafd498601 100644 (file)
@@ -1144,7 +1144,7 @@ static int pin_vector_pages(struct user_sdma_request *req,
        rb_node = hfi1_mmu_rb_extract(pq->handler,
                                      (unsigned long)iovec->iov.iov_base,
                                      iovec->iov.iov_len);
-       if (rb_node && !IS_ERR(rb_node))
+       if (rb_node)
                node = container_of(rb_node, struct sdma_mmu_node, rb);
        else
                rb_node = NULL;
This page took 0.050444 seconds and 4 git commands to generate.