public inbox for linux-mtd@lists.infradead.org
 help / color / mirror / Atom feed
* jffs2 on ubi volume
@ 2009-06-23  2:18 Manoj
  2009-06-24  0:46 ` Manoj
  0 siblings, 1 reply; 4+ messages in thread
From: Manoj @ 2009-06-23  2:18 UTC (permalink / raw)
  To: linux-mtd

Hi,

I would like to use JFFS2 on top of UBI. I have enabled
CONFIG_MTD_UBI_GLUEBI in kernel config.

I have been able to create an empty FS by doing:
> modprobe ubi mtd=1
> ubimkvol /dev/ubi0 -s 25MiB -N ubivol1
> mount -t jffs2  /dev/mtdb-nvdata /tmp/flash

I can read and write files to /tmp/flash.

How do I write a jffs2 filesystem image to a ubi volume? I tried
ubiupdatevol but I think I am not passing the right parameters.
Do I need to use ubinize to create the UBI image that can be then
programmed to the UBI volume?

Thanks for any help.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: jffs2 on ubi volume
  2009-06-23  2:18 Manoj
@ 2009-06-24  0:46 ` Manoj
  0 siblings, 0 replies; 4+ messages in thread
From: Manoj @ 2009-06-24  0:46 UTC (permalink / raw)
  To: linux-mtd

Answering my own question, I got it to work by creating a /dev/ubi0_1
device file and then using ubiupdatevol.

>./ubimkvol /dev/ubi0 -s25MiB -Nubivol1 -n1
> mknod /dev/ubi0_1 c 253 2
> ./ubiupdatevol /dev/ubi0_1 sum.jffs2.rootfs
> mkdir /tmp/flash
> mount -t jffs2 /dev/mtdb-nvdata /tmp/flash




On Mon, Jun 22, 2009 at 7:18 PM, Manoj<manoj23@gmail.com> wrote:
> Hi,
>
> I would like to use JFFS2 on top of UBI. I have enabled
> CONFIG_MTD_UBI_GLUEBI in kernel config.
>
> I have been able to create an empty FS by doing:
>> modprobe ubi mtd=1
>> ubimkvol /dev/ubi0 -s 25MiB -N ubivol1
>> mount -t jffs2  /dev/mtdb-nvdata /tmp/flash
>
> I can read and write files to /tmp/flash.
>
> How do I write a jffs2 filesystem image to a ubi volume? I tried
> ubiupdatevol but I think I am not passing the right parameters.
> Do I need to use ubinize to create the UBI image that can be then
> programmed to the UBI volume?
>
> Thanks for any help.
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* jffs2 on ubi volume
@ 2009-06-26  6:20 Thang Dao Duy
  2009-06-26  6:32 ` Artem Bityutskiy
  0 siblings, 1 reply; 4+ messages in thread
From: Thang Dao Duy @ 2009-06-26  6:20 UTC (permalink / raw)
  To: manoj23; +Cc: linux-mtd

manoj23@gmail.com wrote:

>Answering my own question, I got it to work by creating a /dev/ubi0_1
>device file and then using ubiupdatevol.

>>./ubimkvol /dev/ubi0 -s25MiB -Nubivol1 -n1
>> mknod /dev/ubi0_1 c 253 2
>> ./ubiupdatevol /dev/ubi0_1 sum.jffs2.rootfs
>> mkdir /tmp/flash


Command ubimkvol will create a device /dev/ubi0_1, so "mknod
/dev/ubi0_1 c 253 2" may be unnecessary.

manoj23@gmail.com wrote:

>> mount -t jffs2 /dev/mtdb-nvdata /tmp/flash

jffs2 file system does not work on UBI API, it works on MTD API. so we
cannot mount jffs2 on ubi volume. We can use ubifs on ubi volume:

mount -t ubifs ubi0_1 /mnt/

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: jffs2 on ubi volume
  2009-06-26  6:20 jffs2 on ubi volume Thang Dao Duy
@ 2009-06-26  6:32 ` Artem Bityutskiy
  0 siblings, 0 replies; 4+ messages in thread
From: Artem Bityutskiy @ 2009-06-26  6:32 UTC (permalink / raw)
  To: Thang Dao Duy; +Cc: manoj23, linux-mtd

On Fri, 2009-06-26 at 13:20 +0700, Thang Dao Duy wrote:
> manoj23@gmail.com wrote:
> 
> >Answering my own question, I got it to work by creating a /dev/ubi0_1
> >device file and then using ubiupdatevol.
> 
> >>./ubimkvol /dev/ubi0 -s25MiB -Nubivol1 -n1
> >> mknod /dev/ubi0_1 c 253 2
> >> ./ubiupdatevol /dev/ubi0_1 sum.jffs2.rootfs
> >> mkdir /tmp/flash
> 
> 
> Command ubimkvol will create a device /dev/ubi0_1, so "mknod
> /dev/ubi0_1 c 253 2" may be unnecessary.

No, not really. Udev will do this, not ubimkvol. And if you do not
have udev, the device node will not be created. But may be it would
be a good idea to teach ubimkvol doing this.
> manoj23@gmail.com wrote:
> 
> >> mount -t jffs2 /dev/mtdb-nvdata /tmp/flash
> 
> jffs2 file system does not work on UBI API, it works on MTD API. so we
> cannot mount jffs2 on ubi volume. We can use ubifs on ubi volume:
> 
> mount -t ubifs ubi0_1 /mnt/

Right, but you still may use jffs2 with ubi. We have the gluebi emulator
for this:

http://www.linux-mtd.infradead.org/faq/ubi.html#L_run_jffs2

-- 
Best regards,
Artem Bityutskiy (Битюцкий Артём)

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-06-26  6:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-06-26  6:20 jffs2 on ubi volume Thang Dao Duy
2009-06-26  6:32 ` Artem Bityutskiy
  -- strict thread matches above, loose matches on Subject: below --
2009-06-23  2:18 Manoj
2009-06-24  0:46 ` Manoj

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox