[PATCH] if (foo) brelse(foo) in /drivers cleanup

Zwane Mwaikambo (zwane@linux.realnet.co.sz)
Sat, 1 Dec 2001 13:31:29 +0200 (SAST)


Patch to remove the extra check before calling brelse in /drivers

-Zwane Mwaikambo

diffed against 2.5.1-pre4

diff -urN linux-2.5.1-pre4.orig/drivers/ide/pdcraid.c linux-2.5.1-pre4.brelse/drivers/ide/pdcraid.c
--- linux-2.5.1-pre4.orig/drivers/ide/pdcraid.c Tue Nov 13 19:19:41 2001
+++ linux-2.5.1-pre4.brelse/drivers/ide/pdcraid.c Sat Dec 1 07:47:23 2001
@@ -445,8 +445,7 @@
}
ret = 0;
abort:
- if (bh)
- brelse (bh);
+ brelse (bh);
return ret;
}

diff -urN linux-2.5.1-pre4.orig/drivers/md/md.c linux-2.5.1-pre4.brelse/drivers/md/md.c
--- linux-2.5.1-pre4.orig/drivers/md/md.c Thu Oct 25 22:58:34 2001
+++ linux-2.5.1-pre4.brelse/drivers/md/md.c Sat Dec 1 07:46:39 2001
@@ -501,8 +501,7 @@
printk(KERN_INFO " [events: %08lx]\n", (unsigned long)rdev->sb->events_lo);
ret = 0;
abort:
- if (bh)
- brelse (bh);
+ brelse (bh);
return ret;
}

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/