A Simple Flash File System For Embedded Space
A Simple Flash File System For Embedded Space Applications October 28, 2015 John Harwell jharwell@swri. org (210)-522 -5965 Benefiting government, industry and the public through innovative science and technology 10/28/15 1
Outline § Motivation And Purpose § File Systems Background § Target Environments § Interstellar File System (IFS) Overview § Next Steps 10/28/15 2
Motivation And Purpose § Many existing Flash file systems for FSW applications – Limited wear leveling – Do not intrinsically utilize supplemental non-volatile storage for file system metadata – Configurability § In-progress report of independent research to address these issues 10/28/15 3
Flash File System Hierarchy 10/28/15 4
File Systems on Flash Media § Concern: limited write/erase cycles (10 x deration) – Different write paradigm than magnetic media – Different superblock paradigm than magnetic media 10/28/15 5
An Example File System Transaction Written every transaction! § Writing two files in two directories 10/28/15 6
Target Environments Overview § FSW OSes – RTEMS – Vx. Works – Others § Integration via Virtual File System (VFS) layer – POSIX compliance § Stand alone 10/28/15 7
Flash File Systems in RTEMS § JFFS 2 port – Boot time scales with device size – Documentation suggests it does not provide ideal wear leveling § RFS (RTEMS File System) – Supports Flash via the Flash disk driver, but no built-in wear leveling § FAT – No wear leveling 10/28/15 8
Flash File Systems in Vx. Works § Licensing requirements § HRFS – High fault tolerance – Difficult to find description of features § True. FFS – Magnetic disk emulation (no wear leveling) § RT-11 (deprecated) – Primitive interface/features, high performance (no wear leveling) 10/28/15 9
Interstellar File System (IFS) Overview 10/28/15 10
IFS Configurability § “As simple as possible, but no simpler” § Dual APIs: – Direct access to IFS core – Access via VFS interface (in progress) § Exposes fine-grained configuration options – Maximum programmer flexibility – Maximum mission adaptability 10/28/15 11
IFS Storage Awareness § Non-volatile storage awareness/utilization – MRAM, EEPROM, etc – Fast boot times – Increased reliability – Significantly increased Flash utilization/lifetime Written every transaction! 10/28/15 12
IFS Integrity § Error/event reporting – Standard POSIX error codes – Configurable event logging (errors and normal operations) for later telemetry downlink § Stateless – Atomic transaction model (no buffered writes or FILE* handles) – Certain configurations do not require fsck() at all § No dynamic memory allocation 10/28/15 13
IFS Segment Compaction § Page per write unit – 4 KB vs 128 KB page for 1 byte write § Improves Flash utilization significantly § fsck() required if device driver does not support page read-modify-write § Reduces wear-leveling to approximate 10/28/15 14
IFS Garbage Collection § Configurable cleanliness threshold § Configurable, bounded execution time § Can be automatic or application driven 10/28/15 15
Next Steps § Finish POSIX compliance in the IFS core § Finish VFS layer bindings for RTEMS § Core improvements 10/28/15 16
Summary § Several Flash file systems available for RTEMS, Vx. Works, and others – Wear leveling offerings appear to be lacking – Are not MRAM/EEPROM aware (reliability, boot time concerns) – Limited configurability (sometimes not desirable) § IFS – “As simple as possible but not simpler” – MRAM/EEPROM aware – Configurable to provide ideal wear leveling, and/or eliminate the need for fsck() – Configurable garbage collection, segment compaction 10/28/15 17
A Simple Flash File System For Embedded Space Applications October 28, 2015 John Harwell jharwell@swri. org (210)-522 -5965 Benefiting government, industry and the public through innovative science and technology 10/28/15 18
- Slides: 18