From: Theodore Tso <tytso@mit.edu>
To: Eric Sandeen <esandeen@redhat.com>
Cc: linux-ext4@vger.kernel.org
Subject: Comments on respun 16T patches: group_desc_loops
Date: Mon, 11 Sep 2006 22:30:55 -0400 [thread overview]
Message-ID: <20060912023055.GA31035@thunk.org> (raw)
In-Reply-To: <44F5D66D.8030500@redhat.com>
On Wed, Aug 30, 2006 at 01:18:21PM -0500, Eric Sandeen wrote:
> http://people.redhat.com/esandeen/ext3/e2fsprogs-1.39-16T/e2fsprogs-hg-20060830-16T-patches.tar.gz
In the group_desc_loops patches in the above tarball:
>For loops iterating over all group descriptors, consistently define
>first_block and last_block in a way that they are inclusive of the
>range, and do not overflow.
>
>Previously on the last block group we did a test of <= first + dec_blocks;
>this would actually wrap back to 0 for a total block count of 2^32-1
As far as I can tell this is not a problem. sb->s_last_block can be
at most 2**32-1 --- which means that the last valid block number is
actually 2**32-2, since block numbers are zero based.
So as long as the handling of the last block group is correct, I don't
think we actually need to make the <= to < change. It's not wrong to
make the change, just not necessary as far as I can see.
Also, there are some files for which the only change was variable
names. That's fine, but the changelogs should state that.
So there is a last block group handling bug in ext2fs_check_desc(),
but I didn't see any other bugs that this patch would actually affect.
Am I missing anything?
Regards,
- Ted
next prev parent reply other threads:[~2006-09-12 9:13 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <44E3855D.5040303@redhat.com>
[not found] ` <20060830061825.GB8046@thunk.org>
[not found] ` <44F5D66D.8030500@redhat.com>
2006-08-30 22:25 ` [Ext2-devel] [PATCH] 2/6 Detect overflows in loop counters Theodore Tso
2006-09-12 2:30 ` Theodore Tso [this message]
2006-09-12 19:28 ` Theodore Tso
2006-09-12 19:38 ` Eric Sandeen
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=20060912023055.GA31035@thunk.org \
--to=tytso@mit.edu \
--cc=esandeen@redhat.com \
--cc=linux-ext4@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.