All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Dunn <mikedunn@newsguy.com>
To: dedekind1@gmail.com
Cc: Scott Branden <sbranden@broadcom.com>,
	Joern Engel <joern@logfs.org>,
	Kyungmin Park <kyungmin.park@samsung.com>,
	linux-mtd@lists.infradead.org,
	Jiandong Zheng <jdzheng@broadcom.com>,
	Robert Jarzmik <robert.jarzmik@free.fr>
Subject: Re: [PATCH] MTD: drivers return bitlip info to mtd on read
Date: Tue, 27 Dec 2011 12:26:12 -0800	[thread overview]
Message-ID: <4EFA29E4.1020803@newsguy.com> (raw)
In-Reply-To: <1324974817.1165.51.camel@sauron.fi.intel.com>

On 12/27/2011 12:33 AM, Artem Bityutskiy wrote:
> On Mon, 2011-12-26 at 11:38 -0800, Mike Dunn wrote:
>> This patch changes the meaning of the value returned by the read() and
>> read_oob() mtd driver methods.  Previously, absent a hard error, these functions
>> returned either -EUCLEAN (one or more bitflips were corrected) or 0 (no
>> bitflips).  Drivers now return, absent a hard error, the maximum number of
>> bitflips that were corrected on any one page.  
>>
>> This change is made possible by the fact that all calls to the driver methods
>> now go through mtd wrapper functions.  The values returned by those wrapper
>> functions have not changed, nor have their meaning.  Only the values returned to
>> the mtd wrappers by the driver have changed.
>>
>> Tested with nandsim and onenand_sim.  The two drivers that were modified were
>> compile-tested only.
>>
>> Signed-off-by: Mike Dunn <mikedunn@newsguy.com>
> Hi, I am not sure using the return code is a good way for this.


OK.  It was a little kludgey, but had the advantage of touching very few drivers
and leaving the existing function prototypes unchanged.


> But please, proceed with working on your issues - this patch is not
> going to hit 3.2 anyway - I think it is the 3.3 material. Linus promised
> 3.2 release this week, then we have the merge window, and then it is
> time for further patches in this area.
>
> I will do the other changes which I described in my cover letter. I
> will also make a patch which adds a bitflips parameter to read/read_oob
> and then you will implement 
>
> But please, just make something which works for you for now and go on
> with other DoC issues you have. Meantime I'll prepare the MTD basis
> for you.
>
> I think I'll first do the 3 items I described in my series. Then I'll
> add "bitflips" parameter to read/read_oob() functions, but won't
> implement or ever check it. After this you'll add your code.
>
> How does this sound to you?


Sure, you're the boss.  I appreciate your attention on this.  If you like, I'd
be happy to submit a patch that adds the max_bitflips argument to  read() and
read_oob() after you finish the cleanup and consolidation made possible by the
wrappers.  I've already done this work.  Your choice; let me know.

Thanks again,
Mike

  reply	other threads:[~2011-12-27 20:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-26 19:38 [PATCH] MTD: drivers return bitlip info to mtd on read Mike Dunn
2011-12-27  8:33 ` Artem Bityutskiy
2011-12-27 20:26   ` Mike Dunn [this message]
2011-12-27 20:57     ` 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=4EFA29E4.1020803@newsguy.com \
    --to=mikedunn@newsguy.com \
    --cc=dedekind1@gmail.com \
    --cc=jdzheng@broadcom.com \
    --cc=joern@logfs.org \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-mtd@lists.infradead.org \
    --cc=robert.jarzmik@free.fr \
    --cc=sbranden@broadcom.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.