Memory and File Systems

353 views

Published on

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
353
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
10
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Memory and File Systems

  1. 1. Memory CS423 Dick Steflik
  2. 2. DRAM <ul><li>Dynamic Random Access Memory </li></ul><ul><ul><li>each data bit is stored in a separate capacitive element in the Integrated Circuit </li></ul></ul><ul><ul><li>Because capacitors leak their charge the memory must be periodically refreshed, thus the name Dynamic or Volatile </li></ul></ul><ul><ul><li>requires one transistor and one capacitor per bit </li></ul></ul><ul><ul><ul><li>simple, allowing high packaging densities </li></ul></ul></ul><ul><ul><ul><li>refresh rate dependent on implementation </li></ul></ul></ul><ul><ul><ul><ul><li>8 usec – 64 msec </li></ul></ul></ul></ul><ul><ul><li>includes DDR and SDRAM </li></ul></ul>
  3. 3. SRAM <ul><li>Static Random Access Memory </li></ul><ul><ul><li>Static in the sense that it does not need refreshing like DRAM, but is still considered volatile (loses its memory when power is removed)‏ </li></ul></ul><ul><ul><li>requires six transistors (multi ported memory may require 8, 10 or more transistors per bit)‏ </li></ul></ul><ul><ul><li>lower packaging density than DRAM </li></ul></ul><ul><ul><li>easier to interface with than DRAM because of simplicity and no need to refresh </li></ul></ul>
  4. 4. ROM <ul><li>Read-only memory </li></ul><ul><ul><li>mask ROM – non-volatile, permanently programed in the manufacturing process </li></ul></ul><ul><ul><li>PROM – Programmable Read-Only Memory </li></ul></ul><ul><ul><ul><li>Programmable once then unalterable, non-volatile </li></ul></ul></ul><ul><ul><ul><li>essentially a fuse matrix in which programming is done by blowing the fuses </li></ul></ul></ul><ul><ul><li>EPROM – Erasable Programmable Read-Only Memory </li></ul></ul><ul><ul><ul><li>semi-permanent in that the memory can be erased (by exposing to ultrviolet light) and reprogrammed, considered to be non-volatile </li></ul></ul></ul><ul><ul><li>EEPROM – Electronically Erasable Programmable Read-only </li></ul></ul><ul><ul><ul><li>non-volatile, parallel and serial access. </li></ul></ul></ul><ul><ul><ul><li>serial access via SPI, I2C, 1-wire </li></ul></ul></ul>
  5. 5. Flash <ul><li>Not an Acronym, just a name </li></ul><ul><ul><li>stores one bit per cell, cells are floating gate MOSFETs </li></ul></ul><ul><li>two types, NAND and NOR </li></ul><ul><ul><li>NOR – used like traditional memory, execute-in-place memory (DRAM, SRAM) </li></ul></ul><ul><ul><li>NAND – accessed like a block device (disk), used for memory sticks, flash drived, MMC, CF </li></ul></ul><ul><ul><li>finite number of writes, unlimited reads </li></ul></ul><ul><ul><ul><li>need wear leveling and bad block management </li></ul></ul></ul>
  6. 6. CF <ul><li>Compact Flash </li></ul><ul><ul><li>mostly NAND based, interface is smaller than, but electrically identical to, the ATA interface. </li></ul></ul><ul><ul><ul><li>appears to the host device as if it were a hard disk. The CF device contains an ATA controller. </li></ul></ul></ul><ul><ul><ul><li>makes it easy to use CF to replace a small hard drive </li></ul></ul></ul><ul><ul><ul><li>used mostly in older digital cameras </li></ul></ul></ul><ul><ul><ul><li>convenient to use in ITX, mini-ITX systems that are IDE/ATA based </li></ul></ul></ul>
  7. 7. MMC <ul><li>MultiMedia card </li></ul><ul><ul><li>NAND technology developed by Siemans and SanDisk </li></ul></ul><ul><ul><li>been superseded by Secure Digital format </li></ul></ul>
  8. 8. SD, SDHC <ul><li>Secure Digital Card </li></ul><ul><ul><li>NAND Flash </li></ul></ul><ul><ul><li>most commonly found in digital camera equipment </li></ul></ul><ul><ul><li>typically formatted as FAT, FAT32 by manufacturer but can be reformatted to any file system (ext2, jffs, cram,yaffs) for embedded systems use </li></ul></ul><ul><ul><li>MMC card can be used in SD slot but not vice-versa </li></ul></ul>
  9. 9. JFFS <ul><li>Journaling Flash File System </li></ul><ul><ul><li>log-structured file system for use on NOR flash memory devices on the Linux operating system. It has been superseded by JFFS2 </li></ul></ul><ul><ul><li>enforces wear leveling by treating the flash device as a circular log </li></ul></ul><ul><ul><ul><li>At mount time, the file system driver must read the entire chain and then keep it in memory </li></ul></ul></ul><ul><ul><ul><li>The circular log design means all data in the filesystem is re-written, regardless of whether it is static or not. This generates many unnecessary erase cycles and reduces the life of the flash medium. </li></ul></ul></ul>
  10. 10. JFFS2 <ul><li>Journaling Flash File System (2)‏ </li></ul><ul><ul><li>includes support for NAND flash </li></ul></ul><ul><ul><li>better performance, JFFS treated the disk as a circular log. This generated a great deal of unnecessary I/O. The garbage collection algorithm in JFFS2 makes this mostly unnecessary. </li></ul></ul><ul><ul><li>supports compression </li></ul></ul><ul><ul><li>supports hard links </li></ul></ul><ul><ul><li>part of Linux kernel since 2.4.10 </li></ul></ul>
  11. 11. YAFFS <ul><li>Yet Another Flash File System </li></ul><ul><ul><li>designed specifically for NAND flash cards </li></ul></ul><ul><ul><li>log structured, used both with embedded OSs and systems with no OS. Simple OS interface </li></ul></ul>
  12. 12. Compressed File Systems <ul><li>FS decompresses data as it is retrieved and may or may not compress as data is put into storage </li></ul><ul><li>CramFS </li></ul><ul><li>e2compr </li></ul><ul><li>SquashFS </li></ul><ul><li>JFFS2 </li></ul>
  13. 13. CramFS <ul><li>read-only Linux file system </li></ul><ul><li>zlib-compressed one page at a time to allow random read access, files are compressed, meta-data is not </li></ul><ul><li>comes with a utility (mkcramfs) to pack files into new cramfs images. </li></ul><ul><li>often used for initrd images </li></ul>
  14. 14. e2compr <ul><li>set of patches for ext2 file system kernel driver to make it work with compression </li></ul><ul><li>not a new file system, makes ext2 work with both uncompressed and compressed data </li></ul><ul><li>meta data us left uncompressed (for safety)‏ </li></ul><ul><li>doesn't require a separate partition for compressed files </li></ul>
  15. 15. SquashFS <ul><li>Compressed read-only file system </li></ul><ul><li>uses gzip compression (LZMA being worked on)‏ </li></ul><ul><li>Live CDs </li></ul><ul><ul><li>Ubuntu, Fedora, Gentoo </li></ul></ul><ul><ul><li>often used with UnionFS to provide read/write environment for Live CDs </li></ul></ul><ul><ul><ul><li>SLAX, Debian Live, Mandiva </li></ul></ul></ul>
  16. 16. UnionFS <ul><li>allows several file systems to be mounted as a single file system </li></ul><ul><li>allows files and directories of separate file systems, to be transparently overlaid, forming a single coherent file system. </li></ul><ul><li>Contents of directories which have the same path within the merged branches will be seen together in a single merged directory, within the new, virtual filesystem. </li></ul><ul><li>In the case of a union of a read-only and a writable FS where an identical path is encountered the preference can be given to the writable path. </li></ul><ul><li>Example: Knoppix Live CD with a USB memorystick </li></ul>

×