Embodiments described herein relate generally to a magnetic random access memory.
Magnetic random access memories (to be referred to as MRAMs hereinafter) using the magnetoresistive effects of ferromagnetic materials have recently attracted interest as next-generation solid-state nonvolatile memories capable of speeding up read/write, increasing the capacity, and implementing a low-power operation. As the read method of the MRAMs, a method of feeding a current through a memory cell and reading data based on the magnitude of the value of the current that has flowed is used in general.
Embodiments will now be described with reference to the accompanying drawing. In the following explanation, the same reference numerals denote constituent elements having the same functions and arrangements, and a repetitive explanation will be made only when necessary. The embodiments to be described below merely exemplify devices and methods for embodying the technical concepts of the embodiments, and the materials, shapes, structures, layouts, and the like of the components are not limited to those to be described below.
In general, according to one embodiment, a magnetic random access memory includes a memory cell array, a read circuit, an error checking and correction (ECC) circuit, an address register, a data register, a flag register, a flag check circuit, and a write back circuit.
In the memory cell array, memory cells each including a magnetoresistive element are arranged. The read circuit reads data from a memory cell designated by an address out of the memory cells. The ECC circuit checks an error in the data read by the read circuit and corrects the error. The address register stores the address at which the error has been detected by the ECC circuit. The data register stores corrected data in which the error has been corrected by the ECC circuit. The flag register sets an error flag in association with the address at which the error has been detected by the ECC circuit. The flag check circuit checks whether the error flag is set in the flag register. The write back circuit writes back the data to the memory cell designated by the address corresponding to the error flag.
In the first embodiment, an example will be described in which data is read from the memory cell array of a magnetic random access memory (MRAM), error checking and correction of the data is performed immediately after the read, and the data is written back to a memory cell at which an error has been detected.
As shown in
The memory cell array 11 includes a plurality of memory cells for storing data. Each memory cell includes a resistance change element and a select transistor. The resistance change element includes, for example, a magnetoresistive element. A magnetic tunnel junction (MTJ) element is used here as the magnetoresistive element. The select transistor is used to select the memory cell from the memory cell array 11.
As shown in
The storage layer 1 is a magnetic layer having a variable magnetization direction, and has perpendicular magnetic anisotropy with a magnetization direction perpendicular or almost perpendicular to the film plane (upper surface/lower surface). “Variable magnetization direction” means that the magnetization direction changes with respect to the write current.
The tunnel barrier layer 2 is formed on the storage layer 1. The tunnel barrier layer 2 is a nonmagnetic layer and is made of, for example, MgO.
The reference layer 3 is formed on the tunnel barrier layer 2. The reference layer 3 is a magnetic layer having an invariable magnetization direction, and has perpendicular magnetic anisotropy with a magnetization direction perpendicular or almost perpendicular to the film plane. “Invariable magnetization direction” means that the magnetization direction does not change with respect to the write current. That is, the magnetization direction reversing energy barrier of the reference layer 3 is larger than that of the storage layer 1.
The read controller 15 controls data read from the memory cells in the memory cell array 11. The ECC circuit 16 performs error checking of the data read by the read controller 15 and corrects error data. The input/output circuit 18 outputs the data that has undergone the error checking and correction of the ECC circuit 16.
The write back data register 13 temporarily stores the data that has undergone the error checking and correction of the ECC circuit 16. The write back controller 12 writes back the data stored in the write back data register 13 to the memory cells.
The input/output circuit 19 receives a command and an address and outputs them to the command controller 17 and the address controller 14. The command controller 17 receives the command and performs control necessary for the operation of the command. The address controller 14 supplies the address to the memory cell array 11.
The read operation of the MRAM according to the first embodiment will be described next with reference to
When a read command and an address are input to the input/output circuit 19, the command controller 17 performs control necessary for read, and the address controller 14 outputs the read target address to the memory cell array 11.
Next, the read controller 15 reads data from the memory cell designated by the address (step S1). The ECC circuit 16 performs error checking of the read data, and if error data exists, corrects the error data (step S2). After that, the data processed by the ECC circuit 16 is output from the input/output circuit 18 (step S3).
In addition, the data processed by the ECC circuit 16 is stored in the write back data register 13 (step S4). If error data exists, the write back controller 12 writes back the data in the write back data register 13 to the memory cell from which the error data has been read (step S5). The operation of the read command thus ends.
As the read method of, for example, the magnetic random access memory (MRAM), a method of feeding a current through a memory cell and reading data based on the magnitude of the value of the current that has flowed is used currently. As the generations have passed, a current Ic necessary to invert the value of a memory cell is scaled down. Depending on the decrease in the current Ic, a current Iread needed to read the data of a memory cell is also scaled down. However, the current Iread cannot have a value equal to or smaller than the minimum current value necessary for read. For this reason, the decrease amount of the current Iread is smaller than that of the current Ic, and concerns are rising that read data may erroneously be inverted due to read disturb that occurs at the time of read.
To solve the above-described problem, the first embodiment includes the above-described arrangement and operation. That is, data is read from the memory cell array 11, and error checking and correction of the read data is performed. Immediately after the error checking and correction, the data is written back to the address (memory cell) at which error data has been detected. This makes it possible to reduce data errors caused by read disturb and write errors.
In the second embodiment, an example will be described in which at the time of read when a read command is input, if read data includes an error, an error flag is set, and the address and corrected data are stored. An auto write back command is input for every predetermined period, and the corrected data is written back to the address for which the error flag is set.
As shown in
The write back data and flag register 21 temporarily stores data that has undergone error checking and correction of the ECC circuit 16, and sets an error flag in association with an address at which an error has been detected. The write back address register 22 temporarily stores the address at which the error has been detected by the ECC circuit 16.
The write back check circuit 23 detects whether an error flag is set in the write back data and flag register 21, and outputs the detection result to the write back address register 22. The rest of the arrangement is the same as in the first embodiment.
Read executed in the second embodiment and auto write back performed after the read will be described next.
When a read command and an address are input to the input/output circuit 19, the command controller 17 performs control necessary for read, and the address controller 14 outputs the read target address to the memory cell array 11.
Next, the read controller 15 reads data from the memory cell designated by the address (step S11). The ECC circuit 16 performs error checking of the read data, and if error data exists, corrects the error data (step S12). After that, the data processed by the ECC circuit 16 is output from the input/output circuit 18 (step S13).
In addition, the data processed by the ECC circuit 16 is stored in the write back data and flag register 21. An error flag associated with the address at which the error has been detected by the ECC circuit 16 is set in the write back data and flag register 21. The address at which the error has been detected by the ECC circuit 16 is stored in the write back address register 22 (step S14). The operation of the read command thus ends.
After the above-described read, an auto write back command is input for every predetermined period.
When the auto write back command is input to the input/output circuit 19, the command controller 17 performs control necessary for auto write back.
First, the write back check circuit 23 determines whether an error flag is set in the write back data and flag register 21 (step S21). If an error flag is set, the address corresponding to the error flag, which is stored in the write back address register 22, is output to the address controller 14.
Write back is executed to the memory cell designated by the address set in the address controller 14. That is, data in the write back data and flag register 21 corresponding to the address is written back to the memory cell of the address by the write back controller 12 (step S23).
On the other hand, if no error flag is set in step S21, the write back stops, and the operation ends (step S24).
The auto write back operation of the MRAM according to the second embodiment will be described in detail with reference to
As shown in
In this case, since an error flag is set, the write back controller 12 writes back corrected data corresponding to the error flag to an address corresponding to the error flag at the time T2 at which the next auto write back command is input.
At the time T2, it is checked whether an error flag is set in the write back data and flag register 21. In this case, since no error flag is set, write back is not performed at the time T3 at which the next auto write back command is input.
At the time T3, it is checked whether an error flag is set in the write back data and flag register 21. In this case, two error flags are set. Hence, the write back controller 12 writes back corrected data corresponding to the error flags to addresses corresponding to the error flags at the time T4 at which the next auto write back command is input.
At the time T4 and the times T5 and T6 at which the next auto write back command is input, it is checked whether an error flag is set in the write back data and flag register 21. In this case, since no error flag is set, write back is not performed.
In the second embodiment, error checking and correction of read data is performed at the time of read when a read command is input. If the read data includes an error, an error flag is set, and the address and corrected data are stored. The error flag is checked for every predetermined period. If an error flag is set, the corrected data is written back to the address for which the error flag is set. Data write back is performed not immediately after read by the read command but for every predetermined period. This can shorten the read cycle time in the read operation. It is also possible to reduce data errors caused by read disturb and write errors. The chip size can also be reduced.
In the third embodiment, an example will be described in which when an error flag is set, write back is performed, and when no error flag is set, auto write back is performed. That is, in the second embodiment, write back is performed only when an error flag is set. In the third embodiment, when an error flag is set, write back is performed similarly. However, when no error flag is set, auto write back is performed.
As shown in
The auto write back address counter 31 automatically generates an address for write back under predetermined control and increments the address. The multiplexer 32 selects one of the outputs of the write back address register 22 and the auto write back address counter 31 in accordance with the error flag detection result output from the write back check circuit 23, and supplies the output to the address controller 14. The rest of the arrangement is the same as in the second embodiment.
In the third embodiment, storing an error flag and its address and corrected data corresponding to it at the time of read when a read command is input is the same as in the second embodiment, and a description thereof will be omitted.
When the auto write back command is input to the input/output circuit 19, the command controller 17 performs control necessary for auto write back.
First, the write back check circuit 23 determines whether an error flag is set in the write back data and flag register 21 (step S31). If an error flag is set, the multiplexer 32 outputs the address corresponding to the error flag, which is stored in the write back address register 22, to the address controller 14.
Write back is executed to the memory cell designated by the address set in the address controller 14. That is, data in the write back data and flag register 21 corresponding to the address is written back to the memory cell of the address by the write back controller 12 (step S35).
On the other hand, if no error flag is set in step S31, the multiplexer 32 outputs the address stored in the auto write back address counter 31 to the address controller 14 (step S33).
Next, read shown in
The auto write back operation of the MRAM according to the third embodiment will be described in detail with reference to
As shown in
The auto write back is processing executed in the order of steps S33, S34, and S35 shown in
In this case, since an error flag is set at the time T1, the write back controller 12 writes back corrected data corresponding to the error flag to an address corresponding to the error flag at the time T2 at which the next auto write back command is input.
At the time T2, it is checked whether an error flag is set in the write back data and flag register 21. In this case, since no error flag is set, write back according to an error flag is not performed, and auto write back is executed at the time T3 at which the next auto write back command is input.
At the time T3, it is checked whether an error flag is set in the write back data and flag register 21. In this case, two error flags are set. Hence, the write back controller 12 writes back corrected data corresponding to the error flags to addresses corresponding to the error flags at the time T4 at which the next auto write back command is input.
At the time T4 and the times T5 and T6 at which the next auto write back command is input, it is checked whether an error flag is set in the write back data and flag register 21. In this case, since no error flag is set, write back according to an error flag is not performed, and auto write back is executed at the times at which the next auto write back command is input.
In the third embodiment, error checking and correction of read data is performed at the time of read when a read command is input. If the read data includes an error, an error flag is set, and the address and corrected data are stored. The error flag is checked for every predetermined period. If an error flag is set, the corrected data is written back to the address for which the error flag is set. If no error flag is set, auto write back is performed. That is, read is performed for an address automatically issued by the address counter, and corrected data is written back to the address at which an error has been detected. Data write back is performed not immediately after read by the read command but for every predetermined period.
This can shorten the read cycle time in the read operation. It is also possible to reduce data errors caused by read disturb and write errors. In the third embodiment, since auto write back is performed even if no error flag is set, data errors can further be reduced.
The auto write back operation of an MRAM according to the modification of the third embodiment will be described next. In this modification, an example will be described in which the interval to perform auto write back is changed in accordance with the error flag generation frequency.
When the auto write back command is input to the input/output circuit 19, the command controller 17 performs control necessary for auto write back.
First, the write back check circuit 23 determines whether an error flag is set in the write back data and flag register 21 (step S41). If an error flag is set, the write back check circuit 23 counts the number A of error flags (step S42).
Next, the write back check circuit 23 determines whether the number A of error flags is equal to or larger than a predetermined number B (step S43). If the number A of error flags is equal to or larger than the predetermined number B, the write back controller 12 shortens the interval to perform write back (step S44). After that, the process advances to step S45.
On the other hand, if the number A of error flags is smaller than the predetermined number B in step S43, the write back controller 12 prolongs the interval to perform write back (step S46). After that, the process advances to step S45.
In step S45, the multiplexer 32 outputs the address corresponding to the error flag, which is stored in the write back address register 22, to the address controller 14. After that, write back is executed to the memory cell designated by the address set in the address controller 14 (step S49).
On the other hand, if no error flag is set in step S41, the multiplexer 32 outputs the address stored in the auto write back address counter 31 to the address controller 14 (step S47).
Next, read shown in
The auto write back operation of the MRAM according to the modification will be described in detail with reference to
As shown in
In this case, since an error flag is set at the time T1, the write back controller 12 writes back corrected data corresponding to the error flag to an address corresponding to the error flag at the time T2 at which the next auto write back command is input.
At the times T2, T3, T4, and T5, no error flag is set. Hence, write back according to an error flag is not performed, and auto write back is executed at the times T3, T4, T5, and T6 at which the next auto write back command is input.
When the auto write back command is input at the time T6, the write back check circuit 23 checks whether an error flag is set in the write back data and flag register 21.
At the time T6, a plurality of error flags are set. Hence, the write back controller 12 writes back corrected data corresponding to the error flags to addresses corresponding to the error flags at the time T7 at which the next auto write back command is input.
In the error flag check at the time T6, the number A of error flags is equal to or larger than the predetermined number B. For this reason, the auto write back command input interval at the times T7 to T12 is adjusted to be shorter, as shown in
In the modification, the auto write back command input interval is changed in accordance with the error flag generation frequency. That is, when the error flag generation frequency is high, the write back execution interval is shortened. When the error flag generation frequency is low, the write back execution interval is prolonged. This enables an efficient write back operation.
As described above, according to the above-described embodiments, the problem that the rate of data error occurrence caused by read disturb and write errors in the MRAM increases can be solved while maintaining the performance of the memory.
Note that a command generated as an auto refresh command in a dynamic random access memory (DRAM) can also be used as the auto write back command of the embodiments.
While certain embodiments have been described, these embodiments have been presented by way of example only, and are not intended to limit the scope of the inventions. Indeed, the novel methods and systems described herein may be embodied in a variety of other forms; furthermore, various omissions, substitutions and changes in the form of the methods and systems described herein may be made without departing from the spirit of the inventions. The accompanying claims and their equivalents are intended to cover such forms or modifications as would fall within the scope and spirit of the inventions.
This application claims the benefit of U.S. Provisional Application No. 61/876,085, filed Sep. 10, 2013, the entire contents of which are incorporated herein by reference.
Number | Name | Date | Kind |
---|---|---|---|
5621743 | Tomisawa | Apr 1997 | A |
6584589 | Tran et al. | Jun 2003 | B1 |
6704230 | DeBrosse et al. | Mar 2004 | B1 |
9112536 | Alam | Aug 2015 | B2 |
9170879 | Yang | Oct 2015 | B2 |
20030093744 | Leung et al. | May 2003 | A1 |
20040219740 | Nishihara | Nov 2004 | A1 |
20050193164 | Royer, Jr. et al. | Sep 2005 | A1 |
20060282755 | Oh | Dec 2006 | A1 |
20080133994 | Oh | Jun 2008 | A1 |
20080288809 | Koguchi et al. | Nov 2008 | A1 |
20090100315 | Lee | Apr 2009 | A1 |
20090168571 | Pyo et al. | Jul 2009 | A1 |
20100088572 | Ohnuki et al. | Apr 2010 | A1 |
20100142260 | Yoon et al. | Jun 2010 | A1 |
20110041016 | O'Connell | Feb 2011 | A1 |
20120060066 | Nagadomi et al. | Mar 2012 | A1 |
20120268994 | Nagashima | Oct 2012 | A1 |
20140169083 | Wang et al. | Jun 2014 | A1 |
20140281810 | Gifford et al. | Sep 2014 | A1 |
Entry |
---|
Yu, et al., “A Hybrid ECC and Redundancy Technique for Reducing Refresh Power of DRAMs”, 2013 IEEE 31st VLSI Test Symposium (VTS). |
Number | Date | Country | |
---|---|---|---|
20150074491 A1 | Mar 2015 | US |
Number | Date | Country | |
---|---|---|---|
61876085 | Sep 2013 | US |