Patent ID: 8239619

Claim:
A method for operating a flash memory array, comprising: allocating a plurality of sectors of data cells having sector addresses in the flash memory array to store respective data structures, a data structure having a physical address in one of the plurality of sectors arranged to store N-bits of data and including an index field and a data field; initializing the data structure by erasing the index field and the data field; writing N-bits of data having a logical address that maps to said physical address in the data structure by programming a data cell storing a bit in the index field corresponding with a particular N-bit segment in the data field, and programming the particular N-bit segment in the data field of the data structure to store the N-bits of data; and writing N-bits of data having the same logical address again, in the data structure having said physical address, by programming a different bit in the index field of the data structure corresponding with a different N-bit segment in the data field, and programming the different N-bit segment, wherein the index field includes a pointer field storing a number M of bits in address order, and the data field includes the number M of N-bit segments in address order, wherein when a data cell storing a first bit is programmed and a remainder of the data cells remain erased in the pointer field, the pointer field points to a first one of the N-bit segments in address order, when a data cell or data cells storing the first bit and a second bit are programmed and a remainder of the data cells remain erased in the pointer field, the pointer field points to a second one of the N-bit segments in address order, and when all of the number M of bits in the pointer field are programmed, the pointer points to a last one of the N-bit segments in address order.