/drivers/mtd/tests/ |
H A D | mtd_test.h | 4 int mtdtest_scan_for_bad_eraseblocks(struct mtd_info *mtd, unsigned char *bbt, 6 int mtdtest_erase_good_eraseblocks(struct mtd_info *mtd, unsigned char *bbt,
|
H A D | speedtest.c | 46 static unsigned char *bbt; variable 248 bbt = kzalloc(ebcnt, GFP_KERNEL); 249 if (!bbt) 251 err = mtdtest_scan_for_bad_eraseblocks(mtd, bbt, 0, ebcnt); 255 if (!bbt[i]) 259 err = mtdtest_erase_good_eraseblocks(mtd, bbt, 0, ebcnt); 267 if (bbt[i]) 282 if (bbt[i]) 293 err = mtdtest_erase_good_eraseblocks(mtd, bbt, 0, ebcnt); 301 if (bbt[ [all...] |
H A D | mtd_test.c | 45 int mtdtest_scan_for_bad_eraseblocks(struct mtd_info *mtd, unsigned char *bbt, argument 55 bbt[i] = is_block_bad(mtd, eb + i) ? 1 : 0; 56 if (bbt[i]) 65 int mtdtest_erase_good_eraseblocks(struct mtd_info *mtd, unsigned char *bbt, argument 72 if (bbt[i])
|
H A D | pagetest.c | 44 static unsigned char *bbt; variable 70 for (i = 0; i < ebcnt && bbt[i]; ++i) 74 for (i = 0; i < ebcnt && bbt[ebcnt - i - 1]; ++i) 97 if (addr <= addrn - pgsize - pgsize && !bbt[ebnum + 1]) { 139 for (i = 0; i < ebcnt && bbt[i]; ++i) 143 for (i = 0; i < ebcnt && bbt[ebcnt - i - 1]; ++i) 211 for (i = 0; i < ebcnt && bbt[i]; ++i) { 217 while (ebnum2 && bbt[ebnum2]) 289 for (i = 0; i < ebcnt && bbt[i]; ++i) { 385 bbt [all...] |
H A D | stresstest.c | 47 static unsigned char *bbt; variable 63 if (bbt[eb]) 93 if (bbt[eb + 1]) { 118 if (bbt[eb + 1]) 209 bbt = kzalloc(ebcnt, GFP_KERNEL); 210 if (!bbt) 212 err = mtdtest_scan_for_bad_eraseblocks(mtd, bbt, 0, ebcnt); 230 kfree(bbt);
|
H A D | oobtest.c | 43 static unsigned char *bbt; variable 105 if (bbt[i]) 256 if (bbt[i]) 318 bbt = kzalloc(ebcnt, GFP_KERNEL); 319 if (!bbt) 322 err = mtdtest_scan_for_bad_eraseblocks(mtd, bbt, 0, ebcnt); 334 err = mtdtest_erase_good_eraseblocks(mtd, bbt, 0, ebcnt); 354 err = mtdtest_erase_good_eraseblocks(mtd, bbt, 0, ebcnt); 367 if (bbt[i]) 384 err = mtdtest_erase_good_eraseblocks(mtd, bbt, [all...] |
H A D | subpagetest.c | 42 static unsigned char *bbt; variable 265 if (bbt[i]) 327 bbt = kzalloc(ebcnt, GFP_KERNEL); 328 if (!bbt) 331 err = mtdtest_scan_for_bad_eraseblocks(mtd, bbt, 0, ebcnt); 335 err = mtdtest_erase_good_eraseblocks(mtd, bbt, 0, ebcnt); 342 if (bbt[i]) 356 if (bbt[i]) 367 err = mtdtest_erase_good_eraseblocks(mtd, bbt, 0, ebcnt); 379 if (bbt[ [all...] |
H A D | readtest.c | 41 static unsigned char *bbt; variable 173 bbt = kzalloc(ebcnt, GFP_KERNEL); 174 if (!bbt) 176 err = mtdtest_scan_for_bad_eraseblocks(mtd, bbt, 0, ebcnt); 185 if (bbt[i]) 205 kfree(bbt);
|
/drivers/mtd/onenand/ |
H A D | onenand_bbt.c | 104 bbm->bbt[i >> 3] |= 0x03 << (i & 0x6); 129 * The function creates a memory based bbt by scanning the device 154 res = (bbm->bbt[block >> 3] >> (block & 0x06)) & 0x03; 156 pr_debug("onenand_isbad_bbt: bbt info for offs 0x%08x: (block %d) 0x%02x\n", 190 bbm->bbt = kzalloc(len, GFP_KERNEL); 191 if (!bbm->bbt) 206 kfree(bbm->bbt); 207 bbm->bbt = NULL;
|
H A D | onenand_base.c | 1564 * onenand_bbt_read_oob - [MTD Interface] OneNAND read out-of-band for bbt scan 1569 * OneNAND read out-of-band data from the spare area for bbt scan 2227 * @param allowbbt 1, if its allowed to access the bbt area 2587 if (bbm->bbt) 2588 bbm->bbt[block >> 2] |= 0x01 << ((block & 0x03) << 1); 4127 kfree(bbm->bbt);
|
/drivers/mtd/nand/ |
H A D | nand_bbt.c | 51 * 10b: block is reserved (to protect the bbt area) 58 * - the space necessary for a bbt in FLASH does not exceed a block boundary 86 uint8_t entry = chip->bbt[block >> BBT_ENTRY_SHIFT]; 95 chip->bbt[block >> BBT_ENTRY_SHIFT] |= msk; 168 * @num: the number of bbt descriptors to read 169 * @td: the bbt describtion table 265 * that the bbt bits are in consecutive order. 389 * assume that the bbt bits are in consecutive order. 521 * NAND_BBT_PERCHIP is given, each chip is searched for a bbt, which contains 525 * The bbt iden [all...] |
H A D | nandsim.c | 112 static unsigned int bbt; variable 136 module_param(bbt, uint, 0400); 169 MODULE_PARM_DESC(bbt, "0 OOB, 1 BBT with marker in OOB, 2 BBT with marker in data area"); 2266 switch (bbt) { 2274 NS_ERR("bbt has to be 0..2\n");
|
H A D | docg4.c | 215 #define DOCG4_FACTORY_BBT_PAGE 16 /* page where read-only factory bbt lives */ 216 #define DOCG4_REDUNDANT_BBT_PAGE 24 /* page where redundant factory bbt lives */ 1016 * update the memory-based bbt accordingly. 1034 * If no memory-based bbt was created, exit. This will happen if module 1040 if (nand->bbt == NULL) /* no memory-based bbt */ 1045 * Whoops, an ecc failure ocurred reading the factory bbt. 1052 "The factory bbt could not be read!\n"); 1058 * Parse factory bbt and update memory-based bbt [all...] |
H A D | nand_base.c | 455 if (chip->bbt) { 498 if (!chip->bbt) 509 * @allowbbt: 1, if its allowed to access the bbt area 519 if (!chip->bbt) 2712 * @allowbbt: allow erasing the bbt area 4228 kfree(chip->bbt);
|
/drivers/mtd/devices/ |
H A D | docg3.h | 296 * @bbt: bad block table cache 311 u8 *bbt; member in struct:docg3
|
H A D | docg3.c | 1004 u_char *buf = docg3->bbt; 1044 is_good = docg3->bbt[block0 >> 3] & (1 << (block0 & 0x7)); 1893 docg3->bbt = kzalloc(bbt_nbpages * DOC_LAYOUT_PAGE_SIZE, GFP_KERNEL); 1894 if (!docg3->bbt) 1946 kfree(docg3->bbt);
|