BUG_ON() Conversion in drivers/s390/char/tape_block.c

this changes if() BUG(); constructs to BUG_ON() which is
cleaner, contains unlikely() and can better optimized away.

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
This commit is contained in:
Eric Sesterhenn 2006-04-01 01:28:11 +02:00 коммит произвёл Adrian Bunk
Родитель e048a8a688
Коммит 3a8dc8930e
1 изменённых файлов: 4 добавлений и 9 удалений

Просмотреть файл

@ -198,9 +198,7 @@ tapeblock_request_fn(request_queue_t *queue)
device = (struct tape_device *) queue->queuedata; device = (struct tape_device *) queue->queuedata;
DBF_LH(6, "tapeblock_request_fn(device=%p)\n", device); DBF_LH(6, "tapeblock_request_fn(device=%p)\n", device);
if (device == NULL) BUG_ON(device == NULL);
BUG();
tapeblock_trigger_requeue(device); tapeblock_trigger_requeue(device);
} }
@ -307,8 +305,7 @@ tapeblock_revalidate_disk(struct gendisk *disk)
int rc; int rc;
device = (struct tape_device *) disk->private_data; device = (struct tape_device *) disk->private_data;
if (!device) BUG_ON(!device);
BUG();
if (!device->blk_data.medium_changed) if (!device->blk_data.medium_changed)
return 0; return 0;
@ -440,11 +437,9 @@ tapeblock_ioctl(
rc = 0; rc = 0;
disk = inode->i_bdev->bd_disk; disk = inode->i_bdev->bd_disk;
if (!disk) BUG_ON(!disk);
BUG();
device = disk->private_data; device = disk->private_data;
if (!device) BUG_ON(!device);
BUG();
minor = iminor(inode); minor = iminor(inode);
DBF_LH(6, "tapeblock_ioctl(0x%0x)\n", command); DBF_LH(6, "tapeblock_ioctl(0x%0x)\n", command);