* [merged] hfsplus-add-missing-call-to-bio_put.patch removed from -mm tree
@ 2011-07-01 19:17 akpm
0 siblings, 0 replies; only message in thread
From: akpm @ 2011-07-01 19:17 UTC (permalink / raw)
To: seth.forshee, hch, stable, mm-commits
The patch titled
hfsplus: add missing call to bio_put()
has been removed from the -mm tree. Its filename was
hfsplus-add-missing-call-to-bio_put.patch
This patch was dropped because it was merged into mainline or a subsystem tree
The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/
------------------------------------------------------
Subject: hfsplus: add missing call to bio_put()
From: Seth Forshee <seth.forshee@canonical.com>
hfsplus leaks bio objects by failing to call bio_put() on the bios it
allocates. Add the missing call to fix the leak.
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: <stable@kernel.org> [2.6.38+]
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
fs/hfsplus/wrapper.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff -puN fs/hfsplus/wrapper.c~hfsplus-add-missing-call-to-bio_put fs/hfsplus/wrapper.c
--- a/fs/hfsplus/wrapper.c~hfsplus-add-missing-call-to-bio_put
+++ a/fs/hfsplus/wrapper.c
@@ -36,6 +36,7 @@ int hfsplus_submit_bio(struct block_devi
{
DECLARE_COMPLETION_ONSTACK(wait);
struct bio *bio;
+ int ret = 0;
bio = bio_alloc(GFP_NOIO, 1);
bio->bi_sector = sector;
@@ -54,8 +55,10 @@ int hfsplus_submit_bio(struct block_devi
wait_for_completion(&wait);
if (!bio_flagged(bio, BIO_UPTODATE))
- return -EIO;
- return 0;
+ ret = -EIO;
+
+ bio_put(bio);
+ return ret;
}
static int hfsplus_read_mdb(void *bufptr, struct hfsplus_wd *wd)
_
Patches currently in -mm which might be from seth.forshee@canonical.com are
linux-next.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-07-01 19:17 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-07-01 19:17 [merged] hfsplus-add-missing-call-to-bio_put.patch removed from -mm tree akpm
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).