[PATCH] MTD: mtdconcat NAND/Sibley support
Jörn Engel
joern at wohnheim.fh-wedel.de
Wed Apr 26 11:57:41 EDT 2006
On Wed, 26 April 2006 19:21:38 +0400, Alexander Belyakov wrote:
> Jorn Engel wrote:
> >
> >concat_writev() is far too complicated. I have a patch somewhere that
> >adds a generic writev() function to every device. Once that is in,
> >your patch should get a respin and be much simpler.
> >
>
> Having generic writev() still requires concat_writev() to split the data
> into several parts (in general case by number of subdevices). So I do
> not see how concat_writev() could become simpler.
Fair. Having writev() for the underlying devices doesn't buy you
much.
> In my patch you split data from downcoming vector into several _equal_
> page-sized chunks and write them by calling generic write().
Not sure whether the splitting makes much sense. As long as you don't
cross a boundary, just send the whole vector to the subdevice. And in
case of a boudary, there is no guarantee for it to reside on a page
boundary, so you currently have a bug anyway. One that you'll quickly
hit on dataflash.
> >I didn't closely look at the rest of it but suspect similar things.
>
> Why I'm not surprised here? :)
Either because
a) I'm lazy or
b) your code doesn't look inviting.
And just because I'm lazy doesn't imply anything about your code. :)
> Patch have nothing complex and have completely nothing new. Just fixes
> some broken stuff.
>
> Is it better to leave concatenation layer without any changes and only
> compatible with NOR devices, despite mtdconcat.c file comments claim
> that it does support NAND?
I'm not sure about your "nothing complex" statement, but fixing concat
is a worthy goal. Hope you don't mind if I point out the questionable
parts of your patch.
Jörn
--
Linux [...] existed just for discussion between people who wanted
to show off how geeky they were.
-- Rob Enderle
More information about the linux-mtd
mailing list