* RE: [ECOS] Error when changing 'fconfig' redboot values from a linux program
@ 2006-05-17 15:12 Calin Onofrei
0 siblings, 0 replies; 6+ messages in thread
From: Calin Onofrei @ 2006-05-17 15:12 UTC (permalink / raw)
To: Andrew Lunn; +Cc: ecos-discuss
Andrew,
I read/write 4096 bytes. I tried to replace the erase by writing 4096
bytes of 0x00, but is not working. I'll try to use ioctl's MEMERASE
option.
Calin Onofrei.
-----Original Message-----
From: Andrew Lunn [mailto:andrew@lunn.ch]
Sent: Wednesday, May 17, 2006 11:03 AM
To: Calin Onofrei
Cc: ecos-discuss@ecos.sourceware.org
Subject: Re: [ECOS] Error when changing 'fconfig' redboot values from a
linux program
On Wed, May 17, 2006 at 10:51:23AM -0400, Calin Onofrei wrote:
> Thierry,
>
> In my case RedBoot config is on mtd5 partition (do cat /proc/mtd to
see) and I open the device:
> Open("/dev/mtd5", O_RDWR | O_SYNC). With the handle returned by the
open function I do read and write operations as for any other device.
But is /dev/mtd5 like any other device? Or do you need to erase it using
an ioctl call?
I don't know, but maybe you need to find out.
Andrew
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [ECOS] Error when changing 'fconfig' redboot values from a linux program
@ 2006-05-17 19:50 Calin Onofrei
0 siblings, 0 replies; 6+ messages in thread
From: Calin Onofrei @ 2006-05-17 19:50 UTC (permalink / raw)
To: Andrew Lunn; +Cc: ecos-discuss
Now is working, I can read/write Redboot configuration from a linux
program. Before writing I use the ioctl MEMERASE and erase the whole
RedBoot config block.
Thanks Andrew for your suggestion.
Calin Onofrei.
-----Original Message-----
From: Andrew Lunn [mailto:andrew@lunn.ch]
Sent: Wednesday, May 17, 2006 11:03 AM
To: Calin Onofrei
Cc: ecos-discuss@ecos.sourceware.org
Subject: Re: [ECOS] Error when changing 'fconfig' redboot values from a
linux program
On Wed, May 17, 2006 at 10:51:23AM -0400, Calin Onofrei wrote:
> Thierry,
>
> In my case RedBoot config is on mtd5 partition (do cat /proc/mtd to
see) and I open the device:
> Open("/dev/mtd5", O_RDWR | O_SYNC). With the handle returned by the
open function I do read and write operations as for any other device.
But is /dev/mtd5 like any other device? Or do you need to erase it using
an ioctl call?
I don't know, but maybe you need to find out.
Andrew
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [ECOS] Error when changing 'fconfig' redboot values from a linux program
2006-05-17 14:51 Calin Onofrei
@ 2006-05-17 15:05 ` Andrew Lunn
0 siblings, 0 replies; 6+ messages in thread
From: Andrew Lunn @ 2006-05-17 15:05 UTC (permalink / raw)
To: Calin Onofrei; +Cc: ecos-discuss
On Wed, May 17, 2006 at 10:51:23AM -0400, Calin Onofrei wrote:
> Thierry,
>
> In my case RedBoot config is on mtd5 partition (do cat /proc/mtd to see) and I open the device:
> Open("/dev/mtd5", O_RDWR | O_SYNC). With the handle returned by the open function I do read and write operations as for any other device.
But is /dev/mtd5 like any other device? Or do you need to erase it
using an ioctl call?
I don't know, but maybe you need to find out.
Andrew
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [ECOS] Error when changing 'fconfig' redboot values from a linux program
@ 2006-05-17 14:51 Calin Onofrei
2006-05-17 15:05 ` Andrew Lunn
0 siblings, 1 reply; 6+ messages in thread
From: Calin Onofrei @ 2006-05-17 14:51 UTC (permalink / raw)
To: thierry langlais; +Cc: ecos-discuss
Thierry,
In my case RedBoot config is on mtd5 partition (do cat /proc/mtd to see) and I open the device:
Open("/dev/mtd5", O_RDWR | O_SYNC). With the handle returned by the open function I do read and write operations as for any other device.
Calin Onofrei.
-----Original Message-----
From: thierry langlais [mailto:thierry.langlais@efixo.com]
Sent: Wednesday, May 17, 2006 10:09 AM
To: Calin Onofrei
Cc: ecos-discuss@ecos.sourceware.org
Subject: Re: [ECOS] Error when changing 'fconfig' redboot values from a linux program
How are you using MTD Driver ?
Could you give us more details ?
Thierry Langlais.
Le mercredi 17 mai 2006 à 09:33 -0400, Calin Onofrei a écrit :
> Hi All,
>
> I am trying to change the RedBoot config from a Linux program.
> I can read the RedBoot configuration from user space with MTD driver
> function but when I write the configuration changed for an unsigned
> long
> (4 bytes) always the 3rd byte isn't changed and keep the old value!
> Any suggestion?
>
> Thanks,
> Calin.
>
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [ECOS] Error when changing 'fconfig' redboot values from a linux program
2006-05-17 13:34 Calin Onofrei
@ 2006-05-17 14:12 ` thierry langlais
0 siblings, 0 replies; 6+ messages in thread
From: thierry langlais @ 2006-05-17 14:12 UTC (permalink / raw)
To: Calin Onofrei; +Cc: ecos-discuss
How are you using MTD Driver ?
Could you give us more details ?
Thierry Langlais.
Le mercredi 17 mai 2006 à 09:33 -0400, Calin Onofrei a écrit :
> Hi All,
>
> I am trying to change the RedBoot config from a Linux program.
> I can read the RedBoot configuration from user space with MTD driver
> function but when I write the configuration changed for an unsigned long
> (4 bytes) always the 3rd byte isn't changed and keep the old value!
> Any suggestion?
>
> Thanks,
> Calin.
>
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 6+ messages in thread
* [ECOS] Error when changing 'fconfig' redboot values from a linux program
@ 2006-05-17 13:34 Calin Onofrei
2006-05-17 14:12 ` thierry langlais
0 siblings, 1 reply; 6+ messages in thread
From: Calin Onofrei @ 2006-05-17 13:34 UTC (permalink / raw)
To: ecos-discuss@ecos.sourceware.org
Hi All,
I am trying to change the RedBoot config from a Linux program.
I can read the RedBoot configuration from user space with MTD driver
function but when I write the configuration changed for an unsigned long
(4 bytes) always the 3rd byte isn't changed and keep the old value!
Any suggestion?
Thanks,
Calin.
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2006-05-17 19:50 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-05-17 15:12 [ECOS] Error when changing 'fconfig' redboot values from a linux program Calin Onofrei
-- strict thread matches above, loose matches on Subject: below --
2006-05-17 19:50 Calin Onofrei
2006-05-17 14:51 Calin Onofrei
2006-05-17 15:05 ` Andrew Lunn
2006-05-17 13:34 Calin Onofrei
2006-05-17 14:12 ` thierry langlais
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).