New upstream version 18.11-rc3
[deb_dpdk.git] / drivers / crypto / octeontx / otx_cryptodev_ops.c
index 23f9659..90d0c14 100644 (file)
@@ -216,7 +216,7 @@ otx_cpt_que_pair_setup(struct rte_cryptodev *dev,
        }
 
        ret = otx_cpt_get_resource(cptvf, 0, &instance);
-       if (ret != 0) {
+       if (ret != 0 || instance == NULL) {
                CPT_LOG_ERR("Error getting instance handle from device %s : "
                            "ret = %d", dev->data->name, ret);
                return ret;