From: Ivan Khoronzhuk <ivan.khoronzhuk@ti.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [U-Boot, U-boot, 1/2] common: cmd_nand: add nand ecclayout command
Date: Fri, 20 Jun 2014 20:10:19 +0300 [thread overview]
Message-ID: <53A46AFB.2050506@ti.com> (raw)
In-Reply-To: <1403280181.12851.181.camel@snotra.buserror.net>
On 06/20/2014 07:03 PM, Scott Wood wrote:
> On Fri, 2014-06-20 at 09:10 -0500, Jon Loeliger wrote:
>>>>> --- a/common/cmd_nand.c
>>>>> +++ b/common/cmd_nand.c
>>>>> @@ -462,6 +462,53 @@ static void adjust_size_for_badblocks(loff_t *size,
>>>>> + for (i = 0; i < p->eccbytes; i++) {
>>>>> + if (i && !(i % 9))
>>>>> + printf("\n ");
>>>>> +
>>>>> + printf("%2d ", p->eccpos[i]);
>>>>> + }
>>>> Why 9?
>>>
>>> It's to print a new line on every 9th character position.
>>> I'll add a comment.
>> OK, Scott, breath... I got this one. It'll be OK...
>>
>> Ivan,
>> I am confident Scott understood that a newline would
>> be generated every ninth-character. We all get that. I think
>> what Scott was asking was why the value 9 was chosen?
>> Why not 10? Or 8? Or 145? Was it to fit some arbitrary
>> line length or screen size? Would it make more sense to
>> use something familiar like a base 10 or half of base-16?
> More specifically, it neither avoids a division (as a power of two
> would) nor does it seem to match the ecc size of the layouts used by the
> davinci driver (which is the only user of this so far), nor is it
> anywhere near 80 columns.
>
> Also, why is the field width two characters, when ecc positions can
> exceed 100?
>
> -Scott
>
>
Ok, I'll try to correct as you proposed. I dislike it also ...
Thanks.
--
Regards,
Ivan Khoronzhuk
next prev parent reply other threads:[~2014-06-20 17:10 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-16 18:26 [U-Boot] [U-boot] [Patch 0/2] keystone: nand: add additional nand ecclayout Ivan Khoronzhuk
2014-05-16 18:26 ` [U-Boot] [U-boot] [Patch 1/2] common: cmd_nand: add nand ecclayout command Ivan Khoronzhuk
2014-06-20 1:00 ` [U-Boot] [U-Boot, U-boot, " Scott Wood
2014-06-20 13:29 ` Ivan Khoronzhuk
2014-06-20 14:10 ` Jon Loeliger
2014-06-20 16:03 ` Scott Wood
2014-06-20 17:10 ` Ivan Khoronzhuk [this message]
2014-06-20 16:31 ` Scott Wood
2014-06-20 17:02 ` Ivan Khoronzhuk
2014-05-16 18:26 ` [U-Boot] [U-boot] [Patch 2/2] mtd: nand: davinci: allow to change ecclayout by " Ivan Khoronzhuk
2014-06-20 1:07 ` [U-Boot] [U-Boot, U-boot, " Scott Wood
2014-06-20 14:59 ` Ivan Khoronzhuk
2014-06-20 16:22 ` Scott Wood
2014-06-20 16:57 ` Ivan Khoronzhuk
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=53A46AFB.2050506@ti.com \
--to=ivan.khoronzhuk@ti.com \
--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 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.