From: Evgeniy Dushistov <dushistov@mail.ru>
To: Alessio Igor Bogani <abogani@kernel.org>
Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
Tim Bird <tim.bird@am.sony.com>
Subject: Re: [PATCH] ufs: Check if page has buffers before calling page_buffers()
Date: Wed, 2 Feb 2011 07:23:47 +0300 [thread overview]
Message-ID: <20110202042347.GA3870@maclin> (raw)
In-Reply-To: <1296595418-2457-1-git-send-email-abogani@kernel.org>
On Tue, Feb 01, 2011 at 10:23:38PM +0100, Alessio Igor Bogani wrote:
> In ufs_change_blocknr() we have called page_buffers() without checking if the
> page actually had pages attached to it and this could cause a BUG oops.
>
This looks wrong for me. May be I missed something?
Put little more context here.
In ufs the tail of small files consists of fragments (usually 2K),
the rest of file consists of blocks (usually 16K=8 fragments).
When file is growing, and tail become too big (8 fragments)
we allocate one block and move content of 8 fragments to it.
So in our case we reach (during realocation) point when
!page_has_buffers(page) (how?) and in your patch you suggest
just ignore such buffer (in terms of ufs - fragments),
in other words silently corrupt user data.
May be there is better variant?
--
/Evgeniy
next prev parent reply other threads:[~2011-02-02 4:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-01 21:23 [PATCH] ufs: Check if page has buffers before calling page_buffers() Alessio Igor Bogani
2011-02-02 4:23 ` Evgeniy Dushistov [this message]
2011-02-02 17:57 ` Alessio Igor Bogani
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=20110202042347.GA3870@maclin \
--to=dushistov@mail.ru \
--cc=abogani@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tim.bird@am.sony.com \
/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.