[ECOS] Help -- Creating a FAT Filesystem on a NOR Flash Device

Ramgopal Kota rkota@broadcom.com
Wed Sep 9 15:59:00 GMT 2009


I saw this in the fat readme.txt ..

There is currently just one test available for the FAT filesystem,
fileio1. This test will currently only run on the Linux synthetic
target and needs a special disk image. However, with some work it
should be possible to make this test run on other disk drivers, if the
image can be installed and the configury set appropriately.

What are the disk drivers required to run on NOR flash ?

Thanks & Regards,
Ramgopal Kota
-----Original Message-----
From: ecos-discuss-owner@ecos.sourceware.org [mailto:ecos-discuss-owner@ecos.sourceware.org] On Behalf Of Ramgopal Kota
Sent: Wednesday, September 09, 2009 9:05 PM
To: ecos-discuss@ecos.sourceware.org
Subject: [ECOS] Help -- Creating a FAT Filesystem on a NOR Flash Device

 Hi,

I am new to ecos development .. Please bear with me if these are very novice questions...

I am working on a MIPS Malta board with 16MB NOR Flash device.
I want to create a FAT Filesystem of 2MB size from an offset.

I pulled in the required packages for FAT FS and IO.
I created a device /dev/flash2 in the cdl file.

When I am doing a mount from my ecos application using ..
err = mount( "/dev/flash2/", "/", "fatfs" );
I am getting err as -1 ...

Do I have to use synthetic linux driver for this purpose as shown in the readme ? 
Currently flash is empty how to create a FATFS header so that mount will recognise ?
Is there a way to detect a FATFS at that device ? If it is not there can I create one all using application.

Ramgopal Kota
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
                cdl_component CYGDAT_IO_FLASH_BLOCK_DEVICE_NAME_2 {
                display       "Name of flash device 1 block device"
                flavor        data
                default_value { "\"/dev/flash2\"" }

            cdl_option CYGNUM_IO_FLASH_BLOCK_OFFSET_2 {
                display         "Start offset from flash base"
                flavor          data
                default_value   0x220000
                description     "
                    This gives the offset from the base of flash which this
                    block device corresponds to."
            }
            cdl_option CYGNUM_IO_FLASH_BLOCK_LENGTH_2 {
                display         "Length"
                flavor          data
                default_value   0x200000
                description     "
                    This gives the length of the region of flash given over
                    to this block device."
            }



-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss




--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list