2008 BPM Microsystems Confidential and Proprietary
Slide 2
Factory Preprogramming Solutions for NAND Flash Devices Dragon
Zhang
Slide 3
2008 BPM Microsystems Confidential and Proprietary What Is
Factory Preprogramming? Factory preprogramming is the writing of
initial data content into a non-volatile memory device. The memory
devices are usually virgin blanks straight from the semiconductor
distributor. At the very least, factory preprogramming provides the
bootstrapping necessary for the embedded system.
Slide 4
2008 BPM Microsystems Confidential and Proprietary Example
Preprogrammed Content Store-and-download SnD boot loader OS, System
Firmware Preloaded user content: Applications Pictures, Music,
Movies GPS Maps Unique / Dynamic content: Serial Numbers Network
addresses Encryption keys
Slide 5
2008 BPM Microsystems Confidential and Proprietary The Hidden
Added Cost Per Device Devices per Hour (DPH) The number of
successfully preprogrammed devices that a process can produce in an
hour. Aka Units per Hour. Outsourced Programming Fees Additional
charge to preprogram your data. Price depends on DPH and volume.
$0.25 - $1.00 per device typical range. Production beat rate
Slide 6
2008 BPM Microsystems Confidential and Proprietary Factory
Preprogramming Methods Offline / In-Socket In-house Outsourced
Manual Automated (Pick & Place) ISP / ICP Via Connected Target
System Via Test Port (eg JTAG) Via In-circuit test (ICT)
system
Slide 7
2008 BPM Microsystems Confidential and Proprietary Offline
In-Socket Performance Advantage Isolated Device Concurrency + Gang
Scalable Eliminate failures before solder process Easy to
outsource. Or, handle in-house.
Slide 8
2008 BPM Microsystems Confidential and Proprietary In-Circuit /
In-System Its how the design engineers did it. But youll need more
than the DevKit. Can you reuse your embedded code? 40+ minute
programming times are common
Slide 9
2008 BPM Microsystems Confidential and Proprietary This Sounds
Like Productions Problem Whats all of this have to do with
designing flash-based products? Your NAND driver choices will have
an impact on the manufacturability of your product. Your decisions
on NAND control during the design phase can mean the difference
between turn-key factory preprogramming and weeks of delays. It
really happens!
Slide 10
2008 BPM Microsystems Confidential and Proprietary
Preprogramming Considerations - NAND Flash Type Is it raw SLC, raw
MLC, or managed? If managed, is it consumer card or SMT packaged?
Standard or proprietary interface? Huge Device Densities Data
Pattern file logistics (Gigabytes) Program Disturbs Data Output
Data Input, but not always an error! Bad Block Management
Slide 11
2008 BPM Microsystems Confidential and Proprietary Raw NAND
Types 1.Single-Level Cell (SLC) Fastest NAND Flash No disturbs
during preprogramming 2.Multi-Level Cell (MLC) More memory, but
less speed, less intrinsic reliability 1-bit disturbs certain,
2-bit likely Preprogramming verification must tolerate a specified
number of bit errors or yield will be 0% Raw NAND requires an extra
algorithm plug-in for Bad Block Management
Slide 12
2008 BPM Microsystems Confidential and Proprietary Managed NAND
Types 1.Consumer Card CF, SD, MMC, MS 2.Surface Mount Package
Embedded eMMC, moviNAND, iNAND Easy to preprogram. No extra
algorithms necessary!
Slide 13
2008 BPM Microsystems Confidential and Proprietary Performance
Comparisons
Slide 14
2008 BPM Microsystems Confidential and Proprietary What is Bad
Block Management (BBM)? NAND ships from factory with bad blocks,
and a scheme must be employed to deal with that. The system
preprogramming the NAND must do it exactly the same as the target
system. Its the biggest challenge to ramping up volume
preprogramming of NAND. Plan ahead at design time and it wont be a
problem at production time.
Slide 15
2008 BPM Microsystems Confidential and Proprietary Raw NAND
Requires 2 Algorithms
Slide 16
2008 BPM Microsystems Confidential and Proprietary Who
specifies the BBM Algorithm? The provider of the FFS software that
you integrated? Some undocumented open-source FFS software? The FFS
or driver software that you wrote yourself? The MCU/chipset vendor?
The NAND Flash vendor? The hardware IP provider? Some combination
of the above? The most common answer: I dont know.
Slide 17
2008 BPM Microsystems Confidential and Proprietary Six BBM
Preprogramming Elements 1.Bad Block Replacement Strategy
2.Partitioning 3.Error Correction Codes (ECC) 4.Spare Area
Placement 5.Free Good Block Formatting 6.Dynamic Metadata
Slide 18
2008 BPM Microsystems Confidential and Proprietary Skip Bad
Blocks When a bad block is encountered, simply skip ahead to the
next good block. No tables, no tags. Simple Suitable for
preprogramming and WORM applications. Most FFSs will require more
sophistication at runtime. Good Bad
Slide 19
2008 BPM Microsystems Confidential and Proprietary Reserve
Block Area (RBA) A portion of the flash memory is set aside to
replace bad blocks. When a bad block is encountered, redirect the
data to a replacement block in the RBA, then resume. Usually
requires a mapping data structure. Good Bad Good RBA @ End of
Device
Slide 20
2008 BPM Microsystems Confidential and Proprietary Partitioning
for SBB Partitioning is required to prevent regions from
encroaching on adjacent regions when bad blocks occur. Allows you
to guarantee a fixed starting block for IPL, bootloaders, FFS
mounts, etc. Block 0 1 1 block 2 blocks 10 blocks 6 blocks 2017
blocks 2 4 5 14 24 25 30 2047 Bootstrap Bootloader OS File System
Padding Cleanmarkers
Slide 21
2008 BPM Microsystems Confidential and Proprietary Partitioning
for RBA Defines the User Block Area and Reserve Block Area
allocations. Bad blocks dont disrupt the physical location of data
on good blocks. 2047 2046 Block 0 1638 blocks 2 blocks 408 blocks
1637 1638 Metadata, BB Table User Block Area 2045 Reserve Block
Area
Slide 22
2008 BPM Microsystems Confidential and Proprietary Specifying
Partitioning Specify the details of your NAND partitioning to
manufacturing or programming center. Or, use tools that emit
partition tables and furnish the file.
Slide 23
2008 BPM Microsystems Confidential and Proprietary ECC
Calculated values that allow for detection and correction of bit
errors in the original data. Preprogrammer must write the ECCs
exactly as the target system expects. Definitively specifying an
ECC algorithm: Hamming, Reed-Solomon, BCH Additional parameters,
sub-pages, hybrid schemes Most embedded system designers cannot
fully specify the ECC used in their NAND control system. ECCs
should be pre-encoded for static data pattern content to boost
DPH.
Slide 24
2008 BPM Microsystems Confidential and Proprietary Spare Area
Placement Aka Out-Of-Band (OOB) Area How are the ECC bytes
arranged? Bad Block Marker(s) Other metadata 2048 64 BB Marker FFS
MetadataECC0ECC1ECC2ECC3ECC4ECC5ECC6ECC7 MainSpare...
Slide 25
2008 BPM Microsystems Confidential and Proprietary Free Good
Block Formatting What to fill the unused good blocks with. For
every bad block on the device, one block of FGBF will be discarded.
Common Examples: 0xFF / Blank Padding Completely blank pages are
not programmed, just blank checked. This is the most common FGBF.
JFFS2 Cleanmarkers
Slide 26
2008 BPM Microsystems Confidential and Proprietary Dynamic
Metadata Additional computed data written to the device based on
the individual DUT. Includes information such as: Filesystem
headers, erase counts, logical-physical mappings, etc. Customized
bad block tables Other unanticipated crazy stuff
Slide 27
2008 BPM Microsystems Confidential and Proprietary
Confidentiality and IP Issues Who owns the IP of your BBM
algorithm? Many hardware and software vendors will not disclose to
you the details of their BBM and/or ECC algorithm. Dont delay your
product launch while lawyers execute NDAs. It really happens!
Slide 28
2008 BPM Microsystems Confidential and Proprietary Universal
BBM for Preprogramming 1.BBR: Skip Bad Blocks 2.Partitioning: One
or more partitions defined. 3.ECCs: Pre-computed in the data
pattern. 4.SAP: All Spare Area bytes in the data pattern. 5.FGBF:
All unused block formatting or padding (FFh) in the data pattern.
6.Dynamic Metadata: None! Many commercial, open-source, and
proprietary BBMs adhere to this.
Slide 29
2008 BPM Microsystems Confidential and Proprietary De facto
Image File Conventions Flat binary file. 1:1 mapping to devices
physical blocks, Main+Spare for each page. Contains full page data,
all spare area content, including ECCs, needed for board bring-up.
Includes all Free Good Block Formatting, even if its just blank
padding.
Slide 30
2008 BPM Microsystems Confidential and Proprietary NAND Drivers
& FFS Considerations Open-Source Ex: Linux JFFS2, UBI
Commercial off-the-shelf (COTS) Software Ex: FlashFX, TargetFFS,
CMX-FFS Hardware Controller + Software Ex: MSM7201, OMAP3530,
Databahn+Spectra One-off / Roll-your-own Determine during the
design phase preprogramming support for your FFS.
Slide 31
2008 BPM Microsystems Confidential and Proprietary BBM
Algorithm Plug-ins Generally any BBM algorithm can be combined in
the field with any Raw NAND device algorithm. Part number changes
are no problem. But beware of one-off or esoteric BBM schemes! If
it cant be coded using the defined abstractions, the alternative is
to produce a combined BBM+Device algorithm. Higher development
costs Longer lead times Cant change the part number in the
field.
Slide 32
2008 BPM Microsystems Confidential and Proprietary Bit Error
Rate Tolerance for Raw MLC Before MLC, disturbs were a non-issue
with factory- fresh devices. Now with MLC, programming a page will
corrupt some bits in another page of the same block. Normally this
is a verify failure. But with MLC youll get 0% yield. The
preprogrammer must tolerate a certain number of incorrect bits per
page during verify. Specify the BERT in bits per page for your
application!
Slide 33
2008 BPM Microsystems Confidential and Proprietary Design Tips
Fully specify BBM to production: Six preprogramming elements BERT
for Raw MLC Balance yield vs. waste for bad block allowances.
Deliver standard image file. If you are designing an FFS, support
the use of Skip Bad Blocks Compatible factory preprogramming. FFS
vendors can help their customers and increase their products
adoptability by adhering to this rule!
Slide 34
2008 BPM Microsystems Confidential and Proprietary Resources
Whitepaper: TODO http://flashstream.bpmmicro.com
http://www.bpmmicro.com/pdf/FMS2008- WhiteT1BSlides.pdf
Slide 35
2008 BPM Microsystems Confidential and Proprietary
Questions?