Lines Matching full:oob
40 * - a 1 byte Hamming code stored in the OOB for each page
41 * - a 7 bytes BCH code stored in the OOB for each page
594 * reading OOB only or write status byte).
625 * It's in fact recv_ecc ^ calc_ecc, where recv_ecc was read from OOB
859 * @ops: the mtd oob structure
861 * Reads flash memory OOB area of pages.
889 doc_dbg("doc_read_oob(from=%lld, mode=%d, data=(%p:%zu), oob=(%p:%zu))\n", in doc_read_oob()
930 doc_dbg("OOB - INFO: %*phC\n", 7, oobbuf); in doc_read_oob()
931 doc_dbg("OOB - HAMMING: %02x\n", oobbuf[7]); in doc_read_oob()
932 doc_dbg("OOB - BCH_ECC: %*phC\n", 7, oobbuf + 8); in doc_read_oob()
933 doc_dbg("OOB - UNUSED: %02x\n", oobbuf[15]); in doc_read_oob()
1218 * @oob: buffer to get out of band bytes from (can be NULL if no OOB should be
1220 * @autoecc: if 0, all 16 bytes from OOB are taken, regardless of HW Hamming or
1223 * computations. Its value is not meaningfull is oob == NULL.
1226 * OOB data. The OOB ECC is automatically computed by the hardware Hamming and
1232 const u_char *oob, int autoecc) in doc_write_page() argument
1254 if (oob && autoecc) { in doc_write_page()
1255 doc_write_page_putbytes(docg3, DOC_LAYOUT_OOB_PAGEINFO_SZ, oob); in doc_write_page()
1257 oob += DOC_LAYOUT_OOB_UNUSED_OFS; in doc_write_page()
1269 doc_write_page_putbytes(docg3, DOC_LAYOUT_OOB_UNUSED_SZ, oob); in doc_write_page()
1271 if (oob && !autoecc) in doc_write_page()
1272 doc_write_page_putbytes(docg3, DOC_LAYOUT_OOB_SIZE, oob); in doc_write_page()
1293 * @ops: the oob operations
1295 * Returns 0 or 1 if success, -EINVAL if invalid oob mode
1316 * doc_fill_autooob - Fill a 16 bytes OOB from 8 non-ECC bytes
1317 * @dst: the target 16 bytes OOB buffer
1318 * @oobsrc: the source 8 bytes non-ECC OOB buffer
1328 * doc_backup_oob - Backup OOB into docg3 structure
1331 * @ops: the OOB size and buffer
1333 * As the docg3 should write a page with its OOB in one pass, and some userland
1334 * applications do write_oob() to setup the OOB and then write(), store the OOB
1336 * applications could store an OOB, and then write their pages (which will
1337 * result into one having its OOB corrupted).
1340 * the page data _and_ the OOB area.
1372 * @ops: the mtd oob structure
1374 * Either write OOB data into a temporary buffer, for the subsequent write
1375 * page. The provided OOB should be 16 bytes long. If a data buffer is provided
1377 * Or provide data without OOB, and then a all zeroed OOB will be used (ECC will
1390 u8 oob[DOC_LAYOUT_OOB_SIZE]; in doc_write_oob() local
1404 doc_dbg("doc_write_oob(from=%lld, mode=%d, data=(%p:%zu), oob=(%p:%zu))\n", in doc_write_oob()
1438 memset(oob, 0, sizeof(oob)); in doc_write_oob()
1440 memcpy(oob, docg3->oob_write_buf, DOC_LAYOUT_OOB_SIZE); in doc_write_oob()
1442 doc_fill_autooob(oob, oobbuf); in doc_write_oob()
1444 memcpy(oob, oobbuf, DOC_LAYOUT_OOB_SIZE); in doc_write_oob()
1445 ret = doc_write_page(docg3, ofs, buf, oob, autoecc); in doc_write_oob()