]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/scsi/aha1542.c
Merge tag 'pwm/for-4.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/thierry...
[karo-tx-linux.git] / drivers / scsi / aha1542.c
index 5b8b2937a3fea85e6d69f02526158c659a182584..7db448ec8bebe7a97c7edfbf1249d092c50d6e5b 100644 (file)
@@ -403,6 +403,9 @@ static int aha1542_queuecommand(struct Scsi_Host *sh, struct scsi_cmnd *cmd)
                cptr = kmalloc(sizeof(*cptr) * sg_count, GFP_KERNEL | GFP_DMA);
                if (!cptr)
                        return SCSI_MLQUEUE_HOST_BUSY;
+       } else {
+               sg_count = 0;
+               cptr = NULL;
        }
 
        /* Use the outgoing mailboxes in a round-robin fashion, because this