File system questions

Eugeny S. Mints emints at ru.mvista.com
Thu Sep 16 08:07:57 UTC 2004


Hi Alan!

Alan Cudmore wrote:
> I'm doing a little bit of research on File systems under RTEMS and I 
> have a couple of questions:
> 
> 1. It looks like the two supported file system types are IMFS and the 
> FAT file system. Does IMFS require a ram block device to operate, or 
> does it just operate on an area of RAM?

As far as I remember IMFS does not require a ram block device to operate 
and just uses area of RAM.

> 
> 2. Can the FAT file system be used on a RAM disk block device or is it 
> supposed to be used only on physical media such as a hard disk?

It is possible to use FAT fs on a RAM disk. To do so you need to add 
ramdisk device driver entry into device drivers table (this table is 
filled in at your application sources) and create valid FAT image on a 
ramdisk. Ram disk driver itself locates in
cpukit/libblock/src/ramdisk.c.

> 
> 3. Is there an example of how I can create a RAM disk block device, 
Please, see above.
> format a DOS FS on top of it, and mount it? 

I'm not sure whether a formatting tool for FAT fs to allow runtime 
formatting is included into current RTEMS sources but it seems to me I 
remember somebody worked on it - please, try to search mail archieve.
Anyway you can create a valid FAT fs on a ramdisk (in a file) with help 
say mtools in linux and download it into RAM. To mount anything it RTEMS 
mount command is used.
I aslo believe Victor Vengerov or I posted a ramdisk usage example to 
this list some time ago (I;m not sure whether it exists on rtems ftp 
site) - again, please try to search mail archieve.

>How about for an IMFS file 
> system?

You need just to configure IMFS and IMFS tree will be created at sturtup.
(as I remember you don't need to mount it).

A collection of examples is available at rtems ftp site - 
ftp.rtems.com:/pub/rtems/snapshots/examples* . As I remember there is 
IMFS usage example.

Best wishes,
			Eugeny






More information about the users mailing list