[RFC 1/5] mtd: support MTD_MODE_RAW for writing OOB

Artem Bityutskiy dedekind1 at gmail.com
Tue Aug 23 00:47:49 EDT 2011


On Mon, 2011-08-22 at 13:08 -0700, Brian Norris wrote:
> I forgot to CC a contributor on this (and the complementary patch for
> "read OOB")
> 
> Cc: Jim Quinlan <jim2101024 at gmail.com>
> 
> On Mon, Aug 22, 2011 at 1:35 AM, Artem Bityutskiy <dedekind1 at gmail.com> wrote:
> > On Wed, 2011-08-17 at 16:50 -0700, Brian Norris wrote:
> >> This fixes issues with `nandwrite -n' and the MEMWRITEOOB[64] ioctls.
> >
> > I guess this patch deserves to be non-RFC? Should it be pushed to
> > l2-mtd-2.6.git? Should it even have "Cc: stable at kernel.org [kernel
> > version +] ?
> 
> I'm not actually sure where this stands (RFC vs. patch) since I really
> wanted some outside opinion on the methods used here. I have a feeling
> that some of this is only working on my hardware. For instance,
> somehow (I'm really not sure how!) `nandwrite -n -o' is working in
> nandsim without my fix. Perhaps this is due to a different set of
> nand_ecc_ctrl functions (soft ECC vs. HW ECC).

May be one of the reasons is that nandsim just _copies_ data to the
internal RAM buffer, instead of doing binary "&", so you can re-write in
some cases, but not sure.

> With this patch applied, however, I get some strange kernel oopses
> with nandsim. I've identified at least one issue, I think, but I
> haven't completely resolved this discrepancy between nandsim and my
> driver. See sample commands:
> 
> # insmod nandsim.ko
> # nandwrite /dev/mtdX <data.bin> -n -o
> 
> So for this "fix" (and its coming updates), I would appreciate some
> outside testing on other systems, especially before we send this to
> stable or even before including it upstream at all.
> 
> And any comments on the current status of noecc and MTD_OOB_RAW from
> others would be highly valuable to me; a bit of system information and
> a "working" or "not working since commit [XXX]" would be a start. In
> the meantime, I'm trying to get a hold of a wider variety of test
> systems for myself for these kind of issues...

Yes, would be great to have more people to test. I always encourage
people to look at patches _before_ they get in and break their systems,
not afterwards. But even if nobody cares, we can merge your stuff after
you gave it some more testing - absence of caring people should not stop
the progress in MTD :-) 

-- 
Best Regards,
Artem Bityutskiy




More information about the linux-mtd mailing list