From: Kazuya Mio <k-mio@sx.jp.nec.com>
To: Lukas Czerner <lczerner@redhat.com>
Cc: linux-ext4@vger.kernel.org, tytso@mit.edu
Subject: Re: [PATCH] ext4: invalidate gap cache when writing extents last block
Date: Wed, 25 May 2011 17:59:23 +0900 [thread overview]
Message-ID: <4DDCC4EB.5000007@sx.jp.nec.com> (raw)
In-Reply-To: <alpine.LFD.2.00.1105241037190.4028@dhcp-27-109.brq.redhat.com>
2011/05/24 17:57, Lukas Czerner wrote:
> Hi Kazuya,
>
> I am really sorry for late answer. I think you're partly right. my
> solution is not good, but I still think that your is not good as well. I
> need to look at this again and more closely, sorry.
>
> What do you think about this: ext4_ext_next_allocated_block() should
> return next allocated block, however instead it in some cases returns
> EXT_MAX_BLOCK, which points at the last logical block in a file, which
> however in some cases might be equal to the last not allocated block,
> not first allocated block in subsequent extent. And boom, we have (next
> == lblock).
I think so, too.
> So if we want to really return next allocated block (or more
> specifically, next block which we can not allocate), we should in those
> cases return EXT_MAX_BLOCK+1. And we should do this in
> ext4_ext_put_gap_in_cache() as well when there is no extent yet. Also
> note that as I said EXT_MAX_BLOCK means maximum logical block, however
> we use it as lenght in ext4_ext_put_gap_in_cache() which does not sound
> right either. It seems all a little bit messy :-/. I need to look at it
> and try it to see if it would work, but I think it does make sense.
>
> What do you think?
AFAIK, it's the best way to fix this problem. But I have no idea that doesn't
increase the size of struct ext4_ext_cache. I'm looking forward to seeing
the patch.
Regards,
Kazuya Mio
next prev parent reply other threads:[~2011-05-25 8:59 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-11 8:08 [PATCH] ext4: Fix max file size of extent format file Kazuya Mio
2011-05-13 6:34 ` Lukas Czerner
2011-05-13 6:36 ` [PATCH] ext4: invalidate gap cache when writing extents last block Lukas Czerner
2011-05-13 8:55 ` Kazuya Mio
2011-05-24 8:33 ` Kazuya Mio
2011-05-24 8:57 ` Lukas Czerner
2011-05-25 8:59 ` Kazuya Mio [this message]
2011-06-03 17:35 ` [PATCH] ext4: Fix max file size of extent format file Andreas Dilger
2011-06-03 18:08 ` Lukas Czerner
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=4DDCC4EB.5000007@sx.jp.nec.com \
--to=k-mio@sx.jp.nec.com \
--cc=lczerner@redhat.com \
--cc=linux-ext4@vger.kernel.org \
--cc=tytso@mit.edu \
/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