From: Artem Bityutskiy <dedekind1@gmail.com>
To: Bhavesh Parekh <bparekh@nvidia.com>
Cc: "linux-mtd@lists.infradead.org" <linux-mtd@lists.infradead.org>
Subject: Re: [UBI] Missing scrub when there is a bit-flip
Date: Wed, 30 Nov 2011 00:15:46 +0200 [thread overview]
Message-ID: <1322604953.2150.24.camel@koala> (raw)
In-Reply-To: <6F5E0EB93579CE4A99BFB2D6A9D015057D9CA89078@BGMAIL01.nvidia.com>
Hi, good catch!
On Wed, 2011-11-23 at 18:58 +0530, Bhavesh Parekh wrote:
... snip ...
> When we used leb_write_lock instead of leb_write_trylock() then we are
> seeing matching erase-call for the bit-flips.
>
> So, we are currently thinking 2 possible approaches to fix this:
> 1. Use leb_write_lock instead of leb_write_trylock(), but
> leb_write_trylock was used to avoid contention. Will adding back will
> have side-effect ?
Yeah, there is a big comment which explains that this can cause a
dead-lock, so you cannot use leb_write_lock().
> 2. Add the leb again in the scrubbing list for scrubbing. There is
> already code for the same in the implementation, (in out_not_moved
> case where scrubbed=1 if condition), but since we have set protect=1
> we won't go in this condition. We are thinking to return two
> different error code from the eba_copy_leb base for two different
> cases in the function (one where volume is removed and another is
> contention). And only in case of contention set scrubbing=1 and call
> goto out_not_moved which will add this LEB for scrubbing again.
Yes, this sounds reasonable, introduce a separate return code, like
MOVE_RETRY. Please go ahead and send a patch.
Thanks!
next prev parent reply other threads:[~2011-11-29 22:15 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-23 13:28 [UBI] Missing scrub when there is a bit-flip Bhavesh Parekh
2011-11-29 22:15 ` Artem Bityutskiy [this message]
2011-11-30 12:19 ` Bhavesh Parekh
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=1322604953.2150.24.camel@koala \
--to=dedekind1@gmail.com \
--cc=bparekh@nvidia.com \
--cc=linux-mtd@lists.infradead.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