From: Marcin Slusarz <marcin.slusarz@gmail.com>
To: Jan Kara <jack@suse.cz>
Cc: LKML <linux-kernel@vger.kernel.org>,
Ben Fennema <bfennema@falcon.csc.calpoly.edu>,
Christoph Hellwig <hch@infradead.org>
Subject: Re: [PATCH 4/7] udf: replace loops coded with goto to real loops
Date: Tue, 8 Jan 2008 19:29:54 +0100 [thread overview]
Message-ID: <20080108182945.GA8106@joi> (raw)
In-Reply-To: <20080108101732.GB17794@duck.suse.cz>
On Tue, Jan 08, 2008 at 11:17:32AM +0100, Jan Kara wrote:
> On Mon 07-01-08 22:10:01, Marcin Slusarz wrote:
> > On Mon, Jan 07, 2008 at 03:48:21PM +0100, Jan Kara wrote:
> > > On Sun 06-01-08 02:21:50, marcin.slusarz@gmail.com wrote:
> > > > Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
> > > I'm not sure if this improves readability in general. If the code is
> > > really a loop in nature, then we should code it using do {} while but in
> > > case we loop back just in case of some error (as seems to be the case in
> > > udf_bitmap_new_block()), then IMHO goto is more explanative. So at least
> > > that one case I'd leave as is.
> > Why do you think it's an error?
> There is code:
>
> if (!udf_clear_bit(bit, bh->b_data)) {
> udf_debug("bit already cleared for block %d\n", bit);
> goto repeat;
> }
> Now if this happens, it's a bug AFAICS because we have been searching for
> a free block and we hold s_alloc_mutex and hence we should not race with
> any other allocation.
Fine, I'll drop this part of patch.
Marcin
next prev parent reply other threads:[~2008-01-08 18:29 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-06 1:21 [PATCH 0/7] udf: more cleanups marcin.slusarz
2008-01-06 1:21 ` [PATCH 2/7] udf: create common function for tag checksumming marcin.slusarz
2008-01-07 12:29 ` Christoph Hellwig
2008-01-06 1:21 ` [PATCH 3/7] udf: create common function for changing free space counter marcin.slusarz
2008-01-07 12:41 ` Christoph Hellwig
2008-01-06 1:21 ` [PATCH 4/7] udf: replace loops coded with goto to real loops marcin.slusarz
2008-01-07 14:48 ` Jan Kara
2008-01-07 21:10 ` Marcin Slusarz
2008-01-08 10:17 ` Jan Kara
2008-01-08 18:29 ` Marcin Slusarz [this message]
2008-01-06 1:21 ` [PATCH 5/7] udf: convert byte order of constant instead of variable marcin.slusarz
2008-01-07 14:52 ` Jan Kara
2008-01-06 1:21 ` [PATCH 6/7] udf: remove UDF_I_* macros and open code them marcin.slusarz
2008-01-07 14:53 ` Jan Kara
2008-01-06 1:21 ` [PATCH 7/7] udf: cache struct udf_inode_info marcin.slusarz
2008-01-07 14:55 ` Jan Kara
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=20080108182945.GA8106@joi \
--to=marcin.slusarz@gmail.com \
--cc=bfennema@falcon.csc.calpoly.edu \
--cc=hch@infradead.org \
--cc=jack@suse.cz \
--cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox