summaryrefslogtreecommitdiffstats
path: root/drivers/mtd
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-03-26 09:41:18 -0800
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-26 09:41:18 -0800
commit9ae21d1bb376436285cd5346d3e4b3655d6dd1b9 (patch)
tree8f889770fae721da63bd378c1834a87e2eb1cfb5 /drivers/mtd
parentf9b4192923fa6e38331e88214b1fe5fc21583fcc (diff)
parente9415777b1cd0eaf4d1d3d61772f0e6d5c2551ad (diff)
downloadop-kernel-dev-9ae21d1bb376436285cd5346d3e4b3655d6dd1b9.zip
op-kernel-dev-9ae21d1bb376436285cd5346d3e4b3655d6dd1b9.tar.gz
Merge git://git.kernel.org/pub/scm/linux/kernel/git/bunk/trivial
* git://git.kernel.org/pub/scm/linux/kernel/git/bunk/trivial: drivers/char/ftape/lowlevel/fdc-io.c: Correct a comment Kconfig help: MTD_JEDECPROBE already supports Intel Remove ugly debugging stuff do_mounts.c: Minor ROOT_DEV comment cleanup BUG_ON() Conversion in drivers/s390/block/dasd_devmap.c BUG_ON() Conversion in mm/mempool.c BUG_ON() Conversion in mm/memory.c BUG_ON() Conversion in kernel/fork.c BUG_ON() Conversion in ipc/sem.c BUG_ON() Conversion in fs/ext2/ BUG_ON() Conversion in fs/hfs/ BUG_ON() Conversion in fs/dcache.c BUG_ON() Conversion in fs/buffer.c BUG_ON() Conversion in input/serio/hp_sdc_mlc.c BUG_ON() Conversion in md/dm-table.c BUG_ON() Conversion in md/dm-path-selector.c BUG_ON() Conversion in drivers/isdn BUG_ON() Conversion in drivers/char BUG_ON() Conversion in drivers/mtd/
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/chips/Kconfig5
-rw-r--r--drivers/mtd/maps/dilnetpc.c8
-rw-r--r--drivers/mtd/mtd_blkdevs.c3
-rw-r--r--drivers/mtd/mtdconcat.c6
4 files changed, 9 insertions, 13 deletions
diff --git a/drivers/mtd/chips/Kconfig b/drivers/mtd/chips/Kconfig
index 205bb70..0f6bb2e 100644
--- a/drivers/mtd/chips/Kconfig
+++ b/drivers/mtd/chips/Kconfig
@@ -25,9 +25,8 @@ config MTD_JEDECPROBE
compatible with the Common Flash Interface, but will use the common
CFI-targetted flash drivers for any chips which are identified which
are in fact compatible in all but the probe method. This actually
- covers most AMD/Fujitsu-compatible chips, and will shortly cover also
- non-CFI Intel chips (that code is in MTD CVS and should shortly be sent
- for inclusion in Linus' tree)
+ covers most AMD/Fujitsu-compatible chips and also non-CFI
+ Intel chips.
config MTD_GEN_PROBE
tristate
diff --git a/drivers/mtd/maps/dilnetpc.c b/drivers/mtd/maps/dilnetpc.c
index b51c757..efb2216 100644
--- a/drivers/mtd/maps/dilnetpc.c
+++ b/drivers/mtd/maps/dilnetpc.c
@@ -218,8 +218,8 @@ static void dnp_set_vpp(struct map_info *not_used, int on)
{
if(--vpp_counter == 0)
setcsc(CSC_RBWR, getcsc(CSC_RBWR) | 0x4);
- else if(vpp_counter < 0)
- BUG();
+ else
+ BUG_ON(vpp_counter < 0);
}
spin_unlock_irq(&dnpc_spin);
}
@@ -240,8 +240,8 @@ static void adnp_set_vpp(struct map_info *not_used, int on)
{
if(--vpp_counter == 0)
setcsc(CSC_RBWR, getcsc(CSC_RBWR) | 0x8);
- else if(vpp_counter < 0)
- BUG();
+ else
+ BUG_ON(vpp_counter < 0);
}
spin_unlock_irq(&dnpc_spin);
}
diff --git a/drivers/mtd/mtd_blkdevs.c b/drivers/mtd/mtd_blkdevs.c
index 7f3ff50..840dd66 100644
--- a/drivers/mtd/mtd_blkdevs.c
+++ b/drivers/mtd/mtd_blkdevs.c
@@ -450,8 +450,7 @@ int deregister_mtd_blktrans(struct mtd_blktrans_ops *tr)
kfree(tr->blkcore_priv);
- if (!list_empty(&tr->devs))
- BUG();
+ BUG_ON(!list_empty(&tr->devs));
return 0;
}
diff --git a/drivers/mtd/mtdconcat.c b/drivers/mtd/mtdconcat.c
index b1bf8c4..9af8403 100644
--- a/drivers/mtd/mtdconcat.c
+++ b/drivers/mtd/mtdconcat.c
@@ -477,8 +477,7 @@ static int concat_erase(struct mtd_info *mtd, struct erase_info *instr)
}
/* must never happen since size limit has been verified above */
- if (i >= concat->num_subdev)
- BUG();
+ BUG_ON(i >= concat->num_subdev);
/* now do the erase: */
err = 0;
@@ -500,8 +499,7 @@ static int concat_erase(struct mtd_info *mtd, struct erase_info *instr)
if ((err = concat_dev_erase(subdev, erase))) {
/* sanity check: should never happen since
* block alignment has been checked above */
- if (err == -EINVAL)
- BUG();
+ BUG_ON(err == -EINVAL);
if (erase->fail_addr != 0xffffffff)
instr->fail_addr = erase->fail_addr + offset;
break;
OpenPOWER on IntegriCloud