From: "Dan Bastone" <dan@pwienterprises.com>
To: "Eric Sandeen" <sandeen@sandeen.net>
Cc: linux-kernel@vger.kernel.org, bfennema@falcon.csc.calpoly.edu
Subject: Re: [PATCH]: initialize parts of udf inode earlier in create
Date: Mon, 07 Aug 2006 23:44:14 -0700 [thread overview]
Message-ID: <1155019454.29767.267870507@webmail.messagingengine.com> (raw)
In-Reply-To: <44D7C26F.1040609@sandeen.net>
On Mon, 07 Aug 2006 17:45:03 -0500, "Eric Sandeen" <sandeen@sandeen.net>
said:
> That looks fine to me, but I wonder if there's a cleaner way, rather
> than sprinkling these initializations in the code. If __udf_read_inode
> fails, then it calls mark_bad_inode; maybe the code should check for
> that before trying to discard prealloced blocks? I don't really know
> enough about all the UDF codepaths (by far!) to know for sure what the
> best solution is, here.
I'm certainly not an expert on this code either, but it seems like doing
the initializations once in udf_alloc_inode() makes the most sense. As
I said it should fix both of the scenarios you & I experienced as well
as any others that assume the udf_inode_info structs are zeroed. Now
that I look at it again, I think it also makes the initializations in
udf_new_inode() redundant.
So, assuming my previous patch is applied and yours is not, I think the
following is right:
---
Signed-off-by: Dan Bastone <dan@pwienterprises.com>
--- linux-2.6.17.7/fs/udf/ialloc.c.orig
+++ linux-2.6.17.7/fs/udf/ialloc.c
@@ -84,11 +84,6 @@
}
mutex_lock(&sbi->s_alloc_mutex);
- UDF_I_UNIQUE(inode) = 0;
- UDF_I_LENEXTENTS(inode) = 0;
- UDF_I_NEXT_ALLOC_BLOCK(inode) = 0;
- UDF_I_NEXT_ALLOC_GOAL(inode) = 0;
- UDF_I_STRAT4096(inode) = 0;
if (UDF_SB_LVIDBH(sb))
{
struct logicalVolHeaderDesc *lvhd;
---
Dan
--
http://www.fastmail.fm - Faster than the air-speed velocity of an
unladen european swallow
prev parent reply other threads:[~2006-08-08 6:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-08-04 15:57 [PATCH]: initialize parts of udf inode earlier in create Eric Sandeen
2006-08-07 7:14 ` dan
2006-08-07 22:45 ` Eric Sandeen
2006-08-08 6:44 ` Dan Bastone [this message]
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=1155019454.29767.267870507@webmail.messagingengine.com \
--to=dan@pwienterprises.com \
--cc=bfennema@falcon.csc.calpoly.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=sandeen@sandeen.net \
/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.