[PATCH 03/10] nandwrite: consolidate buffer usage

Brian Norris computersforpeace at gmail.com
Wed Sep 14 14:22:11 EDT 2011


On Wed, Sep 14, 2011 at 1:15 AM, Mike Frysinger <vapier.adi at gmail.com> wrote:
> On Wed, Aug 31, 2011 at 16:00, Brian Norris wrote:
>> Instead of using two different output buffers for OOB data, let's just
>> use the same one for all output. This adds an extra memcpy, but it
>> simplifies some future work, so it's worth it.
>
> could it be done by pulling out the pointer ?  make oobbuf a "char *",
> rename existing oobbuf to like "char _oobbuf[]", and then assign
> oobbuf to the relevant buffer and assume it's always set ...

It could be done this way, but actually, this patch was not intended
to stand alone; it was a precursor to removing one of the buffers from
nandwrite.c, as done in patch 07/10:
   mtdutils: move OOB auto-layout into libmtd's mtd_write


More information about the linux-mtd mailing list