public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Tom Rini <trini@konsulko.com>
To: u-boot@lists.denx.de
Subject: [PATCH] lib: strto: Stop detection when invalid char is used
Date: Sun, 26 Apr 2020 07:26:17 -0400	[thread overview]
Message-ID: <20200426112617.GP4555@bill-the-cat> (raw)
In-Reply-To: <1a681dbefac4c353ad53d7f6cd1a75812036739a.1586333353.git.michal.simek@xilinx.com>

On Wed, Apr 08, 2020 at 10:09:16AM +0200, Michal Simek wrote:

> This issue has been found when mtd partition are specified. Autodetection
> code should stop when the first invalid char is found.
> 
> Here is the example of commands:
> setenv mtdids nand0=memory-controller at e000e000
> setenv mtdparts "mtdparts=nand0:4m(boot),4m(env),64m(kernel),96m(rootfs)"
> mtd list
> 
> Before:
> Zynq> mtd list
> List of MTD devices:
> * nand0
>   - type: NAND flash
>   - block size: 0x20000 bytes
>   - min I/O: 0x800 bytes
>   - OOB size: 64 bytes
>   - OOB available: 16 bytes
>   - ECC strength: 1 bits
>   - ECC step size: 2048 bytes
>   - bitflip threshold: 1 bits
>   - 0x000000000000-0x000010000000 : "nand0"
> 	  - 0x000000000000-0x000000400000 : "boot"
> 	  - 0x000000400000-0x000000800000 : "env"
> 	  - 0x000000800000-0x000006c00000 : "kernel"
> 	  - 0x000006c00000-0x000010000000 : "rootfs"
> 
> Where it is visible that kernel partition has 100m instead of 64m
> 
> After:
> Zynq> mtd list
> * nand0
>   - type: NAND flash
>   - block size: 0x20000 bytes
>   - min I/O: 0x800 bytes
>   - OOB size: 64 bytes
>   - OOB available: 16 bytes
>   - ECC strength: 1 bits
>   - ECC step size: 2048 bytes
>   - bitflip threshold: 1 bits
>   - 0x000000000000-0x000010000000 : "nand0"
> 	  - 0x000000000000-0x000000400000 : "boot"
> 	  - 0x000000400000-0x000000800000 : "env"
> 	  - 0x000000800000-0x000004800000 : "kernel"
> 	  - 0x000004800000-0x00000a800000 : "rootfs"
> 
> Signed-off-by: Michal Simek <michal.simek@xilinx.com>
> Tested-by: Heiko Schocher <hs@denx.de>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200426/68b84333/attachment.sig>

      parent reply	other threads:[~2020-04-26 11:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-08  8:09 [PATCH] lib: strto: Stop detection when invalid char is used Michal Simek
2020-04-22  9:25 ` Heiko Schocher
2020-04-26 11:26 ` Tom Rini [this message]

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=20200426112617.GP4555@bill-the-cat \
    --to=trini@konsulko.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox