MAGNETORESISTIVE RANDOM ACCESS MEMORY FOR PHYSICALLY UNCLONABLE FUNCTION TECHNOLOGY AND ASSOCIATED RANDOM CODE GENERATING METHOD

20230052438 · 2023-02-16

    Inventors

    Cpc classification

    International classification

    Abstract

    A random code generating method for the magnetoresistive random access memory is provided. Firstly, a first magnetoresistive random access memory cell and a second magnetoresistive random access memory cell are programmed into an anti-parallel state. Then, an initial value of a control current is set. Then, an enroll action is performed on the first and second magnetoresistive random access memory cells. If the first and second magnetoresistive random access memory cells fail to pass the verification action, the control current is increased by a current increment, and the step of setting the control current is performed again. If the first and second magnetoresistive random access memory cells pass the verification action, a one-bit random code is stored in the first magnetoresistive random access memory cell or the second magnetoresistive random access memory cell.

    Claims

    1. A magnetoresistive random access memory, comprising: a memory cell array comprising a first magnetoresistive random access memory cell and a second magnetoresistive random access memory cell, wherein a control end of the first magnetoresistive random access memory cell is connected to a word line, a first end of the first magnetoresistive random access memory cell is connected to a first source line, and a second end of the first magnetoresistive random access memory cell is connected to a first bit line, wherein a control end of the second magnetoresistive random access memory cell is connected to the word line, a first end of the second magnetoresistive random access memory cell is connected to a second source line, and a second end of the second magnetoresistive random access memory cell is connected to a second bit line; a current source receiving a control signal and generating a control current according to the control signal; a select circuit connected to the current source, the first bit line and the second bit line; a first sensing element, wherein a first input terminal of the first sensing element is connected to the select circuit, a second input terminal of the first sensing element receives a reference current, and an output terminal of the first sensing element generates a first sensing signal according to the reference current and a first read current generated by the first magnetoresistive random access memory cell; a second sensing element, wherein a first input terminal of the second sensing element is connected to the select circuit, a second input terminal of the second sensing element receives the reference current, and an output terminal of the second sensing element generates a second sensing signal according to the reference current and a second read current generated by the second magnetoresistive random access memory cell; and a judging element, wherein a first input terminal of the judging element is connected to the output terminal of the first sensing element, a second input terminal of the judging element is connected to the output terminal of the second sensing element, and an output terminal of the judging element generates a verification signal according to the first sensing signal and the second sensing signal, wherein both of the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell are initially in an anti-parallel state, wherein while an enroll action is performed, the current source is connected to the first bit line and the second bit line through the select circuit, so that a first portion of the control current flows through the first magnetoresistive random access memory cell and a second portion of the control current flows through the second magnetoresistive random access memory cell, wherein while a verification action is performed, the first bit line and the second bit line are respectively connected to the first input terminal of the first sensing element and the first input terminal of the second sensing element through the select circuit, so that the first read current flows to the first sensing element and the second read current flows to the second sensing element.

    2. The magnetoresistive random access memory as claimed in claim 1, wherein the control current is a current pulse with a fixed pulse width, and a pulse height of the current pulse is adjustable according to the control signal.

    3. The magnetoresistive random access memory as claimed in claim 1, wherein while the enroll action is performed, the word line receives an on voltage, and the first source line and the second source line receive a ground voltage.

    4. The magnetoresistive random access memory as claimed in claim 1, wherein while the verification action is performed, the word line receives an on voltage, and the first source line and the second source line receive a read voltage.

    5. The magnetoresistive random access memory as claimed in claim 4, wherein while the verification action is performed, the first sensing element generates the first sensing signal according to a result of comparing the first read current with the reference current, the second sensing element generates the second sensing signal according to a result of comparing the second read current with the reference current.

    6. The magnetoresistive random access memory as claimed in claim 5, wherein if the verification signal indicates that the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell fail to pass the verification action, both of the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell are maintained in the anti-parallel state.

    7. The magnetoresistive random access memory as claimed in claim 5, wherein if the verification signal indicates that the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell pass the verification action, one of the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell is maintained in the anti-parallel state, and the other of the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell is switched to a parallel state.

    8. The magnetoresistive random access memory as claimed in claim 7, wherein if the verification signal indicates that the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell pass the verification action, the first magnetoresistive random access memory cell or the second magnetoresistive random access memory cell stores a one-bit random code.

    9. The magnetoresistive random access memory as claimed in claim 1, wherein the first magnetoresistive random access memory cell comprises a switch transistor and a storage element, wherein a first drain/source terminal of the switch transistor is connected to the first source line, a gate terminal of the switch transistor is connected to the word line, a second drain/source terminal of the switch transistor is connected to a first terminal of the storage element, a second terminal of the storage element is connected to the first bit line, and the storage element is a magnetic tunnel junction.

    10. A random code generating method for the magnetoresistive random access memory according to claim 1, the random code generating method comprising steps of: (a) programming the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell into the anti-parallel state; (b) setting an initial value of the control current; (c) performing the enroll action on the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell; (d) if the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell fail to pass the verification action, increasing the control current by a current increment, and performing the step (c) again; and (e) if the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell pass the verification action, ending the random code generating process; Wherein a one-bit random code is stored in the first magnetoresistive random access memory cell or the second magnetoresistive random access memory cell after the step (e) is performed.

    11. The random code generating method as claimed in claim 10, wherein the control current is a current pulse with a fixed pulse width, and a pulse height of the current pulse is increased when the control current is increased by the current increment.

    12. A magnetoresistive random access memory, comprising: a memory cell array comprising m×2n magnetoresistive random access memory cells in an m×2n array arrangement, wherein the memory cell array is connected to m word lines, 2n bit lines and 2n source lines, wherein 2n magnetoresistive random access memory cells in a first row of the memory cell array are collaboratively formed as n magnetoresistive random access memory cell pairs, control ends of the 2n magnetoresistive random access memory cells are connected to a first word line, first ends of the 2n magnetoresistive random access memory cells are connected to corresponding 2n source lines, and second ends of the 2n magnetoresistive random access memory cell are connected to corresponding n bit lines, a current source receiving a control signal and generating a control current according to the control signal; a select circuit connected to the current source and the 2n bit lines; a first sensing element, wherein a first input terminal of the first sensing element is connected to the select circuit, a second input terminal of the first sensing element receives a reference current, and an output terminal of the first sensing element generates a first sensing signal; a second sensing element, wherein a first input terminal of the second sensing element is connected to the select circuit, a second input terminal of the second sensing element receives the reference current, and an output terminal of the second sensing element generates a second sensing signal; and a judging element, wherein a first input terminal of the judging element is connected to the output terminal of the first sensing element, a second input terminal of the judging element is connected to the output terminal of the second sensing element, and an output terminal of the judging element generates a verification signal, wherein while an enroll action is performed, the current source is connected to a pair of bit lines of the 2n bit lines through the select circuit, and the current source is connected to a specified magnetoresistive random access memory cell pair of the n magnetoresistive random access memory cell pairs, so that a first portion of the control current flows through a first magnetoresistive random access memory cell of the specified magnetoresistive random access memory cell pair and a second portion of the control current flows through a second magnetoresistive random access memory cell of the specified magnetoresistive random access memory cell pair, wherein while a verification action is performed, the pair of bit lines of the 2n bit lines are respectively connected to the first input terminal of the first sensing element and the first input terminal of the second sensing element through the select circuit, so that a first read current generated by the first magnetoresistive random access memory cell of the specified magnetoresistive random access memory cell pair flows to the first sensing element and a second read current generated by the second magnetoresistive random access memory cell of the specified magnetoresistive random access memory cell pair flows to the second sensing element.

    13. The magnetoresistive random access memory as claimed in claim 12, the control current is a current pulse with a fixed pulse width, and a pulse height of the current pulse is adjustable according to the control signal.

    14. The magnetoresistive random access memory as claimed in claim 12, wherein while the enroll action is performed, the first word line receives an on voltage, and the 2n source lines receive a ground voltage.

    15. The magnetoresistive random access memory as claimed in claim 12, wherein while the verification action is performed, the first word line receives an on voltage, and the 2n source lines receives a read voltage.

    16. The magnetoresistive random access memory as claimed in claim 15, wherein while the verification action is performed, the first sensing element generates the first sensing signal according to a result of comparing the first read current with the reference current, the second sensing element generates the second sensing signal according to a result of comparing the second read current with the reference current, and the judging element generates the verification signal according to the first sensing signal and the second sensing signals.

    17. The magnetoresistive random access memory as claimed in claim 16, wherein if the verification signal indicates that the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell of the specified magnetoresistive random access memory cell pair fail to pass the verification action, both of the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell are maintained in an anti-parallel state.

    18. The magnetoresistive random access memory as claimed in claim 16, wherein if the verification signal indicates that the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell of the specified magnetoresistive random access memory cell pair pass the verification action, one of the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell is maintained in an anti-parallel state, and the other of the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell is switched from the anti-parallel state to a parallel state.

    19. The magnetoresistive random access memory as claimed in claim 18, wherein if the verification signal indicates that the first magnetoresistive random access memory cell and the second magnetoresistive random access memory cell of the specified magnetoresistive random access memory cell pair pass the verification action, the first magnetoresistive random access memory cell or the second magnetoresistive random access memory cell stores a one-bit random code.

    20. The magnetoresistive random access memory as claimed in claim 12, wherein the first magnetoresistive random access memory cell comprises a switch transistor and a storage element, wherein a first drain/source terminal of the switch transistor is connected to a first source line of the n source lines, a gate terminal of the switch transistor is connected to the word line, a second drain/source terminal of the switch transistor is connected to the first terminal of the storage element, a second terminal of the storage element is connected to a first bit line of the 2n bit lines, and the storage element is a magnetic tunnel junction.

    21. A random code generating method for the magnetoresistive random access memory according to claim 12, the random code generating method comprising steps of: (a) programming the m×2n magnetoresistive random access memory cells of the memory cell array into an anti-parallel state; (b) determining a selected row of the memory cell array; (c) setting an initial value of the control current; (d) performing the enroll action on plural magnetoresistive random access memory cell pairs in the selected row sequentially, wherein the plural magnetoresistive random access memory cell pairs have not passed the verification action; (e) if at least one magnetoresistive random access memory cell pair in the selected row fails to pass the verification action, increasing the control current by a current increment, and performing the step (d) again; (f) if all of the magnetoresistive random access memory cell pairs in the selected row pass the verification action and the selected row is not a last row of the memory cell array, determining a next selected row, and performing the step (c) again; and (g) if all of the magnetoresistive random access memory cell pairs in the selected row pass the verification action and the selected row is the last row of the memory cell array, ending the random code generating process; Wherein an m×n-bit random code is stored in the memory cell array after the step (g) is performed.

    22. The random code generating method as claimed in claim 21, wherein the control current is a current pulse with a fixed pulse width, and a pulse height of the current pulse is increased when the control current is increased by the current increment.

    Description

    BRIEF DESCRIPTION OF THE DRAWINGS

    [0027] The above objects and advantages of the present invention will become more readily apparent to those ordinarily skilled in the art after reviewing the following detailed description and accompanying drawings, in which:

    [0028] FIG. 1 (prior art) is a schematic circuit diagram illustrating a conventional MRAM cell;

    [0029] FIGS. 2A and 2B (prior art) are schematic circuit diagrams illustrating the MRAM cell in the P state and the AP state;

    [0030] FIG. 3 (prior art) is a plot illustrating the relationship between the write current and the switching time when the state of the storage element is switched;

    [0031] FIG. 4A is a schematic circuit diagram illustrating a magnetoresistive random access memory (MRAM) for a physically unclonable function (PUF) technology according to a first embodiment of the present invention;

    [0032] FIG. 4B is a flowchart illustrating a random code generating method for the magnetoresistive random access memory according to the first embodiment of the present invention;

    [0033] FIGS. 5A to 5D schematically illustrate the operations of the random code generating method in different stages and the timing waveforms of associated signals;

    [0034] FIG. 6A is a schematic circuit diagram illustrating a magnetoresistive random access memory (MRAM) for a physically unclonable function (PUF) technology according to a second embodiment of the present invention;

    [0035] FIG. 6B is a flowchart illustrating a random code generating method for the magnetoresistive random access memory according to the second embodiment of the present invention; and

    [0036] FIGS. 7A and 7B schematically illustrate the operations of the random code generating method when the enroll action and the verification action of the magnetoresistive random access memory are performed.

    DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS

    [0037] FIG. 4A is a schematic circuit diagram illustrating a magnetoresistive random access memory (MRAM) for a physically unclonable function (PUF) technology according to a first embodiment of the present invention. The magnetoresistive random access memory comprises a MRAM cell array, a current source 410, a select circuit 430, two sensing elements 452, 454, and a judging element 460.

    [0038] The MRAM cell array comprises two MRAM cells c1 and c2 in a 1×2 array arrangement. The MRAM cells c1 and c2 are collaboratively formed as a MRAM cell pair. The MRAM cell c1 comprises a switch transistor M.sub.S1 and a storage element R.sub.1. The MRAM cell c2 comprises a switch transistor M.sub.S2 and a storage element R.sub.2. FIG. 4A illustrates that the switch transistors M.sub.S1, M.sub.S2 are N-type transistors, in some embodiments, the switch transistors M.sub.S1, M.sub.S2 can be P-type transistors. The structures of the MRAM cells c1 and c2 are similar to the structure of the MRAM cell 110 as shown in FIG. 1, and not redundantly described herein.

    [0039] The first end of the MRAM cell c1 is connected to the source line SL1. The second end of the MRAM cell c1 is connected to the bit line BL1. The control end of the MRAM cell c1 is connected to the word line WL1. The first end of the MRAM cell c2 is connected to the source line SL2. The second end of the MRAM cell c2 is connected to the bit line BL2. The control end of the MRAM cell c2 is connected to the word line WL1.

    [0040] The current source 410 is connected between a power supply voltage Vdd and the select circuit 430. While an enroll action is performed, the current source 410 generates the control current I.sub.ctrl. The control current I.sub.ctrl is a current pulse with a fixed pulse width. The magnitude of the control current I.sub.ctrl is equal to the pulse height of the current pulse. According to a control signal S.sub.ctrl, the current source 410 adjusts the magnitude of the control current I.sub.ctrl That is, the pulse height of the current pulse can be adjusted according to the control signal S.sub.ctrl.

    [0041] The select circuit 430 includes two select elements 432 and 434. The first terminal of the select element 432 is connected to the current source 410. The second terminal of the select element 432 is connected to the sensing element 452. The third terminal of the select element 432 is connected to the bit line BL1. The first terminal of the select element 434 is connected to the current source 410. The second terminal of the select element 434 is connected to the sensing element 454. The third terminal of the select element 434 is connected to the bit line BL2. During the enroll action, the first end and the third end of the select element 432 are connected with each other, and the first end and the third end of the select element 434 are connected with each other. During a verification action, the second end and the third end of the select element 432 are connected with each other, and the second end and the third end of the select element 434 are connected with each other.

    [0042] During the verification action, the sensing elements 452 and 454 and the judging element 460 are enabled. The first input terminal of the sensing element 452 is connected to the second terminal of the select element 432. The second input terminal of the sensing element 452 receives a reference current I.sub.ref. The output terminal of the sensing element 452 generates a sensing signal S.sub.S1. The first input terminal of the sensing element 454 is connected to the second terminal of the select element 434. The second input terminal of the sensing element 454 receives the reference current I.sub.ref. The output terminal of the sensing element 454 generates a sensing signal S.sub.S2. In an embodiment, the sensing elements 452 and 454 are current comparators.

    [0043] The two input terminals of the judging element 460 are connected to the output terminals of the sensing elements 452 and 454 for receiving the sensing signals S.sub.S1 and S.sub.S2. For example, the judging element 460 is an XOR gate. During the verification operation, the output terminal of the judging element 460 generates a verification signal V.sub.pass to indicate whether the MRAM cell pair pass the verification action or not.

    [0044] FIG. 4B is a flowchart illustrating a random code generating method for the magnetoresistive random access memory according to the first embodiment of the present invention. Firstly, the MRAM cells c1 and c2 are programmed into the AP state (Step S480). Then, an initial value of the control current I.sub.ctrl is set (Step S482). That is, the control current I.sub.ctrl is adjusted according to the control signal S.sub.ctrl.

    [0045] Then, the MRAM cells c1 and c2 are subjected to an enroll action (Step S484). While the enroll action is performed, the control current I.sub.ctrl is divided into two portions, and the two portions are respectively provided to the MRAM cells c1 and c2 of the MRAM cell pair. That is, while the enroll action is performed, a first portion of the control current I.sub.ctrl is provided to the MRAM cell c1, and a second portion of the control current I.sub.ctrl is provided to the MRAM cell c2. Then, a step S486 is performed to judge whether the MRAM cell pair pass a verification action.

    [0046] If the judging condition of the step S486 is not satisfied, the control current I.sub.ctrl is increased by a current increment (i.e., Ictrl=Ictrl+ΔI) (Step S488), and the step S484 is repeatedly done. That is, the control current I.sub.ctrl is adjusted according to the control signal S.sub.ctrl. Consequently, the pulse height of the current pulse is increased.

    [0047] Whereas, if the judging condition of the step S486 is satisfied, the random code generating process is ended. Under this circumstance, the storage state of the MRAM cell c1 or the MRAM cell c2 can be used as a one-bit random code. In other words, the MRAM cell array has generated a one-bit random code, and the one-bit random code is stored in the MRAM cell c1 or the MRAM cell c2 of the MRAM cell array.

    [0048] FIGS. 5A to 5D schematically illustrate the operations of the random code generating method in different stages and the timing waveforms of associated signals.

    [0049] Please refer to FIG. 5A. The storage elements R.sub.1 and R.sub.2 in the MRAM cells c1 and c2 of the MRAM cell pair have been programmed to the AP state. The time interval between the time point t.sub.A and the time point t.sub.B is an enroll cycle. Meanwhile, the current source 410 generates the control circuit I.sub.ctrl. The magnitude of the control circuit I.sub.ctrl represents the pulse height of the current pulse. The current pulse has a fixed pulse width T.

    [0050] While the enroll action is performed, the first end and the third end of the select element 432 are connected with each other, and the first end and the third end of the select element 434 are connected with each other. Consequently, the current source 410 is connected to the bit lines BL1 and BL2. In addition, the word line WL1 receives the on voltage V.sub.ON, and the source lines SL1 and SL2 are connected to the ground terminal to receive the ground voltage (i.e., 0V). Consequently, the control current I.sub.ctrl generated by the current source 410 is divided into two portions (i.e., the write currents I.sub.W1 and I.sub.W2), wherein I.sub.ctrl=I.sub.W1+I.sub.W2. The two portions of the control current I.sub.ctrl flow to the two MRAM cells c1 and c2, respectively.

    [0051] Since the MRAM cells c1 and c2 are in AP state, the magnitude of the write current I.sub.W1 is almost equal to the magnitude of the write current I.sub.W2. The write current I.sub.W1 flows to the ground terminal through the select element 432, the bit line BL1, the storage element R.sub.1, the select transistor M.sub.S1 and the source line SL1. The write current I.sub.W2 flows to the ground terminal through the select element 434, the bit line BL2, the storage element R.sub.2, the select transistor M.sub.S2 and the source line SL2.

    [0052] Please refer to FIG. 5A again. After the predetermined time period T (i.e., the pulse width) of the write current I.sub.W1, the MRAM cell c1 is still maintained in the AP state, and the storage state is unchanged. Similarly, after the predetermined time period T (i.e., the pulse width) of the write current I.sub.W2, the MRAM cell c2 is still remained in the AP state, and the storage state is unchanged.

    [0053] Please refer to FIG. 5B. After the enroll cycle, the time interval between the time point t.sub.B and the time point t.sub.C is a verification cycle. While the verification action is performed, the second end and the third end of the select element 432 are connected with each other, and the second end and the third end of the select element 434 are connected with each other. Consequently, the first input terminal of the sensing element 452 is connected to the bit line BL1, and the first input terminal of the sensing element 454 is connected to the bit line BL2. In addition, the word line WL1 receives the on voltage V.sub.ON, and the source lines SL1 and SL2 receives the read voltage V.sub.R. Consequently, the read currents I.sub.R1 and I.sub.R2 generated by the MRAM cells c1 and c2 flow to the sensing elements 452 and 454, respectively. The read current I.sub.R1 flows to the sensing element 452 through the source line SL1, the select transistor M.sub.S1, the storage element R.sub.1, the bit line BL1 and the select element 432. The read current I.sub.R2 flows to the sensing element 454 through the source line SL2, the select transistor M.sub.S2, the storage element R.sub.2, the bit line BL2 and the select element 434. Since both of the MRAM cells c1 and c2 are in the AP state, the magnitude of the read current I.sub.R1 and the magnitude of the read current I.sub.R2 are very small and lower than the reference current I.sub.ref. Consequently, the sensing signals S.sub.S1 and S.sub.S2 generated by the sensing elements 452 and 454 have the same logic level to indicate that the MRAM cells c1 and c2 are both in the AP state. Since the sensing signals S.sub.S1 and S.sub.S2 have the same logic level, the verification signal V.sub.pass generated by the judging element 460 is in a logic low level state “0” to indicate that the MRAM cell pair fail to pass the verification action.

    [0054] If the verification action fails, the control current I.sub.ctrl is increased by the current increment ΔI. That is, Ictrl=Ictrl+ΔI. In the time interval between the time point t.sub.C and the time point t.sub.D, another enroll action is performed. After the enroll action, the verification action is performed. If the verification action fails, the control current I.sub.ctrl is further increased by the current increment ΔI. The rest may be deduced by analog.

    [0055] After the enroll action and the verification action are performed for many times, the situation in FIG. 5C is shown. In the time interval between the time point t.sub.E and the time point t.sub.G, another enroll action is performed. In addition, the current source 410 generates the control current I.sub.ctrl Similarly, during the enroll action, the current source 410 is connected to the bit lines BL1 and BL2 through the select circuit 430. In addition, the word line WL1 receives the on voltage V.sub.ON, and the source lines SL1 and SL2 are connected to the ground terminal to receive the ground voltage (i.e., 0V). Consequently, the control current I.sub.ctrl generated by the current source 410 is divided into two portions (i.e., the write currents I.sub.W1 and I.sub.W2), wherein I.sub.ctrl=I.sub.W1+I.sub.W2. The two portions of the control current I.sub.ctrl flow to the two MRAM cells c1 and c2, respectively.

    [0056] Please refer to FIG. 5C again. In the early stage of the enroll cycle (i.e., in the time interval between the time point t.sub.E and the time point t.sub.F,) the write currents I.sub.W1 and I.sub.W2 are nearly equal because both of the two MRAM cells c1 and c2 are in the AP state.

    [0057] Due to the process variation of the MRAM cells c1 and c2, it is unable to predict which of the storage elements R.sub.1 and R.sub.2 is first switched to the P state after the enroll action is completed. Consequently, the MRAM cells c1 and c2 can be applied to the PUF technology. Please refer to FIG. 5C again. In the time point t.sub.F within the enroll cycle, the storage element R.sub.1 of the MRAM cells c1 has been switched to the P state (i.e., the low impedance state). Meanwhile, the storage element R.sub.2 of the MRAM cells c2 is still maintained in the AP state. Consequently, in the time interval between the time point t.sub.E and the time point t.sub.G, the write current I.sub.W1 increases, and the write current I.sub.W2 decreases. In other words, the storage element R.sub.2 of the MRAM cells c2 is certainly unable to be switched to the P state.

    [0058] Please refer to FIG. 5D. After the enroll action is completed, another verification action is started at the time point t.sub.G. While the verification action is performed, the bit lines BL1 and BL2 are respectively connected to the sensing elements 452 and 454 through the select circuit 430. In addition, the word line WL1 receives the on voltage V.sub.ON, and the source lines SL1 and SL2 receives the read voltage V.sub.R. Consequently, the read currents I.sub.R1 and I.sub.R2 generated by the MRAM cells c1 and c2 flow to the sensing elements 452 and 454, respectively.

    [0059] Since the MRAM cell c1 is in the P state and MRAM cell c2 is in the AP state, the magnitude of the read current I.sub.R1 is higher than the reference current I.sub.ref, and the magnitude of the read currents I.sub.R2 is lower than the reference current I.sub.ref. Consequently, the sensing signals S.sub.S1 and S.sub.S2 generated by the sensing elements 452 and 454 have different logic levels to indicate that the MRAM cell c1 is in the P state and MRAM cell c2 is in the AP state. Since the sensing signals S.sub.S1 and S.sub.S2 have different logic levels, the verification signal V.sub.pass generated by the judging element 460 is in a high low level state “1” to indicate that the MRAM cell pair pass the verification action. Then, the random code generating process is ended. Under this circumstance, the storage state of the MRAM cell c1 or the MRAM cell c2 can be used as a one-bit random code. In other words, the MRAM cell array has generated a one-bit random code, and the one-bit random code is stored in the MRAM cell c1 or the MRAM cell c2. In case that an external circuit (not shown) intends to use the random code, the external circuit can perform a read action on the magnetoresistive random access memory to retrieve the random code from the MRAM cell c1 or the MRAM cell c2.

    [0060] In some situations, the storage element R.sub.2 of the MRAM cells c2 is switched to the P state, and the storage element R.sub.1 of the MRAM cell c1 is maintained in the AP state. While the verification action is performed, the verification signal V.sub.pass generated by the judging element 460 is in the high low level state “1” to indicate that the MRAM cell pair pass the verification action.

    [0061] From the above descriptions, the judging element 460 generates the verification signal V.sub.pass to indicate whether the MRAM cell pair pass the verification action or not while the verification action is performed. When the MRAM cell pair pass the verification action, it is confirmed that the MRAM cells c1 and c2 have different storage states, that is, a result of an exclusive-OR operation performed on two one-bit random codes stored in the MRAM cell c1 and the MRAM cell c2 is equal to 1. However, it is unable to realize which of the MRAM cells c1 and c2 has been changed to the P state. Consequently, the random code generating method of the present invention can be applied to the PUF technology.

    [0062] It is noted that the applications of the random code generating method are not restricted to the 1×2 MRAM cell array. In some other embodiments, the random code generating method of the present invention can be applied to the MRAM cell array with a larger size.

    [0063] FIG. 6A is a schematic circuit diagram illustrating a magnetoresistive random access memory (MRAM) for a physically unclonable function (PUF) technology according to a second embodiment of the present invention. The magnetoresistive random access memory comprises a MRAM cell array, a current source 610, a select circuit 630, two sensing elements 652, 654, and a judging element 660.

    [0064] The MRAM cell array comprises plural MRAM cells c.sub.1,1˜c.sub.m,2n, which are arranged in a m×2n array, wherein m and n are positive integers. In the MRAM cell array, each of the MRAM cells c.sub.1,1˜c.sub.m,2n comprises a switch transistor and a storage element. For example, the MRAM cell c.sub.1,1 comprises a switch transistor M.sub.1,1 and a storage element R.sub.1,1. The structures of the MRAM cells c.sub.1,1˜c.sub.m,2n are similar to the structure of the MRAM cell 110 as shown in FIG. 1, and not redundantly described herein.

    [0065] The control ends of the 2n MRAM cells c.sub.1,1˜c.sub.1,2n in the first row of the MRAM cell array are connected to the word line WL1. The first ends of the 2n MRAM cells c.sub.1,1˜c.sub.1,2n in the first row of the MRAM cell array are connected to the corresponding source lines SL1˜SL2n, respectively. The second ends of the 2n MRAM cells c.sub.1,1˜c.sub.1,2n in the first row of the MRAM cell array are connected to the corresponding bit lines BL1˜BL2n, respectively. The control ends of the 2n MRAM cells c.sub.2,1˜c.sub.2,2n in the second row of the MRAM cell array are connected to the word line WL2. The first ends of the 2n MRAM cells c.sub.2,1˜c.sub.2,2n in the second row of the MRAM cell array are connected to the corresponding source lines SL1˜SL2n, respectively. The second ends of the 2n MRAM cells c.sub.2,1˜c.sub.2,2n in the second row of the MRAM cell array are connected to the corresponding bit lines BL1-BL2n, respectively. The rest may be deduced by analog. The control ends of the 2n MRAM cells c.sub.m,1˜c.sub.m,2n in the m-th row of the MRAM cell array are connected to the word line WLm. The first ends of the 2n MRAM cells c.sub.m,1˜c.sub.m,2n in the m-th row of the MRAM cell array are connected to the corresponding source lines SL1˜SL2n, respectively. The second ends of the 2n MRAM cells c.sub.m,1˜c.sub.m,2 in the m-th row of the MRAM cell array are connected to the corresponding bit lines BL1˜BL2n, respectively.

    [0066] When the magnetoresistive random access memory is applied to the PUF technology, any two MRAM cells in a row of the MRAM cell array are collaboratively formed as a MRAM cell pair, and the MRAM cell array in a row contains plural MRAM cell pairs. In other words, the enroll actions are performed on the plural MRAM cell pairs in the selected row. For example, as shown in FIG. 6A, the first row of the MRAM cell array contains n MRAM cell pairs. The MRAM cells c.sub.1,1 and c.sub.1,n+1 are collaboratively formed as a first MRAM cell pair of the first row. The MRAM cells c.sub.1,2 and c.sub.1,n+2 are collaboratively formed as a second MRAM cell pair of the first row. The rest may be deduced by analog. The MRAM cells c.sub.1,n and c.sub.1,2n are collaboratively formed as an n-th MRAM cell pair of the first row.

    [0067] The current source 610 is connected between a power supply voltage Vdd and the select circuit 630. While an enroll action is performed, the current source 610 generates the control current I.sub.ctrl. The control current I.sub.ctrl is a current pulse with a fixed pulse width. The magnitude of the control current I.sub.ctrl is equal to the pulse height of the current pulse. According to a control signal S.sub.ctrl, the current source 610 adjusts the magnitude of the control current I.sub.ctrl. That is, the pulse height of the current pulse can be adjusted according to the control signal S.sub.ctrl.

    [0068] The select circuit 630 is connected with the bit lines BL1˜BL2n, the current source 610, the first input terminal of the sensing element 652 and the first input terminal of the sensing element 654. While the enroll action is performed, two of the bit lines are connected to the current source 610 by the select circuit 630. During a verification action, the two bit lines are connected to the first input terminal of the sensing element 652 and the first input terminal of the sensing element 654, respectively.

    [0069] During the verification action, the sensing elements 652 and 654 and the judging element 660 are enabled. The second input terminal of the sensing element 652 receives a reference current I.sub.ref. The output terminal of the sensing element 652 generates a sensing signal S.sub.S1. The second input terminal of the sensing element 654 receives the reference current I.sub.ref. The output terminal of the sensing element 654 generates a sensing signal S.sub.S2. In an embodiment, the sensing elements 652 and 654 are current comparators.

    [0070] The two input terminals of the judging element 660 are connected to the output terminals of the sensing elements 652 and 654 for receiving the sensing signals S.sub.S1 and S.sub.S2. For example, the judging element 660 is an XOR gate. During the verification operation, the output terminal of the judging element 660 generates a verification signal V.sub.pass to indicate whether the MRAM cell pair pass the verification action or not.

    [0071] FIG. 6B is a flowchart illustrating a random code generating method for the magnetoresistive random access memory according to the second embodiment of the present invention. Firstly, the MRAM cells c1,1˜cm,2n of the MRAM cell array are programmed into the AP state (Step S680). Then, a selected row of the MRAM cell array is determined (Step S681), and an initial value of the control current I.sub.ctrl is set (Step S682). That is, the control current I.sub.ctrl is adjusted according to the control signal S.sub.ctrl. Consequently, the current pulse has the lowest pulse height.

    [0072] Then, the MRAM cell pairs in the selected row that have not passed the verification action are sequentially subjected to an enroll action (Step S684). While the enroll action is performed, the control current I.sub.ctrl is divided into two portions, and the two portions are respectively provided to the two MRAM cells of the MRAM cell pair. That is, while the enroll action is performed, a first portion of the control current I.sub.ctrl is provided to the first MRAM cell of the MRAM cell pair, and a second portion of the control current I.sub.ctrl is provided to the second MRAM cell of the MRAM cell pair.

    [0073] After the enroll action are performed on the MRAM cell pairs in the selected row that have not passed the verification action, a step S686 is performed to judge whether all of the MRAM cell pairs in the selected row pass the verification action. If the judging condition of the step S686 is not satisfied, the control current I.sub.ctrl is increased by a current increment (i.e., Ictrl=Ictrl+ΔI) (Step S688), and the step S684 is repeatedly done. That is, the control current I.sub.ctrl is adjusted according to the control signal S.sub.ctrl. Consequently, the pulse height of the current pulse is increased.

    [0074] Whereas, if the judging condition of the step S686 is satisfied, a step S690 is performed to judge whether the selected row is the last row of the MRAM cell array. If the judging condition of the step S690 is not satisfied, a next selected row is determined (Step S692). Whereas, if the judging condition of the step S690 is satisfied, the random code generating process is ended. After the random code generating process is ended, an m×n-bit random code is stored in the MRAM cell array.

    [0075] FIGS. 7A and 7B schematically illustrate the operations of the random code generating method when the enroll action and the verification action of the magnetoresistive random access memory are performed.

    [0076] As shown in FIG. 7A, the storage elements R.sub.1,1˜R.sub.m,2n in all of the MRAM cells c.sub.1,1˜c.sub.m,2n of the MRAM cell array have been programmed into the AP state.

    [0077] For example, the first row is the selected row. The word line WL1 receives the on voltage V.sub.ON, and the other word lines WL2˜WLm receives an off voltage V.sub.oFF. The selected row contains 2n MRAM cells c.sub.1,1˜c.sub.1,2n. That is, the selected row contains n MRAM cell pairs. When the enroll action of the magnetoresistive random access memory on the selected row is started, all of the n MRAM cell pairs in the selected row have not passed the verification action. Consequently, n MRAM cell pairs are subjected to the enroll actions sequentially. In other words, n enroll actions are performed sequentially.

    [0078] Please refer to FIG. 7A again. While the first enroll action is performed, the first bit line pair (i.e., the bit lines BL1 and BLn+1) are connected to the current source 610 through the select circuit 630, and the source lines SL1˜SL2n are connected to the ground terminal to receive the ground voltage (i.e., 0V). That is, the MRAM cells c.sub.1,1 and c.sub.1,n+1 are collaboratively formed as a first MRAM cell pair of the selected row. Consequently, the control current I.sub.ctrl generated by the current source 610 is divided into two portions (i.e., the write currents I.sub.W1 and I.sub.W2), wherein I.sub.ctrl=I.sub.W1+I.sub.W2. The two portions of the control current I.sub.ctrl flow to the two MRAM cells c.sub.1,1 and c.sub.1,n+1, respectively.

    [0079] Similarly, while the second enroll action is performed, the second bit line pair (i.e., the bit lines BL2 and BLn+2) are connected to the current source 610 through the select circuit 630. That is, the MRAM cells c.sub.1,2 and c.sub.1,n+2 are collaboratively formed as a second MRAM cell pair of the selected row. Consequently, the control current I.sub.ctrl generated by the current source 610 is divided into two portions (i.e., the write currents I.sub.W1 and I.sub.W2), wherein I.sub.ctrl=I.sub.W1+I.sub.W2. The two portions of the control current I.sub.ctrl flow to the two MRAM cells c.sub.1,2 and c.sub.1,n+2, respectively. The above procedures are repeatedly performed until the n-th enroll action is completed.

    [0080] After the n enroll actions are completed, n verification actions are performed. Please refer to FIG. 7B. While the first verification action is performed, the first bit line pair (i.e., the bit lines BL1 and BLn+1) are respectively connected to the first input terminal of the sensing element 652 and the first input terminal of the sensing element 654 through the select circuit 630, and the source lines SL1-SL2n receives a read voltage V.sub.R. That is, the MRAM cells c.sub.1,1 and c.sub.1,n+1 are collaboratively formed as a first MRAM cell pair of the selected row. Consequently, the read currents I.sub.R1 and I.sub.R2 generated by the MRAM cells c.sub.1,1 and c.sub.1,n+1 flow to the sensing elements 652 and 654, respectively. By comparing the read current I.sub.R1 with the reference current I.sub.ref, the sensing element 652 generates a sensing signal S.sub.S1. By comparing the read current I.sub.R2 with the reference current I.sub.ref, the sensing element 654 generates a sensing signal S.sub.S2. According to the sensing signals S.sub.S1 and S.sub.S2, the judging element 660 generates a verification signal V.sub.pass to indicate whether the first MRAM cell pair passes the verification action or not. While the second verification action is performed, the second bit line pair (i.e., the bit lines BL2 and BLn+2) are respectively connected to the first input terminal of the sensing element 652 and the first input terminal of the sensing element 654 through the select circuit 630, and the source lines SL1-SL2n receives a read voltage V.sub.R. That is, the MRAM cells c.sub.1,2 and c.sub.1,n+2 are collaboratively formed as a second MRAM cell pair of the selected row. Consequently, the read currents I.sub.R1 and I.sub.R2 generated by the MRAM cells c.sub.1,2 and c.sub.1,n+2 flow to the sensing elements 652 and 654, respectively. By comparing the read current I.sub.R1 with the reference current I.sub.ref, the sensing element 652 generates a sensing signal S.sub.S1. By comparing the read current I.sub.R2 with the reference current I.sub.ref, the sensing element 654 generates a sensing signal S.sub.S2. According to the sensing signals S.sub.S1 and S.sub.S2, the judging element 660 generates a verification signal V.sub.pass to indicate whether the first MRAM cell pair passes the verification action or not.

    [0081] The above procedures are repeatedly performed until the n-th verification action is completed.

    [0082] If at least one MRAM cell pair of the selected row fails to pass the verification actions after the n-th enroll action and the n-th verification action are completed, the control current I.sub.ctrl is increased according to the control signal S.sub.ctrl. Then, the MRAM cell pairs of the selected row failing to pass the verification action are subjected to the enroll action and the verification action again. For example, x MRAM cell pairs of the selected row fail to pass the verification action. After these x MRAM cell pairs are sequentially subjected to the enroll actions according to the increased control current I.sub.ctrl, these x MRAM cell pairs are sequentially subjected to x verification actions. The above procedures are repeatedly performed until all MRAM cell pairs of the selected row pass the verification actions.

    [0083] When the first MRAM cell pair passes the verification action, it is only able to confirm that the two MRAM cells of the first MRAM cell pair have different storage states. However, it is unable to realize which of the two MRAM cells has been changed to the P state. Consequently, after all of the MRAM cells of the m×2n MRAM cell array pass the verification actions, it means that the MRAM cell array has generated an m×n-bit random code.

    [0084] Please refer to FIG. 6A again. In an embodiment, the m×n-bit random code can be stored in the first n MRAM cells of each row in the MRAM cell array, i.e., the MRAM cells c.sub.1,1˜c.sub.m,n. In another embodiment, the m×n-bit random code can be stored in the last n MRAM cells of each row in the MRAM cell array, i.e., the MRAM cells c.sub.1,n+1˜c.sub.m,2n. In case that an external circuit (not shown) intends to use the random code, the external circuit can perform a read action on the magnetoresistive random access memory to retrieve the random code from the MRAM cells c.sub.1,1˜c.sub.m,n or the MRAM cells c.sub.1,n+1˜c.sub.m,2n of the MRAM cell array.

    [0085] From the above descriptions, the present invention provides a magnetoresistive random access memory (MRAM) for a physically unclonable function (PUF) technology according to the characteristics of the magnetoresistive random access memory. The present invention also provides a random code generating method for allowing the magnetoresistive random access memory to generate random codes.

    [0086] While the invention has been described in terms of what is presently considered to be the most practical and preferred embodiments, it is to be understood that the invention needs not be limited to the disclosed embodiment. On the contrary, it is intended to cover various modifications and similar arrangements included within the spirit and scope of the appended claims which are to be accorded with the broadest interpretation so as to encompass all such modifications and similar structures.