Symbian3/PDK/Source/GUID-AFFC4002-3A06-5458-A4D9-1E0AEDB8C534.dita
author Dominic Pinkman <Dominic.Pinkman@Nokia.com>
Thu, 11 Mar 2010 18:02:22 +0000
changeset 3 46218c8b8afa
parent 1 25a17d01db0c
child 5 f345bda72bc4
permissions -rw-r--r--
week 10 bug fix submission (SF PDK version): Bug 1892, Bug 1897, Bug 1319. Also 3 or 4 documents were found to contain code blocks with SFL, which has been fixed. Partial fix for broken links, links to Forum Nokia, and the 'Symbian platform' terminology issues.

<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
<!-- This component and the accompanying materials are made available under the terms of the License 
"Eclipse Public License v1.0" which accompanies this distribution, 
and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
<!-- Initial Contributors:
    Nokia Corporation - initial contribution.
Contributors: 
-->
<!DOCTYPE concept
  PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
<concept id="GUID-AFFC4002-3A06-5458-A4D9-1E0AEDB8C534" xml:lang="en"><title>FAT
File System Guide</title><shortdesc>Describes the FAT (File Allocation Table) file system that was
originally devised for MS-DOS. </shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
<section id="GUID-32E85FBB-B762-5BF1-9D13-90B3735629ED"><title>Introduction</title> <p>FAT
file system was originally used by IBM PCs and is an industrial standard for
file systems, supported by all operating systems that execute on PCs. Symbian
OS FAT file system implementation supports FAT12, FAT16 and FAT32. FAT file
system is used for storing user data on NAND Flash, internal RAM drives and
removable media such as SD cards and MMC cards. </p> </section>
<section id="GUID-EC9D2DDC-EC74-43E7-A8A2-B4EE4B0F42C5"><title>Background information</title> <p>On a FAT file system , the
smallest size of data storage that can be allocated to a file called a cluster.
The FAT structure is used to track how clusters are allocated to each file.
The FAT table stores the address of the clusters. The cluster size is different
on different media. </p> <p>Over the years this file system has been enhanced
to keep track of increasing drive sizes. The number after the FAT relates
to the size of the entry in the FAT data structure, for example FAT12 uses
12 bit entries. </p> </section>
<section id="GUID-E9826F50-A205-475D-995B-679412A2CA73"><title>FAT features</title> <p>FAT provides the following features: </p> <ul>
<li id="GUID-8DAD60FA-8793-5B1A-A3EC-10108210CC67"><p>The industrial standard
for filing systems on PCs. </p> </li>
<li id="GUID-5254D046-DD0D-5157-80C6-B1CEA9927038"><p>Used for user storage. </p> </li>
<li id="GUID-272D6E2A-6441-5BE2-A1BF-196B0E992E2A"><p>There is a rugged FAT
system that can cope with the loss of power during a write operation. </p> </li>
<li id="GUID-E2004F06-9421-5E75-A969-210AD9430422"><p>Used on a wide variety
of media such as NAND Flash, internal RAM drives and removable media like
SD cards and MMC cards. </p> </li>
<li id="GUID-4D649750-FBAD-57E3-9D64-9DD0EAB26EF2"><p>There is a maximum upper
limit for the size of a drive, which has been increased in FAT32 </p> </li>
</ul> <p>When files are written or deleted from the media, the files can be
scattered over the media known as fragmentation. The fragmentation results
in slower access times of the files. </p> </section>
<section id="GUID-266ACC2C-DEE2-51E0-915B-DBB75AA9BEA8"><title>Leaf Directory
Name Cache</title> <p>Leaf directory name refers to the parent directory path
of a file or a folder. For example the leaf directory of a file <filepath>somefile.txt</filepath> in
the path <filepath>C:\1\2\3\4\5\6\somefile.txt</filepath> is <filepath>C:\1\2\3\4\5\6\</filepath>.
Each leaf directory name cache entry contains the following information: </p> <ul>
<li id="GUID-0242CD6B-88DC-5C0D-8425-3CC2867793E8"><p>Full path of the leaf
directory </p> </li>
<li id="GUID-F7DE41A7-0625-5124-8005-2A458782CCAA"><p>Starting cluster number </p> </li>
<li id="GUID-DE2C1348-9C0C-54FB-8683-FDB7FB061179"><p>Most recently used entry
position </p> </li>
</ul> <p>To perform any file operations such as read, write or update the
file must be first located. The leaf directory name cache improves the performance
of locating a file in deeply nested directories. The number of entries that
can be cached is configured in the <filepath>estart.txt</filepath> file. See <xref href="GUID-DC0BF2A3-613B-595C-BF47-07F29E2A7893.dita">Leaf Directory Name Cache
Configuration Tutorial</xref>, for more details. </p> <p> </p> </section>
<section id="GUID-86BEEEF5-F4F0-50AD-AF29-0A0277455BDB"><title> Directory
Cache</title> <p>A directory is a file that contains a list of files and directory
names. The list items are called directory entries. Each directory entry contains
the filename, size of the file, starting cluster of the file and other metadata
information. The maximum size of a directory entry is 32 bytes. Directory
cache is used to store the directory entries. In the older versions of Symbian platform,
the directory cache was implemented as a fixed array. The new directory cache
is variable and allows the device creators to customise with a dynamic range. </p> <p>The
configuration of directory cache specifies the size of the directory cache
dynamically. The size of a directory cache depends on the available system
memory. The dynamic range can be configured in the <filepath>estart.txt</filepath> file.
See <xref href="GUID-3D8B134E-3C2F-5BAF-82AB-0AB786A5D22D.dita">Dynamic Directory
Cache Configuration Tutorial</xref>, for more information. The global cache
memory manager allocates the memory to the different cache on each drive. </p> </section>
<section id="GUID-7675348A-9D74-54DB-A09A-0537AD4D6CA5"><title>Global Cache
Memory Manager</title> <p>The global cache memory manager is introduced to
dynamically manage the cache memory on different drives. The global cache
memory is configured to reserve the address space required by different cache
memories. The <filepath>estart.txt</filepath> file is used to configure the
global cache memory manager. There are two parameters: </p> <ul>
<li id="GUID-3E196DC8-238F-5CE1-AC5E-1B74BDAD09B9"><p> <codeph>GlobalCacheMemorySize</codeph> parameter
specifies the overall memory available to various cache. The parameter is
specified in kilobytes and the recommended value is 32768. The maximum value
depends on the sum of maximum size required by cache on each drive. </p> </li>
<li id="GUID-2B3475BE-8AAD-580D-A409-4CBD5C223E91"><p> <codeph>LowMemoryThreshold</codeph> specifies
the percentage of RAM that should be reserved for the system. When the memory
on RAM reaches the threshold value, the dynamic memory growth is stopped.
The default value is 10% of RAM. </p> </li>
</ul> <p>The text below is the sample <filepath>estart.txt </filepath> entry
for the global cache memory manager. </p> <codeblock id="GUID-F365FA22-4E35-5FC0-B791-67CFCFF7BC70" xml:space="preserve">


[CacheMemory]
GlobalCacheMemorySize    32768
LowMemoryThreshold         10
</codeblock> <p>The maximum or the global cache memory reserves address space
but the actual memory allocation depends on the available system memory. </p> </section>
</conbody><related-links>
<link href="GUID-9E92EE30-F2E2-5F28-BB2A-391C09EC69D2.dita"><linktext>Using   
             ECom</linktext></link>
<link href="GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20.dita#GUID-F3BD37EC-0CCB-5859-908F-215E22C9FC20/GUID-143780ED-4A23-5E72-A923-F605172EC8B5">
<linktext>File Server</linktext></link>
</related-links></concept>