c4iw_uld_add() must return ERR_PTR() values instead of NULL on failure.
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
        devp = (struct c4iw_dev *)ib_alloc_device(sizeof(*devp));
        if (!devp) {
                printk(KERN_ERR MOD "Cannot allocate ib device\n");
-               return NULL;
+               return ERR_PTR(-ENOMEM);
        }
        devp->rdev.lldi = *infop;
 
                mutex_unlock(&dev_mutex);
                printk(KERN_ERR MOD "Unable to open CXIO rdev err %d\n", ret);
                ib_dealloc_device(&devp->ibdev);
-               return NULL;
+               return ERR_PTR(ret);
        }
 
        idr_init(&devp->cqidr);
                       DRV_VERSION);
 
        dev = c4iw_alloc(infop);
-       if (!dev)
+       if (IS_ERR(dev))
                goto out;
 
        PDBG("%s found device %s nchan %u nrxq %u ntxq %u nports %u\n",