'\" t .\" Title: search_bbt .\" Author: .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: May 2018 .\" Manual: Internal Functions Provided .\" Source: Kernel Hackers Manual 3.16.56 .\" Language: English .\" .TH "SEARCH_BBT" "9" "May 2018" "Kernel Hackers Manual 3\&.16\&" "Internal Functions Provided" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" search_bbt \- [GENERIC] scan the device for a specific bad block table .SH "SYNOPSIS" .HP \w'int\ search_bbt('u .BI "int search_bbt(struct\ mtd_info\ *\ " "mtd" ", uint8_t\ *\ " "buf" ", struct\ nand_bbt_descr\ *\ " "td" ");" .SH "ARGUMENTS" .PP \fImtd\fR .RS 4 MTD device structure .RE .PP \fIbuf\fR .RS 4 temporary buffer .RE .PP \fItd\fR .RS 4 descriptor for the bad block table .RE .SH "DESCRIPTION" .PP Read the bad block table by searching for a given ident pattern\&. Search is preformed either from the beginning up or from the end of the device downwards\&. The search starts always at the start of a block\&. If the option NAND_BBT_PERCHIP is given, each chip is searched for a bbt, which contains the bad block information of this chip\&. This is necessary to provide support for certain DOC devices\&. .PP The bbt ident pattern resides in the oob area of the first page in a block\&. .SH "AUTHOR" .PP \fBThomas Gleixner\fR <\&tglx@linutronix.de\&> .RS 4 Author. .RE .SH "COPYRIGHT" .br