From: Ladislav Michl <ladis@linux-mips.org>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] IMPORTANT NOTE to all maintainers with NAND flash
Date: Fri, 24 Mar 2006 01:43:38 +0100 [thread overview]
Message-ID: <20060324004338.GA14228@orphique> (raw)
In-Reply-To: <20060317211412.A6C00352B33@atlas.denx.de>
On Fri, Mar 17, 2006 at 10:14:12PM +0100, Wolfgang Denk wrote:
> > + int clean = (argc > 2 && strcmp(argv[2], "clean") == 0) ? 1 : 0;
> > + int o = clean ? 3 : 2;
> > + arg_off_size(argc - o, argv + o, &off, &size, nand->size);
>
> Can you please re-implement this in a bit a less cryptic way? I will
> not complain if it takes 6 lines instead of 3. LoC are cheap these
> days ;-)
Syntax is:
0 1 2 3 4
nand erase [clean] [off size]
So we just look if there are more that two arguments and argument at
index 2 is "clean". In that case we want also erase OOB. Then we just
skip first 2 or 3 argumets while looking for offset and size. Shall
I try harder to reimplement it or is additional comment okay? ;-)
Best regards,
ladis
next prev parent reply other threads:[~2006-03-24 0:43 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-02-28 9:21 [U-Boot-Users] IMPORTANT NOTE to all maintainers with NAND flash Wolfgang Denk
2006-02-28 10:05 ` Pantelis Antoniou
2006-03-17 18:50 ` Ladislav Michl
2006-03-17 21:14 ` Wolfgang Denk
2006-03-24 0:43 ` Ladislav Michl [this message]
2006-03-24 0:55 ` Wolfgang Denk
2006-03-24 1:23 ` Ladislav Michl
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=20060324004338.GA14228@orphique \
--to=ladis@linux-mips.org \
--cc=u-boot@lists.denx.de \
/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