1
linux/fs/ext2
Julia Lawall 2c11619a59 fs/ext2: use BUG_ON
if (...) BUG(); should be replaced with BUG_ON(...) when the test has no
side-effects to allow a definition of BUG_ON that drops the code completely.

The semantic patch that makes this change is as follows:
(http://www.emn.fr/x-info/coccinelle/)

// <smpl>
@ disable unlikely @ expression E,f; @@

(
  if (<... f(...) ...>) { BUG(); }
|
- if (unlikely(E)) { BUG(); }
+ BUG_ON(E);
)

@@ expression E,f; @@

(
  if (<... f(...) ...>) { BUG(); }
|
- if (E) { BUG(); }
+ BUG_ON(E);
)
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-04-28 08:58:43 -07:00
..
acl.c Introduce is_owner_or_cap() to wrap CAP_FOWNER use with fsuid check 2007-07-17 12:00:03 -07:00
acl.h
balloc.c fs/ext2: use BUG_ON 2008-04-28 08:58:43 -07:00
dir.c fs/ext2: use BUG_ON 2008-04-28 08:58:43 -07:00
ext2.h ext2: remove unused ext2_put_inode prototype 2008-02-08 09:22:33 -08:00
file.c BKL-removal: convert ext2 over to use unlocked_ioctl 2008-02-06 10:41:20 -08:00
fsync.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
ialloc.c ext2: le*_add_cpu conversion 2008-04-28 08:58:43 -07:00
inode.c ext2: use ext2_fsblk_t type 2008-04-28 08:58:43 -07:00
ioctl.c [PATCH] r/o bind mounts: elevate write count for ioctls() 2008-04-19 00:29:24 -04:00
Makefile
namei.c iget: stop EXT2 from using iget() and read_inode() 2008-02-07 08:42:27 -08:00
super.c ext2: use ext2_group_first_block_no() 2008-04-28 08:58:43 -07:00
symlink.c [PATCH] mark struct inode_operations const 1 2007-02-12 09:48:46 -08:00
xattr_security.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
xattr_trusted.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
xattr_user.c
xattr.c ext2: use ext2_group_first_block_no() 2008-04-28 08:58:43 -07:00
xattr.h
xip.c xip: support non-struct page backed memory 2008-04-28 08:58:23 -07:00
xip.h xip: support non-struct page backed memory 2008-04-28 08:58:23 -07:00