public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
From: Artem Bityutskiy <dedekind@infradead.org>
To: Brijesh Singh <brijesh.s.singh@gmail.com>
Cc: linux-mtd@lists.infradead.org
Subject: Re: UBI : Atomic change LEB
Date: Thu, 13 Sep 2007 16:16:28 +0300	[thread overview]
Message-ID: <1189689388.14370.124.camel@sauron> (raw)
In-Reply-To: <6b5362aa0709130602g61e9b6f0xa762be770e95a32b@mail.gmail.com>

On Thu, 2007-09-13 at 18:32 +0530, Brijesh Singh wrote:
> Thank you Artem.
> This seems like a good idea.This will certainly work
> .
> The only problem I see is
> * this will serialize  all the automic changes.If some device supports
> multiple writes in parrallel,we are locking it for no reason(We have
> reason but hope we can find another option).Also we won't need
> serialization when there are lots of spare blocks.

Well, this is not a big problem with the existing code base: mtd anyway
locks whole chip when doing I/O, and there are not users of this call
except of UBIFS which will not suffer much.

Also, if this is a problem for someone, we can always reserve N PEBs
for the atomic LEB change operation, and allow N tasks to do this
operation at a time. This is not difficult, we just need to use
something a bit more complex then a mutex.

-- 
Best regards,
Artem Bityutskiy (Битюцкий Артём)

  reply	other threads:[~2007-09-13 13:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-13  8:02 UBI : Atomic change LEB Brijesh Singh
2007-09-13 11:13 ` Artem Bityutskiy
2007-09-13 13:02   ` Brijesh Singh
2007-09-13 13:16     ` Artem Bityutskiy [this message]
2007-09-13 14:38     ` Jamie Lokier
2007-09-13 15:46       ` Artem Bityutskiy

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=1189689388.14370.124.camel@sauron \
    --to=dedekind@infradead.org \
    --cc=brijesh.s.singh@gmail.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