]> err.no Git - linux-2.6/blobdiff - drivers/scsi/scsi_lib.c
[PATCH] parport: add NetMOS 9805 support
[linux-2.6] / drivers / scsi / scsi_lib.c
index cab535809d0d6a0bdb9f85d0d8653a755d32f494..7a91ca3d32a6cb343a8a533368a5956afbea18d6 100644 (file)
@@ -621,7 +621,7 @@ static void scsi_free_sgtable(struct scatterlist *sgl, int index)
 {
        struct scsi_host_sg_pool *sgp;
 
-       BUG_ON(index > SG_MEMPOOL_NR);
+       BUG_ON(index >= SG_MEMPOOL_NR);
 
        sgp = scsi_sg_pools + index;
        mempool_free(sgl, sgp->pool);