[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170801233138epcms1p4e0d111bd6757201e7df26a281c9d7dd4@epcms1p4>
Date: Tue, 01 Aug 2017 23:31:38 +0000
From: Daeho Jeong <daeho.jeong@...sung.com>
To: Jan Kara <jack@...e.cz>, Daeho Jeong <daeho.jeong@...sung.com>
CC: "jack@...e.com" <jack@...e.com>, "tytso@....edu" <tytso@....edu>,
"linux-ext4@...r.kernel.org" <linux-ext4@...r.kernel.org>
Subject: Re: Re: [PATCH] ext4: release discard bio after sending discard
commands
> > We've changed the discard command handling into parallel manner.
> > But, in this change, I forgot decreasing the usage count of the bio
> > which was used to send discard request. I'm sorry about that.
> >
> > Signed-off-by: Daeho Jeong <daeho.jeong@...sung.com>
> > Fixes: a015434480dc ("ext4: send parallel discards on commit
> > completions")
> Why do you think this is needed? submit_bio_wait() consumes the reference
> that you've got from __blkdev_issue_discard()...
>
> Honza
Hi Jan,
I thought like you, but submit_bio_wait() doesn't consume the reference
of the bio and the bio cannot be released after the I/O has been completed.
The caller of submit_bio_wait() should invoke bio_put() in person.
You can see what we have to do after calling submit_bio_wait() in
fs/crypto/bio.c.
Actually, in our device, I can see that the slab memory grows gradually
because of the unreleased discard bios.
Powered by blists - more mailing lists