mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Alasdair G Kergon <agk@redhat.com>
To: Linus Torvalds <torvalds@linux-foundation.org>,
	Michael Leun <ml@newton.leun.net>
Cc: Alasdair G Kergon <agk@redhat.com>,
	LKML <linux-kernel@vger.kernel.org>,
	dm-devel@redhat.com, Mikulas Patocka <mpatocka@redhat.com>
Subject: Re: Bisected: Massive memory leak in dm-snapshot in 3.1 development introduced
Date: Sun, 23 Oct 2011 14:44:49 +0100	[thread overview]
Message-ID: <20111023134449.GA13703@agk-dp.fab.redhat.com> (raw)
In-Reply-To: <CA+55aFzfFpnEc+Eerdi9SfMw4o17ONfYCHksJkD1O6AS5U2DoQ@mail.gmail.com>

On Sun, Oct 23, 2011 at 12:52:06PM +0300, Linus Torvalds wrote:
> Mikulas, Alasdair? I see the mempool_free() for the "master job", what
> about everything else? Does the dm_kcopyd_prepare_callback() perhaps
> need to do a
> 
>     job->master_job = job;
> 
> or similar?

If you look at the other place that performs that mempool_alloc, it's indeed
present there.

Michael - can you test if this solves the problem?

Alasdair

--- a/drivers/md/dm-kcopyd.c
+++ b/drivers/md/dm-kcopyd.c
@@ -628,6 +628,7 @@ void *dm_kcopyd_prepare_callback(struct dm_kcopyd_client *kc,
 	job->kc = kc;
 	job->fn = fn;
 	job->context = context;
+	job->master_job = job;
 
 	atomic_inc(&kc->nr_jobs);
 

  reply	other threads:[~2011-10-23 13:45 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-23  9:21 Michael Leun
2011-10-23  9:52 ` Linus Torvalds
2011-10-23 13:44   ` Alasdair G Kergon [this message]
2011-10-23 14:30     ` Michael Leun
2011-10-23 20:19       ` [dm-devel] " Alasdair G Kergon
2011-10-25 17:45   ` [PATCH] check for mempool memory leaks Mikulas Patocka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20111023134449.GA13703@agk-dp.fab.redhat.com \
    --to=agk@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ml@newton.leun.net \
    --cc=mpatocka@redhat.com \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome