* Linux Kernel MTD question
@ 2005-08-21 8:02 JohnsonCheng
2005-08-21 20:58 ` Wolfgang Denk
0 siblings, 1 reply; 15+ messages in thread
From: JohnsonCheng @ 2005-08-21 8:02 UTC (permalink / raw)
To: linuxppc-embedded
[-- Attachment #1: Type: text/plain, Size: 507 bytes --]
Dear All,
Just as I know, we can have many partitions for our flash if we turn on MTD
in Kernel. For example:
0x00000000-0x00040000: u-boot
0x00040000-0x00100000: kernel
0x00100000-0x00200000: inirid1
0x00200000-0x00400000: initrd2
How could I distribute my RootFS into initrd1 and initrd2?
In U-Boot command, bootcmd, I set it to "bootm 40000 100000". 40000 is
Kernel address, and 100000 is RootFS1 address. But where to set RootRS2
address?
Thanks,
Johnson Cheng
[-- Attachment #2: Type: text/html, Size: 4224 bytes --]
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Linux Kernel MTD question
2005-08-21 8:02 JohnsonCheng
@ 2005-08-21 20:58 ` Wolfgang Denk
2005-08-22 2:56 ` JohnsonCheng
0 siblings, 1 reply; 15+ messages in thread
From: Wolfgang Denk @ 2005-08-21 20:58 UTC (permalink / raw)
To: JohnsonCheng; +Cc: linuxppc-embedded
In message <20050821080936.DA55167F92@ozlabs.org> you wrote:
>
> Just as I know, we can have many partitions for our flash if we turn on MTD
> in Kernel. For example:
Right.
> How could I distribute my RootFS into initrd1 and initrd2?
You cannot. The *root* filesystem is always just a single file system.
You can mount additional file systems on top of the directory
hierarchy provided by your root file system, but this is something
completely different.
> In U-Boot command, bootcmd, I set it to "bootm 40000 100000". 40000 is
> Kernel address, and 100000 is RootFS1 address. But where to set RootRS2
> address?
There are several errors in this text.
First, the kernel download address 0x40000 = 256kB is much too low
and can never work.
Second, the "100000" parameter is not a "RootFS1 address". It is the
start address of a ramdisk image. This may or may not be your root
file system, and it is usually NOT the address as seen by the kernel.
And, 100000 = 1 MB is a much too low address and can never work.
And finally: all this has absolutely NOTHING to do with MTD partitions.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Documentation is like sex: when it is good, it is very, very good;
and when it is bad, it is better than nothing. - Dick Brandon
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-21 20:58 ` Wolfgang Denk
@ 2005-08-22 2:56 ` JohnsonCheng
0 siblings, 0 replies; 15+ messages in thread
From: JohnsonCheng @ 2005-08-22 2:56 UTC (permalink / raw)
To: 'Wolfgang Denk'; +Cc: linuxppc-embedded
Very Thanks for your reply.
I am sorry that this data is copied from Building Embedded Linux Systems
book.
Actually, the range of my flash is from 0xFF000000 to 0xFFFFFFFF. My
starting address of Kernel is 0xFF000000, and the starting address of
ramdisk image is FF200000, so the partitions is as following:
0xFF000000 - 0xFF1FFFFF Kernel
0xFF200000 - 0xFF9FFFFF RamDisk Image ( also my Root File System )
And I found my RootFS image is so big that waste many time while write it to
flash.
I hope I can use MTD to distribute it into two parts, Simple RootFS and
libraries, but I don't know how to implement it?
My CPU is MPC8241, and my kernel configure is base on Sandpoint_defconfig.
Thanks,
Johnson Cheng
-----Original Message-----
From: linuxppc-embedded-bounces@ozlabs.org
[mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Wolfgang Denk
Sent: Monday, August 22, 2005 4:59 AM
To: JohnsonCheng
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Linux Kernel MTD question
In message <20050821080936.DA55167F92@ozlabs.org> you wrote:
>
> Just as I know, we can have many partitions for our flash if we turn on
MTD
> in Kernel. For example:
Right.
> How could I distribute my RootFS into initrd1 and initrd2?
You cannot. The *root* filesystem is always just a single file system.
You can mount additional file systems on top of the directory
hierarchy provided by your root file system, but this is something
completely different.
> In U-Boot command, bootcmd, I set it to "bootm 40000 100000". 40000 is
> Kernel address, and 100000 is RootFS1 address. But where to set RootRS2
> address?
There are several errors in this text.
First, the kernel download address 0x40000 = 256kB is much too low
and can never work.
Second, the "100000" parameter is not a "RootFS1 address". It is the
start address of a ramdisk image. This may or may not be your root
file system, and it is usually NOT the address as seen by the kernel.
And, 100000 = 1 MB is a much too low address and can never work.
And finally: all this has absolutely NOTHING to do with MTD partitions.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Documentation is like sex: when it is good, it is very, very good;
and when it is bad, it is better than nothing. - Dick Brandon
_______________________________________________
Linuxppc-embedded mailing list
Linuxppc-embedded@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-embedded
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Linux Kernel MTD question
[not found] <20050822030032.4917442C7E@denx.de>
@ 2005-08-22 8:17 ` Wolfgang Denk
2005-08-22 10:46 ` JohnsonCheng
0 siblings, 1 reply; 15+ messages in thread
From: Wolfgang Denk @ 2005-08-22 8:17 UTC (permalink / raw)
To: JohnsonCheng; +Cc: linuxppc-embedded
In message <20050822030032.4917442C7E@denx.de> you wrote:
>
> Actually, the range of my flash is from 0xFF000000 to 0xFFFFFFFF. My
> starting address of Kernel is 0xFF000000, and the starting address of
> ramdisk image is FF200000, so the partitions is as following:
> 0xFF000000 - 0xFF1FFFFF Kernel
> 0xFF200000 - 0xFF9FFFFF RamDisk Image ( also my Root File System )
>
> And I found my RootFS image is so big that waste many time while write it to
> flash.
Then avoid writing it that often. Use a more efficient setup for
developoment and test, like root file system mounted over NFS.
> I hope I can use MTD to distribute it into two parts, Simple RootFS and
> libraries, but I don't know how to implement it?
You can use MTD to provide an additional file system which can then
be mounted by one of your startup scripts. MTD configuration and file
system building is documented in the DULG, please see
http://www.denx.de/twiki/bin/view/DULG/Manual
It is not possible to give good advice how to split data into
separate file systems, or how exactly you can mount it without
precise knowledge of your system and it's requirements. For example,
do you use a SysV init with several run levels, or a simple setup for
example based on busybox? In the end this is something which you have
to design yourself.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Let the programmers be many and the managers few -- then all will be
productive. -- Geoffrey James, "The Tao of Programming"
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-22 8:17 ` Linux Kernel MTD question Wolfgang Denk
@ 2005-08-22 10:46 ` JohnsonCheng
0 siblings, 0 replies; 15+ messages in thread
From: JohnsonCheng @ 2005-08-22 10:46 UTC (permalink / raw)
To: 'Wolfgang Denk'; +Cc: linuxppc-embedded
I have browsed the website, http://www.denx.de/twiki/bin/view/DULG/Manual.
For this example:
0x00000000-0x00060000 : "U-Boot"
0x00060000-0x00080000 : "Environment 1"
0x00080000-0x000A0000 : "Environment 2"
0x000A0000-0x000C0000 : "ASIC Images"
0x000C0000-0x001C0000 : "Linux Kernel"
0x001C0000-0x005C0000 : "Ramdisk Image"
0x005C0000-0x01000000 : "User Data"
How can I put the Environment variables or configurations in
0x00060000-0x00080000, or put User Data in 0x005C0000-0x1000000?
Use U-boot command? Or....
Best Regards,
Johnson Cheng
-----Original Message-----
From: linuxppc-embedded-bounces@ozlabs.org
[mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Wolfgang Denk
Sent: Monday, August 22, 2005 4:17 PM
To: JohnsonCheng
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Linux Kernel MTD question
In message <20050822030032.4917442C7E@denx.de> you wrote:
>
> Actually, the range of my flash is from 0xFF000000 to 0xFFFFFFFF. My
> starting address of Kernel is 0xFF000000, and the starting address of
> ramdisk image is FF200000, so the partitions is as following:
> 0xFF000000 - 0xFF1FFFFF Kernel
> 0xFF200000 - 0xFF9FFFFF RamDisk Image ( also my Root File
System )
>
> And I found my RootFS image is so big that waste many time while write it
to
> flash.
Then avoid writing it that often. Use a more efficient setup for
developoment and test, like root file system mounted over NFS.
> I hope I can use MTD to distribute it into two parts, Simple RootFS and
> libraries, but I don't know how to implement it?
You can use MTD to provide an additional file system which can then
be mounted by one of your startup scripts. MTD configuration and file
system building is documented in the DULG, please see
http://www.denx.de/twiki/bin/view/DULG/Manual
It is not possible to give good advice how to split data into
separate file systems, or how exactly you can mount it without
precise knowledge of your system and it's requirements. For example,
do you use a SysV init with several run levels, or a simple setup for
example based on busybox? In the end this is something which you have
to design yourself.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Let the programmers be many and the managers few -- then all will be
productive. -- Geoffrey James, "The Tao of Programming"
_______________________________________________
Linuxppc-embedded mailing list
Linuxppc-embedded@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-embedded
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Linux Kernel MTD question
[not found] <20050822104924.214ED429CB@denx.de>
@ 2005-08-22 13:07 ` Wolfgang Denk
2005-08-23 3:12 ` JohnsonCheng
2005-08-23 5:26 ` JohnsonCheng
0 siblings, 2 replies; 15+ messages in thread
From: Wolfgang Denk @ 2005-08-22 13:07 UTC (permalink / raw)
To: JohnsonCheng; +Cc: linuxppc-embedded
In message <20050822104924.214ED429CB@denx.de> you wrote:
>
> How can I put the Environment variables or configurations in
> 0x00060000-0x00080000, or put User Data in 0x005C0000-0x1000000?
> Use U-boot command? Or....
It is up to you to define a memory map for your flash device(s) and
create appropriate partitions for this map in Linux (and probably in
U-Boot, too, using the new "mtdparts" command).
Then you can use standard commands in U-Boot (erase, cp) and in Linux
(erase_all, cp) to store any data you likein your flash.
It is *your* design. *You* must create it.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
The IQ of the group is the lowest IQ of a member of the group divided
by the number of people in the group.
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-22 13:07 ` Wolfgang Denk
@ 2005-08-23 3:12 ` JohnsonCheng
2005-08-23 3:24 ` Robert P. J. Day
2005-08-23 5:26 ` JohnsonCheng
1 sibling, 1 reply; 15+ messages in thread
From: JohnsonCheng @ 2005-08-23 3:12 UTC (permalink / raw)
To: wd; +Cc: linuxppc-embedded
Yes. You are right. It's design by myself.
But I meet a problem. If I have three configuration files, A.conf, B.conf
and C.conf, then I hope save them in one of partitions of MTD,
0x005C0000-0x10000000.
Two questions:
1. How to build these configuration files into an image for U-boot with
mkimage?
2. In kernel, how to get these data? I use "mount /dev/mtd4 /mnt", but it
failed by block device required.
Thanks,
Johnson Cheng
-----Original Message-----
From: wd@denx.de [mailto:wd@denx.de]
Sent: Monday, August 22, 2005 9:07 PM
To: JohnsonCheng
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Linux Kernel MTD question
In message <20050822104924.214ED429CB@denx.de> you wrote:
>
> How can I put the Environment variables or configurations in
> 0x00060000-0x00080000, or put User Data in 0x005C0000-0x1000000?
> Use U-boot command? Or....
It is up to you to define a memory map for your flash device(s) and
create appropriate partitions for this map in Linux (and probably in
U-Boot, too, using the new "mtdparts" command).
Then you can use standard commands in U-Boot (erase, cp) and in Linux
(erase_all, cp) to store any data you likein your flash.
It is *your* design. *You* must create it.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
The IQ of the group is the lowest IQ of a member of the group divided
by the number of people in the group.
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-23 3:12 ` JohnsonCheng
@ 2005-08-23 3:24 ` Robert P. J. Day
2005-08-23 5:31 ` JohnsonCheng
0 siblings, 1 reply; 15+ messages in thread
From: Robert P. J. Day @ 2005-08-23 3:24 UTC (permalink / raw)
To: JohnsonCheng; +Cc: linuxppc-embedded
On Sat, 23 Jul 2005, JohnsonCheng wrote:
> Yes. You are right. It's design by myself.
> But I meet a problem. If I have three configuration files, A.conf, B.conf
> and C.conf, then I hope save them in one of partitions of MTD,
> 0x005C0000-0x10000000.
> Two questions:
> 1. How to build these configuration files into an image for U-boot with
> mkimage?
> 2. In kernel, how to get these data? I use "mount /dev/mtd4 /mnt", but it
> failed by block device required.
for this second issue, you might try mounting the block device, which
is probably called /dev/mtdblock4 or something similar.
rday
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-22 13:07 ` Wolfgang Denk
2005-08-23 3:12 ` JohnsonCheng
@ 2005-08-23 5:26 ` JohnsonCheng
1 sibling, 0 replies; 15+ messages in thread
From: JohnsonCheng @ 2005-08-23 5:26 UTC (permalink / raw)
To: 'Wolfgang Denk'; +Cc: linuxppc-embedded
When I want to turn on MTD with TQM8XXL, I can't find it in kernel 2.6.12.3.
I use "MTD\Mapping drivers for chip access\CFI Flash device in physical
memory map", it seems only one partition can be used.
Thanks,
Johnson Cheng
-----Original Message-----
From: linuxppc-embedded-bounces@ozlabs.org
[mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Wolfgang Denk
Sent: Monday, August 22, 2005 9:07 PM
To: JohnsonCheng
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Linux Kernel MTD question
In message <20050822104924.214ED429CB@denx.de> you wrote:
>
> How can I put the Environment variables or configurations in
> 0x00060000-0x00080000, or put User Data in 0x005C0000-0x1000000?
> Use U-boot command? Or....
It is up to you to define a memory map for your flash device(s) and
create appropriate partitions for this map in Linux (and probably in
U-Boot, too, using the new "mtdparts" command).
Then you can use standard commands in U-Boot (erase, cp) and in Linux
(erase_all, cp) to store any data you likein your flash.
It is *your* design. *You* must create it.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
The IQ of the group is the lowest IQ of a member of the group divided
by the number of people in the group.
_______________________________________________
Linuxppc-embedded mailing list
Linuxppc-embedded@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-embedded
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-23 3:24 ` Robert P. J. Day
@ 2005-08-23 5:31 ` JohnsonCheng
2005-08-23 19:16 ` Ricardo Scop
0 siblings, 1 reply; 15+ messages in thread
From: JohnsonCheng @ 2005-08-23 5:31 UTC (permalink / raw)
To: 'Robert P. J. Day'; +Cc: linuxppc-embedded
It doesn't work, too.
Error message: Invalid argument.
Thanks,
Johnson Cheng
-----Original Message-----
From: linuxppc-embedded-bounces@ozlabs.org
[mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Robert P. J. Day
Sent: Tuesday, August 23, 2005 11:24 AM
To: JohnsonCheng
Cc: linuxppc-embedded@ozlabs.org
Subject: RE: Linux Kernel MTD question
On Sat, 23 Jul 2005, JohnsonCheng wrote:
> Yes. You are right. It's design by myself.
> But I meet a problem. If I have three configuration files, A.conf, B.conf
> and C.conf, then I hope save them in one of partitions of MTD,
> 0x005C0000-0x10000000.
> Two questions:
> 1. How to build these configuration files into an image for U-boot with
> mkimage?
> 2. In kernel, how to get these data? I use "mount /dev/mtd4 /mnt", but it
> failed by block device required.
for this second issue, you might try mounting the block device, which
is probably called /dev/mtdblock4 or something similar.
rday
_______________________________________________
Linuxppc-embedded mailing list
Linuxppc-embedded@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-embedded
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Linux Kernel MTD question
[not found] <20050823053053.67D1A42AFE@denx.de>
@ 2005-08-23 8:59 ` Wolfgang Denk
0 siblings, 0 replies; 15+ messages in thread
From: Wolfgang Denk @ 2005-08-23 8:59 UTC (permalink / raw)
To: JohnsonCheng; +Cc: linuxppc-embedded
In message <20050823053053.67D1A42AFE@denx.de> you wrote:
> When I want to turn on MTD with TQM8XXL, I can't find it in kernel 2.6.12.3.
> I use "MTD\Mapping drivers for chip access\CFI Flash device in physical
> memory map", it seems only one partition can be used.
There is no working support for TQM8xxL in the 2.6 kernel tree yet.
Please use the 2.4 kernel from our CVS server instead.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
"And they told us, what they wanted... Was a sound that could kill
some-one, from a distance." - Kate Bush
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Linux Kernel MTD question
2005-08-23 5:31 ` JohnsonCheng
@ 2005-08-23 19:16 ` Ricardo Scop
2005-08-24 5:02 ` JohnsonCheng
0 siblings, 1 reply; 15+ messages in thread
From: Ricardo Scop @ 2005-08-23 19:16 UTC (permalink / raw)
To: JohnsonCheng, 'Robert P. J. Day'; +Cc: linuxppc-embedded
Hi Johnson,
On Tuesday 23 August 2005 02:31, JohnsonCheng wrote:
> It doesn't work, too.
> Error message: Invalid argument.
Well, do you have an mtdblock4 entry in /dev?
Also, you should specify your filesystem type to mount, like in:
mount -t jffs2 /dev/mtdblock4 /mnt
BTW, -t jffs2 is just an example.
HTH,
-Scop.
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-23 19:16 ` Ricardo Scop
@ 2005-08-24 5:02 ` JohnsonCheng
2005-08-24 8:49 ` Alex Zeffertt
0 siblings, 1 reply; 15+ messages in thread
From: JohnsonCheng @ 2005-08-24 5:02 UTC (permalink / raw)
To: 'Ricardo Scop', 'Robert P. J. Day'; +Cc: linuxppc-embedded
Dear Ricardo and Wolfgang,
Very thanks for your kindly support.
I am sorry I made a mistake.
Before you mount /dev/mtdblock4, you have to use mke2fs to format it.
Now I think my MTD function is almost ready, except write.
When I run "dd if=/dev/mtd1 of=kernel.img", it's OK.
But when I run "dd if=kernel.img of=/dev/mtd1", it's failed. No error
message printed, and the process time is shortly, cause Bad CRC.
Thanks,
Johnson Cheng
-----Original Message-----
From: linuxppc-embedded-bounces@ozlabs.org
[mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Ricardo Scop
Sent: Wednesday, August 24, 2005 3:17 AM
To: JohnsonCheng; 'Robert P. J. Day'
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Linux Kernel MTD question
Hi Johnson,
On Tuesday 23 August 2005 02:31, JohnsonCheng wrote:
> It doesn't work, too.
> Error message: Invalid argument.
Well, do you have an mtdblock4 entry in /dev?
Also, you should specify your filesystem type to mount, like in:
mount -t jffs2 /dev/mtdblock4 /mnt
BTW, -t jffs2 is just an example.
HTH,
-Scop.
_______________________________________________
Linuxppc-embedded mailing list
Linuxppc-embedded@ozlabs.org
https://ozlabs.org/mailman/listinfo/linuxppc-embedded
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: Linux Kernel MTD question
2005-08-24 5:02 ` JohnsonCheng
@ 2005-08-24 8:49 ` Alex Zeffertt
2005-08-25 2:59 ` JohnsonCheng
0 siblings, 1 reply; 15+ messages in thread
From: Alex Zeffertt @ 2005-08-24 8:49 UTC (permalink / raw)
To: JohnsonCheng; +Cc: linuxppc-embedded
Before doing a write to /dev/mtd1 try running
~# eraseall /dev/mtd1
(eraseall is from the mtd-utils package.)
Alex
On Wed, 24 Aug 2005 13:02:31 +0800
"JohnsonCheng" <johnsoncheng@qnap.com.tw> wrote:
> Dear Ricardo and Wolfgang,
>
> Very thanks for your kindly support.
> I am sorry I made a mistake.
> Before you mount /dev/mtdblock4, you have to use mke2fs to format it.
> Now I think my MTD function is almost ready, except write.
> When I run "dd if=/dev/mtd1 of=kernel.img", it's OK.
> But when I run "dd if=kernel.img of=/dev/mtd1", it's failed. No error
> message printed, and the process time is shortly, cause Bad CRC.
>
> Thanks,
> Johnson Cheng
>
> -----Original Message-----
> From: linuxppc-embedded-bounces@ozlabs.org
> [mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Ricardo Scop
> Sent: Wednesday, August 24, 2005 3:17 AM
> To: JohnsonCheng; 'Robert P. J. Day'
> Cc: linuxppc-embedded@ozlabs.org
> Subject: Re: Linux Kernel MTD question
>
> Hi Johnson,
>
> On Tuesday 23 August 2005 02:31, JohnsonCheng wrote:
> > It doesn't work, too.
> > Error message: Invalid argument.
> Well, do you have an mtdblock4 entry in /dev?
>
> Also, you should specify your filesystem type to mount, like in:
>
> mount -t jffs2 /dev/mtdblock4 /mnt
>
> BTW, -t jffs2 is just an example.
>
> HTH,
>
> -Scop.
>
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
>
>
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
^ permalink raw reply [flat|nested] 15+ messages in thread
* RE: Linux Kernel MTD question
2005-08-24 8:49 ` Alex Zeffertt
@ 2005-08-25 2:59 ` JohnsonCheng
0 siblings, 0 replies; 15+ messages in thread
From: JohnsonCheng @ 2005-08-25 2:59 UTC (permalink / raw)
To: 'Alex Zeffertt'; +Cc: linuxppc-embedded
Good idea. It works well.
The latest version of mtd utility for erase flash is flash_eraseall.
Thank you very much,
Johnson Cheng
-----Original Message-----
From: Alex Zeffertt [mailto:ajz@cambridgebroadband.com]
Sent: Wednesday, August 24, 2005 4:50 PM
To: JohnsonCheng
Cc: linuxppc-embedded@ozlabs.org
Subject: Re: Linux Kernel MTD question
Before doing a write to /dev/mtd1 try running
~# eraseall /dev/mtd1
(eraseall is from the mtd-utils package.)
Alex
On Wed, 24 Aug 2005 13:02:31 +0800
"JohnsonCheng" <johnsoncheng@qnap.com.tw> wrote:
> Dear Ricardo and Wolfgang,
>
> Very thanks for your kindly support.
> I am sorry I made a mistake.
> Before you mount /dev/mtdblock4, you have to use mke2fs to format it.
> Now I think my MTD function is almost ready, except write.
> When I run "dd if=/dev/mtd1 of=kernel.img", it's OK.
> But when I run "dd if=kernel.img of=/dev/mtd1", it's failed. No error
> message printed, and the process time is shortly, cause Bad CRC.
>
> Thanks,
> Johnson Cheng
>
> -----Original Message-----
> From: linuxppc-embedded-bounces@ozlabs.org
> [mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Ricardo Scop
> Sent: Wednesday, August 24, 2005 3:17 AM
> To: JohnsonCheng; 'Robert P. J. Day'
> Cc: linuxppc-embedded@ozlabs.org
> Subject: Re: Linux Kernel MTD question
>
> Hi Johnson,
>
> On Tuesday 23 August 2005 02:31, JohnsonCheng wrote:
> > It doesn't work, too.
> > Error message: Invalid argument.
> Well, do you have an mtdblock4 entry in /dev?
>
> Also, you should specify your filesystem type to mount, like in:
>
> mount -t jffs2 /dev/mtdblock4 /mnt
>
> BTW, -t jffs2 is just an example.
>
> HTH,
>
> -Scop.
>
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
>
>
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2005-08-25 2:59 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20050822030032.4917442C7E@denx.de>
2005-08-22 8:17 ` Linux Kernel MTD question Wolfgang Denk
2005-08-22 10:46 ` JohnsonCheng
[not found] <20050823053053.67D1A42AFE@denx.de>
2005-08-23 8:59 ` Wolfgang Denk
[not found] <20050822104924.214ED429CB@denx.de>
2005-08-22 13:07 ` Wolfgang Denk
2005-08-23 3:12 ` JohnsonCheng
2005-08-23 3:24 ` Robert P. J. Day
2005-08-23 5:31 ` JohnsonCheng
2005-08-23 19:16 ` Ricardo Scop
2005-08-24 5:02 ` JohnsonCheng
2005-08-24 8:49 ` Alex Zeffertt
2005-08-25 2:59 ` JohnsonCheng
2005-08-23 5:26 ` JohnsonCheng
2005-08-21 8:02 JohnsonCheng
2005-08-21 20:58 ` Wolfgang Denk
2005-08-22 2:56 ` JohnsonCheng
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 NNTP newsgroup(s).