Студопедия

КАТЕГОРИИ:

АстрономияБиологияГеографияДругие языкиДругоеИнформатикаИсторияКультураЛитератураЛогикаМатематикаМедицинаМеханикаОбразованиеОхрана трудаПедагогикаПолитикаПравоПсихологияРиторикаСоциологияСпортСтроительствоТехнологияФизикаФилософияФинансыХимияЧерчениеЭкологияЭкономикаЭлектроника


Page Layout Structure




The page layout structure is defined in the file File_Config.h as follows:

typedef struct { U8 Pos_LSN; /* LSN position */ U8 Pos_COR; /* Data in page corrupted marker */ U8 Pos_BBM; /* Bad Block marker position */ U8 Pos_ECC; /* First byte of ECC */ U16 SectInc; /* Column increment till next sector */ U16 SpareOfs; /* Spare area offset from beginning */ /* of the page */ U16 SpareInc; /* Column increment till next spare */} NAND_PG_LAY;

This structure contains basic configuration info:

  • Pos_LSN
    Position in spare area, where logical sector number (LSN) is placed. Usually, this is the first byte of spare, therefore Pos_LSN has value zero. LSN is a 32-bit value.
  • Pos_COR
    Position of data corrupted marker in spare area. Usually, this byte is the fifth byte of spare and Pos_COR has value four.
  • Pos_BBM
    Position of bad block marker (BBM) in spare area and is usually placed as the sixth byte of spare, Pos_BBM has value 5.
  • Pos_ECC
    Position of the first byte of Error Correction Code (ECC) bytes in the spare area. First ECC byte is default seventh byte of spare (Pos_ECC == 6). This value is used by flash translation layer only if ECC is encoded and decoded in software.
  • SectInc
    Provides information about user data sector locations within page. If page contains multiple sectors, first sector always starts at the beginning of the page (byte zero). Second sector starts at SectInc, third sector at SectInc + SectInc and so on.
  • SpareOfs
    Provides information about the location of the first spare area byte within page.
  • SpareInc
    Provides information about spare area locations within page. If page contains multiple sectors, first byte of the first spare area is determined by reading SpareOfs value. Location of the first byte of the second spare, can be determined by adding SpareInc value to the SpareOfs value.

The default page data layout (defined by SectInc, SpareOfs and SpareInc values) contains a Spare area after each sector.

Default 16-byte spare area data organization (defined by Pos_LSN, Pos_BBM and Pos_ECC values):


Поделиться:

Дата добавления: 2015-09-15; просмотров: 71; Мы поможем в написании вашей работы!; Нарушение авторских прав





lektsii.com - Лекции.Ком - 2014-2024 год. (0.006 сек.) Все материалы представленные на сайте исключительно с целью ознакомления читателями и не преследуют коммерческих целей или нарушение авторских прав
Главная страница Случайная страница Контакты