public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Lukasz Majewski <lukma@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] How to restore NVRAM on MTD partition from backup
Date: Thu, 28 Dec 2017 23:09:37 +0100	[thread overview]
Message-ID: <20171228230937.38d348d1@jawa> (raw)
In-Reply-To: <1820015694.5687163.1514494008039@mail.yahoo.com>

Hi,

> Missed that mail :(
> 
> it's old board, I have no source code for that customized version of
> bootloader.
> 
> I have commands 
> loadb   - load binary file over serial line (kermit mode)
> loads   - load S-Record file over serial line
> loady   - load binary file over serial line (ymodem mode)

You should be able to use kermit to upload new data to RAM (to some
address).

> 
> NAND device: Manufacturer ID: 0xad, Chip ID: 0x75 (Hynix NAND 32MiB
> 3,3V 8-bit) The NVRAM is MTD partition on "gen_nand":
> 0x01f00000-0x01f80000 : "NVRAM"
> dev:    size   erasesize  name
> mtd9: 00080000 00004000 "NVRAM"

So the NVRAM is a mtd partition for NAND.

What is the output of mtdparts command?

> 
> The cp command is available in bootloader
> 
> # help cp
> cp [.b, .w, .l] source target count
>     - copy memory

It should be enough to use "nand" commands:
https://www.denx.de/wiki/DULG/UBootCmdGroupNand

Erase, then write the mtd9 partition.

> 
> 
> 
> 
> Regards,
> Alex
> --------------------------------------------
> On Fri, 12/22/17, Lukasz Majewski <lukma@denx.de> wrote:
> 
>  Subject: Re: [U-Boot] How to restore NVRAM on MTD partition from
> backup To: "A.W.C." <bluestream@ymail.com>
>  Cc: u-boot at lists.denx.de
>  Date: Friday, December 22, 2017, 11:58 PM
>  
>  On Wed, 20 Dec 2017 13:19:58
>  +0000 (UTC)
>  "A.W.C." <bluestream@ymail.com>
>  wrote:
>  
>  > Hi,
>  > 
>  > U-Boot 2009.03 on  
>  custom board. 
>  
>  Nice :-)
>  
>  I assume that it is not
>  possible to move to newer one?
>  
>  >How to restore NVRAM on MTD partition
>  > from backup use U-boot memory commands, by  
>  uploading backup over
>  > serial line?  
>  (kermit mode or ymodem mode) NAND flash type.
>  
>  It depends on what commands do
>  you have?
>  
>  Yes, it would be
>  best to use load command to get the data via serial
>  line, store it in RAM and then flash it on
>  persistent memory.
>  
>  How do
>  you access NVRAM? (Is it really this memory - not some
>  Parallel
>  NAND, SPI-NOR, OneNAND)?
>  
>  If it has a custom driver
>  ,then you may want to look for 'cp' or other
>  command.
>  
>  >  
>  
>  > Regards,
>  >  
>  Alex
>  > 
>  > 
>  >  
>  _______________________________________________
>  > U-Boot mailing list
>  >  
>  U-Boot at lists.denx.de
>  > https://lists.denx.de/listinfo/u-boot  
>  
>  
>  
>  Best regards,
>  
>  Lukasz Majewski
>  
>  --
>  
>  DENX
>  Software Engineering GmbH,      Managing Director:
>  Wolfgang Denk
>  HRB 165235 Munich, Office:
>  Kirchenstr.5, D-82194 Groebenzell, Germany
>  Phone: (+49)-8142-66989-10 Fax:
>  (+49)-8142-66989-80 Email: wd at denx.de



Best regards,

Lukasz Majewski

--

DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20171228/19b0091a/attachment.sig>

  reply	other threads:[~2017-12-28 22:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1820015694.5687163.1514494008039.ref@mail.yahoo.com>
2017-12-28 20:46 ` [U-Boot] How to restore NVRAM on MTD partition from backup A.W.C.
2017-12-28 22:09   ` Lukasz Majewski [this message]
     [not found] <900150360.1783904.1513775998046.ref@mail.yahoo.com>
2017-12-20 13:19 ` A.W.C.
2017-12-22 21:58   ` Lukasz Majewski

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=20171228230937.38d348d1@jawa \
    --to=lukma@denx.de \
    --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