Chip protection circuit and chip
Through the combination of the rectangular pulse signal generation circuit and the signal comparison circuit, the signals of the protective layer and the metal circuit below are compared to generate an alarm signal, which solves the problem of insufficient detection strength of the existing chip protection circuit and improves the safety and reliability of the chip.
Patent Information
- Application Number
- CN202420595020.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-25
- Publication Date
- 2024-11-19
- Estimated Expiration
- 2034-03-25
AI Technical Summary
The detection strength of existing chip protection circuits is weak and cannot effectively detect physical attacks, resulting in the threat of chip security.
The rectangular pulse signal generation circuit and the signal comparison circuit are used to compare the rectangular pulse waveform excitation signal through the first metal line of the protective layer and the second metal line below to generate an alarm signal to determine whether the chip circuit is damaged.
The detection of metal lines on the protective layer is improved, the safety and reliability of the chip protection circuit is enhanced, and it can promptly detect whether the chip circuit is damaged.
Smart Images

Figure CN222028612U_ABST
Abstract
Description
Technical Field
[0001] The utility model relates to the field of chip design, in particular to a chip protection circuit and a chip. Background Art
[0002] With the continuous development of chip technology, technologies that threaten chip security are also developing. Since data storage in chips must rely on internal physical media, some physical attack technologies targeting these chip storage media have gradually been mastered by some illegal attackers, which has seriously challenged the security of chips. For example, attackers use invasive physical attack technologies such as laser technology or focused ion beam (FIB) technology to purposefully cut the chip circuit and destroy the chip circuit structure. They also conduct node tests on the chip circuit, first determine the test nodes, and then add probe tests to steal information from the chip, or inject modified data into the chip.
[0003] In order to detect the above physical attacks, the related art uses one or more layers of metal wiring to shield the physical structure under the metal layer in the integrated circuit chip to protect the key components. In addition, a chip protection circuit is added above the chip security area, which is composed of a signal generating circuit, a signal comparator and multiple lines. The signal generating circuit generates multiple signals and sends them out in two ways. One way is to send them to the signal comparator through the metal line of the protective layer, and the other way is to send them to the signal comparator through the lower metal line. Then, by comparing the signal of the metal line passing through the protective layer with the signal passing through the lower metal line, it is determined whether the metal line of the protective layer is damaged.
[0004] However, the detection strength of the chip protection circuit in the related art is relatively weak. For example, the signal generating circuit in the related art is generally a random number generating circuit, and the level state of the pseudo-random number signal generated and outputted in any path remains unchanged, resulting in insufficient protection capability and weak detection strength. Utility Model Content
[0005] In order to solve the problem of weak detection strength of chip protection circuits in related technologies, the present application provides a chip protection circuit and a chip. Compared with the related technologies, a rectangular pulse signal generating circuit generates an excitation signal with a rectangular pulse waveform, and the level state of the excitation signal jumps over time, thereby improving the detection strength of the metal line of the protection layer, thereby improving the safety and reliability of the chip protection circuit.
[0006] In a first aspect, an embodiment of the present application provides a chip protection circuit, including:
[0007] A rectangular pulse signal generating circuit, a signal comparing circuit, a first metal circuit arranged on the protective layer, and a second metal circuit arranged below the protective layer; the rectangular pulse signal generating circuit is connected to the signal comparing circuit through the first metal circuit and the second metal circuit respectively;
[0008] The rectangular pulse signal generating circuit is used to generate an excitation signal with a rectangular pulse waveform, and output the excitation signal through the first metal line and the second metal line respectively;
[0009] The signal comparison circuit is used to compare the first excitation signal and the second excitation signal to generate an alarm signal; wherein the first excitation signal is an excitation signal via a first metal line, and the second excitation signal is an excitation signal via a second metal line.
[0010] In a second aspect, an embodiment of the present application provides a chip, including: the chip protection circuit described in the first aspect.
[0011] In the utility model, the chip protection circuit includes a rectangular pulse signal generating circuit, a signal comparison circuit, a first metal line arranged in the protection layer, and a second metal line arranged below the protection layer; the rectangular pulse signal generating circuit is connected to the signal comparison circuit through the first metal line and the second metal line respectively; the rectangular pulse signal generating circuit is used to generate an excitation signal of a rectangular pulse waveform, and output the excitation signal through the first metal line and the second metal line respectively; the signal comparison circuit is used to compare the first excitation signal and the second excitation signal to generate an alarm signal; wherein the first excitation signal is an excitation signal via the first metal line, and the second excitation signal is an excitation signal via the second metal line. In this way, in the scenario where the first metal line of the protection layer is damaged by a physical attack, the first excitation signal via the first metal line of the protection layer can be compared with the originally generated second excitation signal through digital devices such as the rectangular pulse signal generating circuit and the signal comparison circuit, and an alarm signal is generated to determine whether the circuit of the chip is damaged. Moreover, compared with the related art, the rectangular pulse signal generating circuit generates an excitation signal of a rectangular pulse waveform, and the level state of the excitation signal jumps over time, which improves the detection strength of the first metal line of the protection layer, thereby improving the safety and reliability of the chip protection circuit. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the embodiments of the present invention and do not constitute an improper limitation on the present invention. In the drawings:
[0013] Figure 1 A schematic diagram of the working logic principle of a chip protection circuit provided in an embodiment of the present application;
[0014] Figure 2 A schematic diagram of a chip protection circuit provided in an embodiment of the present application;
[0015] Figure 3 A structural schematic diagram of another chip protection circuit provided in an embodiment of the present application;
[0016] Figure 4 A structural schematic diagram of another chip protection circuit provided in an embodiment of the present application;
[0017] Figure 5 A schematic structural diagram of a rectangular pulse signal generating circuit provided in an embodiment of the present application;
[0018] Figure 6 A timing diagram of a rectangular pulse signal generating circuit provided in an embodiment of the present application;
[0019] Figure 7-1 A structural schematic diagram of another chip protection circuit provided in an embodiment of the present application;
[0020] Figure 7-2 A structural schematic diagram of a signal comparison circuit provided in an embodiment of the present application;
[0021] Figure 7-3 Provided in the embodiments of this application Figure 7-2 The corresponding timing diagram of the signal comparison circuit;
[0022] Figure 8-1 A structural schematic diagram of another chip protection circuit provided in an embodiment of the present application;
[0023] Figure 8-2 A structural schematic diagram of another signal comparison circuit provided in an embodiment of the present application;
[0024] Figure 8-3 Provided in the embodiments of this application Figure 8-2 The corresponding timing diagram of the signal comparison circuit;
[0025] Fig. 9 A structural schematic diagram of a chip provided in an embodiment of the present application.
[0026] Description of reference numerals:
[0027] 10-chip protection circuit; 100-rectangular pulse signal generating circuit; 110-counter; 120-D flip-flop; 130-first comparator; 140-selector; 200-signal comparison circuit; 210-exclusive OR circuit; 220-second comparator; 230-exclusive OR circuit; 240-third comparator; 300-first metal line; 400-second metal line; 500-buffer; 20-chip. DETAILED DESCRIPTION
[0028] In order to make the purpose, technical solution and advantages of the present application clearer, the technical solution of the present application will be clearly described below in conjunction with the specific embodiments of the present application and the corresponding drawings. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present application.
[0029] The term "first" or "second" in the specification and claims of this application may include one or more of the features explicitly or implicitly. In the description of this application, unless otherwise specified, "multiple" means two or more. In addition, "and / or" in the specification and claims means at least one of the connected objects, and the character " / " generally means that the objects connected before and after are in an "or" relationship.
[0030] In the description of this application, it should be noted that, unless otherwise clearly specified and limited, the terms "installed", "connected", and "connected" should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be indirectly connected through an intermediate medium, or it can be the internal communication of two elements. For ordinary technicians in this field, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0031] As described in the background technology, the signal generating circuit in the related technology is generally a random number generating circuit, and the level state of the pseudo-random number signal generated and outputted in any path always remains unchanged, resulting in insufficient protection capability of the metal circuit of the protective layer and weak detection strength.
[0032] Based on this, an embodiment of the present application provides a chip protection circuit. In a scenario where the first metal line of the protection layer is damaged by a physical attack, the chip protection circuit can compare the first excitation signal of the first metal line passing through the protection layer with the originally generated second excitation signal through digital devices such as a rectangular pulse signal generating circuit and a signal comparison circuit, generate an alarm signal, and determine whether the chip circuit is damaged. Moreover, compared with the related art, the excitation signal of a rectangular pulse waveform is generated by the rectangular pulse signal generating circuit, and the level state of the excitation signal jumps over time, thereby improving the detection strength of the first metal line of the protection layer, thereby improving the safety and reliability of the chip protection circuit.
[0033] The technical solution provided by the utility model is described in detail below in conjunction with the accompanying drawings.
[0034] For example, Figure 1 As shown, the working logic principle of the chip protection circuit provided by the embodiment of the present application may include: an excitation generation module (for example, a rectangular pulse signal generating circuit) generates a 64-bit excitation signal (for example, cmp_value_in[63:0]), which is sent to 64 metal lines in the protection layer (each 1-bit value corresponds to a metal line), and after passing through the protection layer, it is sent to a feedback comparison module (for example, a signal comparison circuit) to obtain a second excitation signal (for example, cmp_value_out[63:0]), and the second excitation signal is compared with the excitation signal (for example, cmp_value_in[63:0]) generated by the excitation generation module. If the comparison results of any one or several of the metal lines are different, the feedback comparison module sends an alarm signal (for example, an alarm signal), indicating that the chip is under attack.
[0035] It should be pointed out that in order to improve the security of the chip, the chip protection circuit provided in the embodiment of the present application can be applied to any type of chip, so as to timely and reliably detect whether the circuit of the chip is damaged.
[0036] Figure 2 A structural schematic diagram of a chip protection circuit provided in an embodiment of the present application.
[0037] like Figure 2 As shown, the chip protection circuit 10 provided in the embodiment of the present application may include:
[0038] A rectangular pulse signal generating circuit 100, a signal comparing circuit 200, a first metal line 300 arranged on a protective layer, and a second metal line 400 arranged below the protective layer; the rectangular pulse signal generating circuit 100 is connected to the signal comparing circuit 200 through the first metal line 300 and the second metal line 400 respectively;
[0039] The rectangular pulse signal generating circuit 100 is used to generate an excitation signal of a rectangular pulse waveform, and output the excitation signal through a first metal line and a second metal line respectively;
[0040] The signal comparison circuit 200 is used to compare a first excitation signal and a second excitation signal to generate an alarm signal; wherein the first excitation signal is an excitation signal via a first metal line, and the second excitation signal is an excitation signal via a second metal line.
[0041] The protection layer may be located at the top layer of the protection area of the chip. The protection area of the chip may be a multi-layer structure. The core circuits and key components to be protected are arranged below the top layer of the protection area.
[0042] Among them, the second metal circuit 400 can be arranged below the protective layer, wherein below the protective layer can be understood as the lower layer of the top layer in the protective area, and can also be understood as the lower layer of the top layer in the non-protective area, to ensure that the second metal circuit 400 is arranged in the lower layer of the first metal circuit. The present application does not limit the specific area of the second metal circuit 400.
[0043] In an embodiment of the present application, in a scenario where the first metal line of the protective layer is damaged by a physical attack, the rectangular pulse signal generating circuit 100 first generates an excitation signal, and then the signal comparison circuit 200 compares the first excitation signal of the first metal line passing through the protective layer with the originally generated second excitation signal to generate an alarm signal to determine whether the circuit of the chip is damaged.
[0044] Moreover, in the embodiment of the present application, since the rectangular pulse signal generating circuit 100 and the signal comparison circuit 200 can both be digital devices, there is no need to use analog devices to detect whether the resistance value of the metal circuit has changed, thereby improving the reliability of detecting whether the circuit of the chip is damaged.
[0045] Moreover, in the embodiment of the present application, the rectangular pulse signal generating circuit 100 generates an excitation signal with a rectangular pulse waveform, and the level state of the excitation signal changes over time, thereby improving the detection strength of the first metal line of the protective layer, thereby improving the safety and reliability of the chip protection circuit.
[0046] According to the chip protection circuit provided by the embodiment of the present application, it includes a rectangular pulse signal generating circuit, a signal comparison circuit, a first metal line arranged in the protection layer, and a second metal line arranged under the protection layer; the rectangular pulse signal generating circuit is connected to the signal comparison circuit through the first metal line and the second metal line respectively; the rectangular pulse signal generating circuit is used to generate an excitation signal, and output the excitation signal through the first metal line and the second metal line respectively; the signal comparison circuit is used to compare the first excitation signal and the second excitation signal to generate an alarm signal; wherein the first excitation signal is an excitation signal via the first metal line, and the second excitation signal is an excitation signal via the second metal line. In this way, in the scenario where the first metal line of the protection layer is damaged by a physical attack, the first excitation signal via the first metal line of the protection layer can be compared with the originally generated second excitation signal through digital devices such as the rectangular pulse signal generating circuit and the signal comparison circuit, and an alarm signal is generated to determine whether the circuit of the chip is damaged. Moreover, compared with the related art, the rectangular pulse signal generating circuit generates an excitation signal of a rectangular pulse waveform, and the level state of the excitation signal jumps over time, which improves the detection strength of the first metal line of the protection layer, thereby improving the safety and reliability of the chip protection circuit.
[0047] It is understandable that in practical applications, when a first metal line is very long, the line load capacitance is very large, resulting in a large delay. At this time, a buffer is inserted into the first metal line to divide the first metal line into multiple sections. The load driven by each buffer is small, which can effectively reduce the delay and avoid insufficient driving capability due to the line being too long. Furthermore, in the case where a first metal line is very long, by inserting at least one buffer, the first metal line is divided into multiple sections, which effectively reduces the delay and increases the signal driving capability.
[0048] In a specific embodiment, the chip protection circuit 10 provided in the embodiment of the present application may further include at least one buffer 500 , and the at least one buffer 500 is disposed on the first metal line 300 .
[0049] For example, Figure 3 As shown, a buffer 500 is inserted at the midpoint of each first metal line 300 .
[0050] Of course, in practical applications, the embodiment of the present application can select one or more first metal lines according to the length of the first metal line, and insert one or more buffers in the selected insertion position. The number of first metal lines selected, the number of buffers inserted, and the insertion position can be set according to actual needs, and the present application does not limit this.
[0051] The buffer 500 may include two inverters connected in series. Of course, the buffer 500 may also be composed of other similar structures, which is not limited in the present application.
[0052] In another specific embodiment, in order to improve the detection range and detection accuracy, multiple metal lines are fully and comprehensively arranged in the protection area, the first metal line may include N lines, and correspondingly, the excitation signal includes N lines, and the second metal line also includes N lines, where N is an integer greater than 1;
[0053] The rectangular pulse signal generating circuit is specifically used to generate N excitation signals, and output the N excitation signals through N first metal lines respectively, and output the N excitation signals through N second metal lines respectively.
[0054] For example, Figure 3 As shown, taking N as 64 as an example, the first metal lines may include 64, and correspondingly, the second metal lines also include 64, and the rectangular pulse signal generating circuit 100 is used to generate a 64-bit excitation signal cmp_value_in[63:0], and output the 64 excitation signals through 64 first metal lines and 64 second metal lines respectively, wherein each first metal line / second metal line outputs 1 bit of data;
[0055] Among them, Figure 3 As shown, the signal comparison circuit 200 is used to compare whether the value of each bit of the first excitation signal cmp_value_out[63:0] and the second excitation signal cmp_value_in[63:0] is the same, and generate an alarm signal (eg, an alarm signal).
[0056] Among them, Figure 3 As shown, the chip can provide clk signal, en signal and rst signal to the rectangular pulse signal generating circuit 100 and the signal comparing circuit 200, where clk is a clock signal, en is an enable signal and rst is a reset signal, to ensure that the rectangular pulse signal generating circuit 100 and the signal comparing circuit 200 operate normally.
[0057] In practical applications, the first metal line disposed on the protective layer may be damaged, and thus the first excitation signal cmp_value_out[63:0] may be different from the original excitation signal cmp_value_in[63:0] generated by the rectangular pulse signal generating circuit 100. The second metal line 400 disposed under the protective layer is generally not damaged, and the second excitation signal is generally the same as the original excitation signal cmp_value_in[63:0] generated by the rectangular pulse signal generating circuit 100. Thus, the second excitation signal may be recorded as cmp_value_in[63:0].
[0058] In practical applications, the N excitation signals are all rectangular pulse waveform signals, and the level states of the N excitation signals all change over time. Among them, the rectangular pulse waveform is a periodic waveform. In one cycle, the waveform will remain at one level for a period of time, and then remain at another level for a period of time.
[0059] For example, Figure 4 As shown, the level state of the excitation signal cmp_value_in[0] corresponding to the first metal line jumps over time, and the level state of the excitation signal cmp_value_in[1] corresponding to the second metal line jumps over time.
[0060] In this way, the level state of the excitation signal corresponding to each first metal line is prevented from always remaining unchanged, thereby improving the detection strength of the first metal line.
[0061] Furthermore, in practical applications, the detection strength of the first metal line can be adjusted by changing the duty cycle of the excitation signal.
[0062] In addition, in a specific embodiment, among the N excitation signals output by the rectangular pulse signal generating circuit, the level states of two adjacent excitation signals at the same time are different.
[0063] For example, Figure 4 As shown, for the adjacent first first metal line and the second first metal line, cmp_value_in[0] and cmp_value_in[1] correspond to the two adjacent metal lines in the protection layer, and the level state of the excitation signal cmp_value_in[0] corresponding to the first first metal line is different from the level state of the excitation signal cmp_value_in[1] corresponding to the second first metal line.
[0064] In this way, when a plurality of adjacent first metal lines in the protection layer are damaged, changes in corresponding excitation signals when two adjacent first metal lines are damaged are also different, which can make the detection of the protection layer more sensitive.
[0065] In a specific embodiment, the rectangular pulse signal generating circuit 100 can be used to use customized pattern data (such as the second preset value A[63:0] and the third preset value B[63:0] mentioned below) to perform alternating assignment to generate an excitation signal to ensure that the level states of the excitation signals in two adjacent metal lines are different.
[0066] For example, taking N as 64, the first metal lines may include 64 lines, and correspondingly, the second metal lines also include 64 lines. The second preset value A[63:0]=64'h55555555555555555 (hexadecimal)=64'b0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101 (binary) is predefined, and the third preset value B[63:0]=64'haaaa aaaaaaaaaaaaa (hexadecimal) = 64'b1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010.
[0067] Among them, the rectangular pulse signal generating circuit 100 can be used to select the second preset value A[63:0] and the third preset value B[63:0] to alternately assign the excitation signal cmp_value_in[63:0] according to the counting status of a counter 110, so as to ensure that the level state of the excitation signal in each metal line changes over time, and the level states of the excitation signal in two adjacent metal lines are different.
[0068] Specifically, if Figure 5 As shown, in a specific embodiment, in the chip protection circuit 10 provided in the embodiment of the present application, the rectangular pulse signal generating circuit 100 may include: a counter 110, a D flip-flop 120, a first comparator 130 and a selector 140;
[0069] The counter 110 is connected to the input terminal (i.e., the D terminal) of the D flip-flop 120 and the output terminal (i.e., the Q terminal) of the D flip-flop 120. The output terminal of the D flip-flop 120 is also connected to the first input terminal of the first comparator 130. The second input terminal of the first comparator 130 is used to input a first preset value (e.g., 9'hff); wherein the first preset value may be less than the maximum count value (e.g., 9'h1ff) of the counter 100.
[0070] The selector 140 has a first input terminal, a second input terminal, a control terminal and an output terminal; the output terminal of the first comparator 130 is connected to the control terminal of the selector 140, the first input terminal of the selector 140 is used to input a second preset value (e.g., A[63:0]), the second input terminal of the selector 140 is used to input a third preset value (e.g., B[63:0]), and the output terminal of the selector 140 is used to output an excitation signal (e.g., cmp_value_in[63:0]);
[0071] In an embodiment of the present application, the second preset value includes N digits, the third preset value includes N digits, the value of the nth digit in the N digits of the third preset value is different from the value of the nth digit in the N digits of the second preset value, and n is an integer less than N.
[0072] Wherein, n is an integer counting from 0, and n is less than N.
[0073] Taking N as 64 as an example, the second preset value A[63:0]=64'h55555555555555555 (hexadecimal)=64'b0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101 1 (binary), the third preset value B[63:0]=64'haaaaaaaaaaaaaaaaaaa (hexadecimal)=64'b1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010.
[0074] The rectangular pulse signal generating circuit 100 generates 64 excitation signals. The 64 excitation signals are composed of two self-defined pattern data A[63:0]=64'h5555555555555555=64'b0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101_0101 and B[63:0]=64'haaaaaaaaaaaaaaa=64 'b1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010_1010 alternating assignment, A[63:0] is a 64-bit signal, each bit of which is defined as: A[0]=1, A[1]=0, A[2]=1, A[3]=0, …, A
[63] =0. It can be seen that in the 64 bits of A[63:0], the values of adjacent bits are different. B[63:0] is a 64-bit signal, and each bit is defined as: B[0]=0, B[1]=1, B[2]=0, B[3]=1, ..., B
[63] =1. In addition, it can be seen that A[0] is different from B[0], A[1] is different from B[1], and so on. A
[63] is different from B
[63] . The value of each bit in A[63:0] is different from the value of the corresponding bit in B[63:0].
[0075] like Figure 5 As shown, cnt is the defined counting signal, clk is the clock signal, and the first comparator 130 can be used to compare the output value Q of the output end (i.e., the Q end) of the D flip-flop 120 with the first preset value 9'hff (hexadecimal). If Q is greater than the first preset value 9'hff, the first comparator 130 outputs the signal cmp_out in a high level state; if Q is less than the first preset value 9'hff, the first comparator 130 outputs the signal cmp_out in a low level state. The counting signal cnt of the counter 110 is continuously increased by 1 under the triggering of the clock signal. The bit width of the counter 110 can be preset to 10 bits, and the maximum count value of the counter 110 is 9'h1ff. Therefore, when the maximum count of the counter 110 reaches 9'h1ff, it will return to 0, and the cycle will repeat. The timing diagram is shown in Figure 6 shown.
[0076] Among them, Figure 6As shown, cmp_value_in[0] is the first (i.e., the 0th bit) of the 64 excitation signals generated by the rectangular pulse signal generating circuit 100. Under the counting of the counter 110, it undergoes different jumps according to the output signal cmp_out of the first comparator 130. For example, when the output signal cmp_out of the first comparator 130 is 0, the selector 140 selects to assign cmp_value_in[0] to the 0th bit of A[63:0], i.e., A[0]=1. When the output signal cmp_out of the first comparator 130 is 1, the selector 140 selects to assign cmp_value_in[0] to the 0th bit of B[63:0], i.e., B[0]=0. This achieves that the value of cmp_value_in[0] can jump over time according to the counting of the counter 110.
[0077] According to the same principle, the values of cmp_value_in[1], ..., cmp_value_in
[63] can also change over time according to the count of the counter 110. In this way, the level state of the excitation signal cmp_value_in[n] corresponding to each metal line is prevented from always remaining unchanged, thereby improving the detection strength of the first metal line.
[0078] Furthermore, the first preset value reflects the time required for the excitation signal to jump. Figure 5 Also, the maximum count value of the counter 110 (eg, 9'h1ff) reflects a cycle time of the excitation signal and can also be set according to actual needs, which is not specifically limited in this application.
[0079] In practical applications, the present application can adjust the duty cycle of the excitation signal by presetting a suitable first preset value and the maximum count value of the counter 110, and then adjust the detection strength of the first metal circuit to improve the flexibility of the chip protection circuit.
[0080] In addition, among the N excitation signals output by the rectangular pulse signal generating circuit, the level states of two adjacent excitation signals at the same time may be different, which can be specifically achieved in the following manner: in the N-bit number of the second preset value, the values of adjacent digits are different; in the N-bit number of the third preset value, the values of adjacent digits are different.
[0081] For example, the values of adjacent bits in each bit of A[63:0] are different, and the values of adjacent bits in each bit of B[63:0] are different, thereby ensuring that the values of adjacent bits in cmp_value_in[0], cmp_value_in[1], ..., cmp_value_in
[63] are also different, that is, among the N excitation signals output by the rectangular pulse signal generating circuit, the level states of two adjacent excitation signals at the same time can be different.
[0082] In this way, when multiple adjacent first metal lines in the protection layer are attacked, by using excitation signals of different levels for adjacent metal lines in the protection area, changes in the corresponding excitation signals of the damaged multiple adjacent first metal lines are also different, which can make the detection of the protection layer more sensitive.
[0083] In another specific embodiment, Figure 7-1 As shown, in the chip protection circuit 10 provided in the embodiment of the present application, the signal comparison circuit 200 may include an XOR circuit 210 and a second comparator 220;
[0084] The XOR circuit 210 includes a first input terminal, a second input terminal and an output terminal. The rectangular pulse signal generating circuit 100 is connected to the first input terminal of the XOR circuit 210 through the first metal line 300, and the rectangular pulse signal generating circuit 100 is connected to the second input terminal of the XOR circuit 210 through the second metal line 400. The output terminal of the XOR circuit 210 is connected to the first input terminal of the second comparator 220. The second input terminal of the second comparator 220 is used to input a fourth preset value, and the output terminal of the second comparator 220 is used to output an alarm signal.
[0085] The function of the XOR circuit 210 is that when the two input signals are the same, the output is 0, and if the two input signals are different, the output is 1. This is used to determine whether the original first excitation signal is the same as the second excitation signal after passing through the protective layer. If they are the same, it means that the metal circuit of the protective layer is not damaged, and if they are different, it means that the metal circuit of the protective layer is being damaged.
[0086] For example, when both the first metal line 300 and the second metal line 400 include N pieces, the XOR circuit 210 includes N pieces; the first input end of the second comparator 220 includes N interfaces;
[0087] The rectangular pulse signal generating circuit 100 is connected to the first input terminal of the i-th XOR circuit 210 through the i-th first metal line, the rectangular pulse signal generating circuit 100 is connected to the second input terminal of the i-th XOR circuit 210 through the i-th second metal line, and the output terminal of the i-th XOR circuit 210 is connected to the i-th interface of the first input terminal of the second comparator 220, where i is less than or equal to N.
[0088] For example, Figure 7-2 As shown, when the first metal line 300 and the second metal line 400 both include 64 lines, the XOR circuit 210 includes 64 lines; the first input end of the second comparator 220 includes 64 interfaces; the rectangular pulse signal generating circuit 100 is connected to the first input end of the i-th XOR circuit 210 through the i-th first metal line, the rectangular pulse signal generating circuit 100 is connected to the second input end of the i-th XOR circuit 210 through the i-th second metal line, and the output end of the i-th XOR circuit 210 is connected to the i-th interface of the first input end of the second comparator 220.
[0089] In the embodiment of the present application, the working principle of the signal comparison circuit 200 includes, performing XOR processing on the 64 groups of excitation signals through 64 XOR circuits 210, and obtaining the XOR result as cmp_result[63:0], and then comparing the XOR result cmp_result[63:0] with the preset fourth preset value (for example, 64'h0000000000000000 (hexadecimal)) in the second comparator 220, and comparing each bit separately. Once one comparison result is different, the second comparator 220 pulls up the alarm signal (maintains a high level state), indicating that the second excitation signal passing through the protective layer is different from the original first excitation signal, and the protective layer is being damaged. If the comparison results of the 64 bits are all the same, the alarm signal is not pulled up (maintains a low level state).
[0090] In the embodiment of the present application, the detection principle of any one or more of the 64 first metal lines passing through the protective layer being damaged is the same. Taking the first first metal line as an example, Figure 7-3As shown, the cmp_value_out[0] corresponding to the first first metal line after the protection layer is set to 0, that is, it simulates that the first first metal line corresponding to cmp_value_out[0] is damaged. When the metal line corresponding to cmp_value_out[0] is damaged, cmp_value_out[0] is 0. When cmp_value_in[0] is different from cmp_value_out[0], the XOR result cmp_result[0] is pulled high (maintained at a high level), and the second comparator 220 is used to compare the XOR result cmp_result[0] (i.e., "1" value) of cmp_value_in[0] and cmp_value_out[0] with the 0th bit (i.e., "0" value) of the preset fourth preset value (e.g., 64'h0000000000000000). If the two are different, the alarm signal will also be pulled high (maintained at a high level), indicating that the line is damaged, and an alarm signal is sent to notify other modules to alarm.
[0091] In addition, in practical applications, in other embodiments, the fourth preset value can also be set to other values, and the comparison logic of the second comparator 220 is adjusted accordingly. For example, the fourth preset value is 64'hffffffffffffffff. When the metal line corresponding to cmp_value_out[0] is damaged, cmp_value_out[0] is 0. When cmp_value_in[0] is different from cmp_value_out[0], the XOR result cmp_result[0] is pulled high (maintained in a high level state), and the second comparator 220 is used to compare the XOR result cmp_result[0] of cmp_value_in[0] and cmp_value_out[0] (i.e., "1" value) with the 0th bit (i.e., "1" value) of the preset fourth preset value (e.g., 64'hffffffffffff fffff). If the two are the same, the alarm signal will also be pulled high (maintained in a high level state), indicating that the line is damaged, and an alarm signal is sent to notify other modules to alarm.
[0092] In another specific embodiment, Figure 8-1 As shown, in the chip protection circuit 10 provided in the embodiment of the present application, the signal comparison circuit 200 may include an XOR circuit 230 and a third comparator 240;
[0093] The X-OR circuit 230 includes a first input terminal, a second input terminal and an output terminal. The rectangular pulse signal generating circuit 100 is connected to the first input terminal of the X-OR circuit 230 through the first metal line 300, and the rectangular pulse signal generating circuit 100 is connected to the second input terminal of the X-OR circuit 230 through the second metal line 400. The output terminal of the X-OR circuit 230 is connected to the first input terminal of the third comparator 240. The second input terminal of the third comparator 240 is used to input the fifth preset value, and the output terminal of the third comparator 240 is used to output an alarm signal.
[0094] The function of the XOR circuit 230 is that when the two input signals are the same, the output is 1, and if the two input signals are different, the output is 0. This is used to determine whether the original first excitation signal is the same as the second excitation signal after passing through the protective layer. If they are the same, it means that the metal circuit of the protective layer is not damaged. If they are different, it means that the metal circuit of the protective layer is being damaged.
[0095] For example, when both the first metal line 300 and the second metal line 400 include N pieces, the XNOR circuit 230 includes N pieces; the first input end of the third comparator 240 includes N interfaces;
[0096] The rectangular pulse signal generating circuit 100 is connected to the first input terminal of the jth X-OR circuit 230 through the jth first metal line, the rectangular pulse signal generating circuit 100 is connected to the second input terminal of the jth X-OR circuit 230 through the jth second metal line, and the output terminal of the jth X-OR circuit 230 is connected to the jth interface of the first input terminal of the third comparator 240, where j is less than or equal to N.
[0097] For example, Figure 8-2 As shown, when the first metal line 300 and the second metal line 400 each include 64 lines, the X-OR circuit 230 includes 64 lines; the first input end of the third comparator 240 includes 64 interfaces; the rectangular pulse signal generating circuit 100 is connected to the first input end of the j-th X-OR circuit 230 through the j-th first metal line, the rectangular pulse signal generating circuit 100 is connected to the second input end of the j-th X-OR circuit 230 through the j-th second metal line, and the output end of the j-th X-OR circuit 230 is connected to the j-th interface of the first input end of the third comparator 240.
[0098] The working principle of the signal comparison circuit 200 includes: performing XOR processing on the 64 groups of excitation signals through 64 XOR circuits 230, and obtaining the XOR result as cmp_result[63:0]. Subsequently, in the third comparator 240, the XOR result cmp_result[63:0] is compared with the preset fifth preset value (for example, 64'h0000000000000000 (hexadecimal)). Each bit is compared separately. Once one comparison result is the same, the third comparator 240 pulls up the alarm signal (maintains a high level state), indicating that the second excitation signal passing through the protective layer is different from the original first excitation signal, and the protective layer is being damaged. If the comparison results of all 64 bits are different, the alarm signal is not pulled up (maintains a low level state).
[0099] In the embodiment of the present application, the detection principle of any one or more of the 64 first metal lines passing through the protective layer being damaged is the same. Taking the first first metal line as an example, Figure 8-3 As shown, the cmp_value_out[0] corresponding to the first first metal line after the protection layer is set to 0, that is, it simulates that the first first metal line corresponding to cmp_value_out[0] is damaged. When the metal line corresponding to cmp_value_out[0] is damaged, cmp_value_out[0] is 0. When cmp_value_in[0] is different from cmp_value_out[0], the exclusive OR result cmp_result[0] is pulled low (maintained at a low level), and the third comparator 240 is used to compare the exclusive OR result cmp_result[0] (i.e., "0" value) of cmp_value_in[0] and cmp_value_out[0] with the 0th bit (i.e., "0" value) of the preset fourth preset value (e.g., 64'h0000000000000000). If the two are the same, the alarm signal will also be pulled high (maintained at a high level), indicating that the line is damaged, and an alarm signal is sent to notify other modules to alarm.
[0100] In addition, in practical applications, in other embodiments, the fifth preset value can also be set to other values, and the comparison logic of the third comparator 240 is adjusted accordingly. For example, the fifth preset value is 64'hffffffffffffffff. When the metal line corresponding to cmp_value_out[0] is damaged, cmp_value_out[0] is 0. When cmp_value_in[0] is different from cmp_value_out[0], the XOR result cmp_result[0] is pulled low (maintained at a low level), and the third comparator 240 is used to compare the XOR result cmp_result[0] (i.e., "0" value) of cmp_value_in[0] and cmp_value_out[0] with the 0th bit (i.e., "1" value) of the preset fourth preset value (e.g., 64'hffffffffffff fffff). If the two are different, the alarm signal will also be pulled high (maintained at a high level), indicating that the line is damaged, and an alarm signal is sent to notify other modules to alarm.
[0101] Based on the same concept as the chip protection circuit provided in the above embodiment, the embodiment of the present application also provides a chip.
[0102] Fig. 9 A structural schematic diagram of a chip provided in an embodiment of the present application.
[0103] like Fig. 9 As shown, the chip 20 provided in the embodiment of the present application may include: the chip protection circuit 10 provided in any of the above embodiments.
[0104] It should be pointed out that the chip provided in the embodiment of the present application can realize all the functions of the chip protection circuit and achieve the same effect, which will not be repeated here.
[0105] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the utility model, rather than to limit it. Although the utility model has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solution described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solution from the spirit and scope of the technical solution of the utility model.
Claims
1. A chip protection circuit, characterized in that: include: A rectangular pulse signal generating circuit, a signal comparing circuit, a first metal circuit arranged on the protective layer, and a second metal circuit arranged below the protective layer; The rectangular pulse signal generating circuit is connected to the signal comparing circuit through the first metal line and the second metal line respectively; The rectangular pulse signal generating circuit is used to generate an excitation signal with a rectangular pulse waveform, and output the excitation signal through the first metal line and the second metal line respectively; The signal comparison circuit is used to compare a first excitation signal and a second excitation signal to generate an alarm signal; wherein the first excitation signal is an excitation signal via the first metal line, and the second excitation signal is an excitation signal via the second metal line.
2. The chip protection circuit according to claim 1, characterized in that: The first metal lines include N, the second metal lines include N, the excitation signals include N, and N is an integer greater than 1; The rectangular pulse signal generating circuit is specifically used to generate N excitation signals, and output the N excitation signals through N first metal lines respectively, and output the N excitation signals through N second metal lines respectively; Wherein, the level states of the N excitation signals all change over time.
3. The chip protection circuit according to claim 2, characterized in that: The rectangular pulse signal generating circuit comprises: a counter, a D flip-flop, a first comparator and a selector; The counter is connected to the input end of the D flip-flop and the output end of the D flip-flop, the output end of the D flip-flop is also connected to the first input end of the first comparator, and the second input end of the first comparator is used to input a first preset value; The selector has a first input terminal, a second input terminal, a control terminal and an output terminal; the output terminal of the first comparator is connected to the control terminal of the selector, the first input terminal of the selector is used to input a second preset value, the second input terminal of the selector is used to input a third preset value, and the output terminal of the selector is used to output the excitation signal; The second preset value includes an N-digit number, the third preset value includes an N-digit number, the value of the n-th digit in the N-digit number of the third preset value is different from the value of the n-th digit in the N-digit number of the second preset value, and n is an integer less than N.
4. The chip protection circuit according to claim 3, characterized in that: Among the N excitation signals output by the rectangular pulse signal generating circuit, two adjacent excitation signals have different level states at the same time; Among the N digits of the second preset value, the values of adjacent digits are different; among the N digits of the third preset value, the values of adjacent digits are different.
5. The chip protection circuit according to any one of claims 1 to 4, characterized in that: The chip protection circuit further includes at least one buffer, and the at least one buffer is disposed on the first metal line.
6. The chip protection circuit according to claim 1, characterized in that: The signal comparison circuit includes an XOR circuit and a second comparator; The XOR circuit includes a first input terminal, a second input terminal and an output terminal. The rectangular pulse signal generating circuit is connected to the first input terminal of the XOR circuit through the first metal line, and the rectangular pulse signal generating circuit is connected to the second input terminal of the XOR circuit through the second metal line. The output terminal of the XOR circuit is connected to the first input terminal of the second comparator, the second input terminal of the second comparator is used to input a fourth preset value, and the output terminal of the second comparator is used to output the alarm signal.
7. The chip protection circuit according to claim 6, characterized in that: In the case where both the first metal line and the second metal line include N lines, the XOR circuit includes N lines; the first input end of the second comparator includes N interfaces; The rectangular pulse signal generating circuit is connected to the first input terminal of the i-th XOR circuit through the i-th first metal line, the rectangular pulse signal generating circuit is connected to the second input terminal of the i-th XOR circuit through the i-th second metal line, and the output terminal of the i-th XOR circuit is connected to the i-th interface of the first input terminal of the second comparator, where i is less than or equal to N.
8. The chip protection circuit according to claim 1, characterized in that: The signal comparison circuit includes an XOR circuit and a third comparator; The XOR circuit includes a first input terminal, a second input terminal and an output terminal. The rectangular pulse signal generating circuit is connected to the first input terminal of the XOR circuit through the first metal line, and the rectangular pulse signal generating circuit is connected to the second input terminal of the XOR circuit through the second metal line. The output terminal of the XOR circuit is connected to the first input terminal of the third comparator, the second input terminal of the third comparator is used to input a fifth preset value, and the output terminal of the third comparator is used to output the alarm signal.
9. The chip protection circuit according to claim 8, characterized in that: In the case where both the first metal line and the second metal line include N lines, the XNOR circuit includes N lines; the first input end of the third comparator includes N interfaces; The rectangular pulse signal generating circuit is connected to the first input terminal of the jth X-OR circuit through the jth first metal line, the rectangular pulse signal generating circuit is connected to the second input terminal of the jth X-OR circuit through the jth second metal line, and the output terminal of the jth X-OR circuit is connected to the jth interface of the first input terminal of the third comparator, wherein j is less than or equal to N.
10. A chip, characterized in that: include: The chip protection circuit according to any one of claims 1 to 9.
