aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/block')
-rw-r--r--drivers/block/DAC960.c3
-rw-r--r--drivers/block/cciss.c3
-rw-r--r--drivers/block/cciss_scsi.c2
-rw-r--r--drivers/block/cpqarray.c3
4 files changed, 4 insertions, 7 deletions
diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c
index 37b8cda3e8bc..9bdea2a5cf0e 100644
--- a/drivers/block/DAC960.c
+++ b/drivers/block/DAC960.c
@@ -228,8 +228,7 @@ static void *slice_dma_loaf(struct dma_loaf *loaf, size_t len,
228 void *cpu_end = loaf->cpu_free + len; 228 void *cpu_end = loaf->cpu_free + len;
229 void *cpu_addr = loaf->cpu_free; 229 void *cpu_addr = loaf->cpu_free;
230 230
231 if (cpu_end > loaf->cpu_base + loaf->length) 231 BUG_ON(cpu_end > loaf->cpu_base + loaf->length);
232 BUG();
233 *dma_handle = loaf->dma_free; 232 *dma_handle = loaf->dma_free;
234 loaf->cpu_free = cpu_end; 233 loaf->cpu_free = cpu_end;
235 loaf->dma_free += len; 234 loaf->dma_free += len;
diff --git a/drivers/block/cciss.c b/drivers/block/cciss.c
index 1f2890989b56..71ec9e664383 100644
--- a/drivers/block/cciss.c
+++ b/drivers/block/cciss.c
@@ -2361,8 +2361,7 @@ queue:
2361 if (!creq) 2361 if (!creq)
2362 goto startio; 2362 goto startio;
2363 2363
2364 if (creq->nr_phys_segments > MAXSGENTRIES) 2364 BUG_ON(creq->nr_phys_segments > MAXSGENTRIES);
2365 BUG();
2366 2365
2367 if (( c = cmd_alloc(h, 1)) == NULL) 2366 if (( c = cmd_alloc(h, 1)) == NULL)
2368 goto full; 2367 goto full;
diff --git a/drivers/block/cciss_scsi.c b/drivers/block/cciss_scsi.c
index 9e35de05d5c5..0e66e904bd8c 100644
--- a/drivers/block/cciss_scsi.c
+++ b/drivers/block/cciss_scsi.c
@@ -1316,7 +1316,7 @@ cciss_scsi_queue_command (struct scsi_cmnd *cmd, void (* done)(struct scsi_cmnd
1316 1316
1317 cp->Request.Timeout = 0; 1317 cp->Request.Timeout = 0;
1318 memset(cp->Request.CDB, 0, sizeof(cp->Request.CDB)); 1318 memset(cp->Request.CDB, 0, sizeof(cp->Request.CDB));
1319 if (cmd->cmd_len > sizeof(cp->Request.CDB)) BUG(); 1319 BUG_ON(cmd->cmd_len > sizeof(cp->Request.CDB));
1320 cp->Request.CDBLen = cmd->cmd_len; 1320 cp->Request.CDBLen = cmd->cmd_len;
1321 memcpy(cp->Request.CDB, cmd->cmnd, cmd->cmd_len); 1321 memcpy(cp->Request.CDB, cmd->cmnd, cmd->cmd_len);
1322 cp->Request.Type.Type = TYPE_CMD; 1322 cp->Request.Type.Type = TYPE_CMD;
diff --git a/drivers/block/cpqarray.c b/drivers/block/cpqarray.c
index 862b9abac0ae..b6ea2f0c7276 100644
--- a/drivers/block/cpqarray.c
+++ b/drivers/block/cpqarray.c
@@ -906,8 +906,7 @@ queue_next:
906 if (!creq) 906 if (!creq)
907 goto startio; 907 goto startio;
908 908
909 if (creq->nr_phys_segments > SG_MAX) 909 BUG_ON(creq->nr_phys_segments > SG_MAX);
910 BUG();
911 910
912 if ((c = cmd_alloc(h,1)) == NULL) 911 if ((c = cmd_alloc(h,1)) == NULL)
913 goto startio; 912 goto startio;