* Two questions on mtds on x86 platform
@ 2003-02-06 14:43 Somashekara DM
2003-02-06 14:58 ` David Woodhouse
0 siblings, 1 reply; 3+ messages in thread
From: Somashekara DM @ 2003-02-06 14:43 UTC (permalink / raw)
To: linux-mtd
Hi,
We want to mount jffs2 on two mtd partitions as a part of our project.
Our platform is x86 - kernel version 2.4.13.
1. We are using mtdram ("Test driver using RAM") and blkmtd ("MTD
emulation using block device")
to create two mtd's. Our aim is to mount jffs2 on two different
mtds.
Using mtdram and blkmtd at the same time is not successful.
we could mount first mtd device (which ever we loaded first)
successfully but failed to mount second mtd.
mount is giving error as "mount: fs type jffs2 not supported by
kernel".
Here are the steps we have followed.
Step1 :
mknod /dev/mtd0 c 90 0
mknod /dev/mtd2 c 90 2
and
mknod /dev/mtdblock0 b 31 0
mknod /dev/mtdblock2 b 31 2
Step2 :
load mtd driver for RAM and hard disk using 'mtdram' and 'blkmtd'
respectively.
insmod mtdram
insmod blkmtd device=/dev/hda7
Step3 :
write jffs2 image on theses device
Step4 :
mount jffs2 file system on these mtd's as follows
mount -t jffs2 /dev/mtdblock0 /mnt/jffs2drive0 //successfully
mounted
mount -t jffs2 /dev/mtdblock2 /mnt/jffs2drive2 //this mount fails
error - "mount: fs type jffs2 not supported by kernel"
What is going wrong here? Is it possible to use mtdram and blkmtd at the
same time?
Can you give us the procedure for doing this?
2. Can we create multiple partitions on the 'mtdram'?
Can you give us the procedure for that?
--DMS
^ permalink raw reply [flat|nested] 3+ messages in thread* Two questions on mtds on x86 platform
2003-02-06 14:43 Two questions on mtds on x86 platform Somashekara DM
@ 2003-02-06 14:58 ` David Woodhouse
2007-03-14 12:31 ` Two questions on mtds on x86 platform - multiple mtdram MikeW
0 siblings, 1 reply; 3+ messages in thread
From: David Woodhouse @ 2003-02-06 14:58 UTC (permalink / raw)
To: linux-mtd
On Thu, 2003-02-06 at 14:43, Somashekara DM wrote:
> Hi,
>
> We want to mount jffs2 on two mtd partitions as a part of our project.
> Our platform is x86 - kernel version 2.4.13.
>
> 1. We are using mtdram ("Test driver using RAM") and blkmtd ("MTD
> emulation using block device")
> to create two mtd's. Our aim is to mount jffs2 on two different
> mtds.
OK. So you have two MTD devices listed in /proc/mtd?
> Here are the steps we have followed.
>
> Step1 :
> mknod /dev/mtd0 c 90 0
> mknod /dev/mtd2 c 90 2
This is incorrect. The MAKEDEV script in CVS is correct. The device
numbers for the character devices alternate between 'normal' and
read-only devices, as follows:
/dev/mtd0 c 90 0
/dev/mtdr0 c 90 1
/dev/mtd1 c 90 2
/dev/mtdr1 c 90 3
/dev/mtd2 c 90 4
/dev/mtdr2 c 90 5
So what you've called '/dev/mtd2' is in fact what _should_ be called
'/dev/mtd1', and is hence the second of the two MTD devices (In fact,
/dev/mtd2 would be a _third_ device, which does not exist in your
system).
> and
> mknod /dev/mtdblock0 b 31 0
> mknod /dev/mtdblock2 b 31 2
These are correct device numbers and names but as before, /dev/mtdblock2
refers to a third MTD device which does not exist in your system. Make
/dev/mtdblock1 (b 31 1) and use that.
> mount -t jffs2 /dev/mtdblock2 /mnt/jffs2drive2 //this mount fails
> error - "mount: fs type jffs2 not supported by kernel"
What it actually means is 'block device /dev/mtdblock2 does not exist'.
But mount(2) doesn't return sensible errors.
> 2. Can we create multiple partitions on the 'mtdram'?
> Can you give us the procedure for that?
No partitions, but you can load the mtdram module twice (with different
names) so that you get two devices.
--
dwmw2
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: Two questions on mtds on x86 platform - multiple mtdram
2003-02-06 14:58 ` David Woodhouse
@ 2007-03-14 12:31 ` MikeW
0 siblings, 0 replies; 3+ messages in thread
From: MikeW @ 2007-03-14 12:31 UTC (permalink / raw)
To: linux-mtd
David Woodhouse <dwmw2 <at> infradead.org> writes:
>
> On Thu, 2003-02-06 at 14:43, Somashekara DM wrote:
> > Hi,
> >
> > We want to mount jffs2 on two mtd partitions as a part of our project.
> > Our platform is x86 - kernel version 2.4.13.
> >
> > 1. We are using mtdram ("Test driver using RAM") and blkmtd ("MTD
> > emulation using block device")
> > to create two mtd's. Our aim is to mount jffs2 on two different
> > mtds.
>
> OK. So you have two MTD devices listed in /proc/mtd?
>
> > Here are the steps we have followed.
> >
> > Step1 :
> > mknod /dev/mtd0 c 90 0
> > mknod /dev/mtd2 c 90 2
>
> This is incorrect. The MAKEDEV script in CVS is correct. The device
> numbers for the character devices alternate between 'normal' and
> read-only devices, as follows:
>
> /dev/mtd0 c 90 0
> /dev/mtdr0 c 90 1
> /dev/mtd1 c 90 2
> /dev/mtdr1 c 90 3
> /dev/mtd2 c 90 4
> /dev/mtdr2 c 90 5
>
> So what you've called '/dev/mtd2' is in fact what _should_ be called
> '/dev/mtd1', and is hence the second of the two MTD devices (In fact,
> /dev/mtd2 would be a _third_ device, which does not exist in your
> system).
>
> > and
> > mknod /dev/mtdblock0 b 31 0
> > mknod /dev/mtdblock2 b 31 2
>
> These are correct device numbers and names but as before, /dev/mtdblock2
> refers to a third MTD device which does not exist in your system. Make
> /dev/mtdblock1 (b 31 1) and use that.
>
> > mount -t jffs2 /dev/mtdblock2 /mnt/jffs2drive2 //this mount fails
> > error - "mount: fs type jffs2 not supported by kernel"
>
> What it actually means is 'block device /dev/mtdblock2 does not exist'.
> But mount(2) doesn't return sensible errors.
>
> > 2. Can we create multiple partitions on the 'mtdram'?
> > Can you give us the procedure for that?
>
> No partitions, but you can load the mtdram module twice (with different
> names) so that you get two devices.
>
Does this mean that in order to create several mtd devices on mtdram,
I can just create several device nodes with different minor device numbers ?
If so, I presume this means that all devices must share the same
size and erasesize ?
Regards,
Mike
....gmane.padding........................................................
....gmane.padding........................................................
....gmane.padding........................................................
....gmane.padding........................................................
....gmane.padding........................................................
....gmane.padding........................................................
....gmane.padding........................................................
....gmane.padding........................................................
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-03-14 12:33 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-02-06 14:43 Two questions on mtds on x86 platform Somashekara DM
2003-02-06 14:58 ` David Woodhouse
2007-03-14 12:31 ` Two questions on mtds on x86 platform - multiple mtdram MikeW
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox