scsi: qedf: Fix NULL dereference in error handling
[linux-2.6-microblaze.git] / drivers / scsi / qedf / qedf_main.c
index 3b64de8..2a31ddc 100644 (file)
@@ -3041,9 +3041,8 @@ static int qedf_alloc_global_queues(struct qedf_ctx *qedf)
         * addresses of our queues
         */
        if (!qedf->p_cpuq) {
-               status = -EINVAL;
                QEDF_ERR(&qedf->dbg_ctx, "p_cpuq is NULL.\n");
-               goto mem_alloc_failure;
+               return -EINVAL;
        }
 
        qedf->global_queues = kzalloc((sizeof(struct global_queue *)