Using a status indicator in a memory sub-system to detect an event
An indication of an initialization of power to a memory device is received. Responsive to receiving the indication of the initialization of power to the memory device, whether a status indicator associated with a written page of the memory device can be read is determined. Responsive to determining that the status indicator cannot be read, a programming of data to the memory device did not complete based on a prior loss of power to the memory device is determined.
1. A method comprising:
receiving an indication of an initialization of power to a memory device;
responsive to receiving the indication of the initialization of power to the memory device, determining whether a status indicator associated with a written page of the memory device can be read; and
responsive to determining that the status indicator cannot be read, determining that programming of data to the memory device did not complete based on a prior loss of power to the memory device.
2. The method of claim 1 , wherein the written page of the memory device is a last written page of a block of the memory device.
3. The method of claim 1 , further comprising:
responsive to determining that the programming of the data to the memory device did not complete based on the prior loss of power to the memory device:
recovering a portion of the data programmed to one or more locations of the memory device;
invalidating the portion of the data at the one or more locations of the memory device; and
programming one or more other locations of the memory device with the portion of the data.
4. The method of claim 1 , further comprising:
responsive to determining that the status indicator can be read, determining that the programming of the data to the memory device did complete and there is a data retention loss.
5. The method of claim 4 , further comprising:
responsive to determining that the programming of the data to the memory device did complete and there is the data retention loss:
reading the data programmed to the memory device, the data being at first locations of the memory device;
programming the data to second locations different than the first locations of the memory device; and
invalidating the data at the first locations.
6. The method of claim 1 , wherein the status indicator is moved from a first location to a second location of the memory device after completion of a second pass of a two-pass programming operation.
7. The method of claim 1 , further comprising:
identifying the written page of the memory device, wherein the identifying comprises:
identifying that a data block of the written page is open based on another status indicator, wherein the data block is open when a two-pass programming operation has not completed on the data block.
8. The method of claim 1 , wherein the prior loss of power is an asynchronous power loss of the memory device.
9. A system comprising:
a memory device; and
a processing device, operatively coupled with the memory device, to:
receive an indication of an initialization of power to the memory device;
responsive to receiving the indication of the initialization of power to the memory device, determine whether a status indicator associated with a written page of the memory device can be read; and
responsive to determining that the status indicator cannot be read, determining that programming of data to the memory device did not complete based on a prior loss of power to the memory device.
10. The system of claim 9 , wherein the processing device is further to:
responsive to determining that the programming of the data to the memory device did not complete based on the prior loss of power to the memory device:
recover a portion of the data programmed to one or more locations of the memory device;
invalidate the portion of the data at the one or more locations of the memory device; and
program one or more other locations of the memory device with the portion of the data.
11. The system of claim 9 , wherein the processing device is further to:
responsive to determining that the status indicator can be read, determine that the programming of the data to the memory device did complete and there is a data retention loss.
12. The system of claim 11 , wherein the processing device is further to:
responsive to determining that the programming of the data to the memory device did complete and there is the data retention loss:
read the data programmed to the memory device, the data being at first locations of the memory device;
program the data to second locations different than the first locations of the memory device; and
invalidate the data at the first locations.
13. The system of claim 9 , wherein the status indicator is moved from a first location to a second location of the memory device after completion of a second pass of a two-pass programming operation.
14. The system of claim 9 , wherein the written page of the memory device is a last written page of a block of the memory device.
15. The system of claim 9 , wherein the processing device is further to:
identify the written page of the memory device, wherein to identify the written page the processing device is to:
identify that a data block of the written page is open based on another status indicator, wherein the data block is open when a two-pass programming operation has not completed on the data block.
16. The system of claim 9 , wherein the prior loss of power is an asynchronous power loss of the memory device.
17. A non-transitory computer-readable storage medium comprising storing instructions that, when executed by a processing device, cause the processing device to perform operations comprising:
receiving an indication of an initialization of power to a memory device;
responsive to receiving the indication of the initialization of power to the memory device, determining whether a status indicator associated with a written page of the memory device can be read; and
responsive to determining that the status indicator cannot be read, determining that programming of data to the memory device did not complete based on a prior loss of power to the memory device.
18. The non-transitory computer-readable storage medium of claim 17 , the operations further comprising:
responsive to determining that the programming of the data to the memory device did not complete based on the prior loss of power to the memory device:
recovering a portion of the data programmed to one or more locations of the memory device;
invalidating the portion of the data at the one or more locations of the memory device; and
programming one or more other locations of the memory device with the portion of the data.
19. The non-transitory computer-readable storage medium of claim 18 , to the operations further comprising:
responsive to determining that the status indicator can be read, determining that the programming of the data to the memory device did complete and there is a data retention loss.
20. The non-transitory computer-readable storage medium of claim 17 , wherein the prior loss of power is an asynchronous power loss of the memory device, and wherein the written page of the memory device is a last written page of a block of the memory device.