Reset control circuit and method and computer storage medium
By designing a reset control circuit in the on-chip system, using the coordinated work of the reset generation sub-circuit, the reset register configuration sub-circuit and the reset interval counting sub-circuit, the problem of low accuracy and slow efficiency of the execution interval of software configuration reset registers and setting instructions is solved. Achieve more efficient reset operations, improving system stability and response speed.
Patent Information
- Application Number
- CN202411116628.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-14
- Publication Date
- 2024-11-26
AI Technical Summary
In the prior art, reset assert or de-assert is implemented through software configuration of reset registers and setting instruction execution intervals, which have problems of low accuracy and slow efficiency.
A reset control circuit is designed, including a reset generation sub-circuit, a reset register configuration sub-circuit and a reset interval counting sub-circuit. Through hardware collaboration, the reset and release operation sequence and time of the intellectual property core are accurately controlled to reduce system power consumption.
Improves the accuracy and stability of reset operations, reduces power consumption, ensures that the system performs reset and release operations at the correct time, and improves the system's response speed and processing capabilities.
Smart Images

Figure CN119024941A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a reset control circuit, method and computer storage medium. Background Art
[0002] With the development of technology, the integration of digital circuits is getting higher and higher, and the design is becoming more and more complex. In particular, the system on chip (SoC) is generally composed of multiple subsystems, each of which is composed of several or even dozens of IPs, and is interconnected through the network on chip (NoC).
[0003] In order to ensure the normal operation of each sub-circuit, a software reset function is provided for each sub-circuit when designing the SoC to ensure that when one of the sub-circuits is abnormal, it can be reset independently.
[0004] In specific applications, each subcircuit is in a reset state before the SoC chip is started. During the startup process, each subcircuit needs to be reset and released in sequence (called reset de-assert) so that it can enter the working state normally. At the same time, in response to design requirements such as low power consumption of the chip, certain IPs / subsystems will also be reset one by one in sequence when the chip is working normally (called reset assert).
[0005] In the related art, it is necessary to configure a reset register and set an instruction execution interval through software to implement a reset assert or de-assert. The above method has the problems of low configuration accuracy and low efficiency. Summary of the invention
[0006] In view of this, the present invention provides a reset control circuit, method and computer storage medium to solve the problems of low precision and low efficiency of reset assert or de-assert in the related art by configuring a reset register and setting an instruction execution interval through software.
[0007] In a first aspect, the present invention provides a reset control circuit, which is applied to a system on chip, wherein the system on chip includes a plurality of subsystems, each of which is composed of at least one intellectual property core, and the reset control circuit includes: a reset generation subcircuit, a reset register configuration subcircuit, and a reset interval counting subcircuit;
[0008] The reset generation subcircuit is used to adjust the states of all intellectual property cores to the reset operation state in sequence according to the indication information of the reset register configuration subcircuit when the system on chip is not in the working state;
[0009] A reset register configuration subcircuit, used to determine a configuration mode of a reset release operation sequence and a reset release operation sequence of an intellectual property core;
[0010] A reset interval counting subcircuit determines the execution time of the reset release operation of each intellectual property core according to the configuration mode of the reset release operation sequence;
[0011] The reset register configuration subcircuit is also used to control the reset generation subcircuit to complete the reset release operation of one or more intellectual property cores according to the reset release operation sequence and execution time when detecting that the on-chip system is in the working state.
[0012] A reset control circuit provided by the present invention has the following advantages:
[0013] When the system is not in working state, in order to reduce the system power consumption of the system on chip, when the system on chip is not in working state, the working state of the system on chip is first set to the reset operation state through the reset generation subcircuit, and the reset configuration register configuration subcircuit is used to determine the configuration mode of the reset release operation sequence and the reset release operation sequence of each intellectual property core. The reset interval counting subcircuit determines the execution time of each intellectual property core to perform the reset release operation according to the configuration mode of the reset release operation sequence; then, when the reset register configuration subcircuit detects that the system on chip is in working state, according to the reset release operation sequence and the execution time, the reset generation subcircuit is controlled to complete the reset release operation of one or more intellectual property cores. In this way, the reset configuration register configuration subcircuit and the reset interval counting subcircuit work together to ensure that the reset release operation is performed only when the system needs it, further reducing power consumption. Compared with the related art of realizing reset assert or de-assert operations by configuring the reset register and setting the instruction execution interval through software, the hardware execution of related operations is usually faster than software execution. Moreover, the hardware can accurately perform the reset release operation at the specified time under the control of the system clock to ensure the accuracy and stability of the system. Furthermore, hardware-executed reset release operations usually consume less power than software-executed ones. Hardware can directly control the on / off of the circuit, avoiding the calculation and data transmission during software execution, thereby reducing power consumption. Once the registers are defined, there is no need to adjust the instruction execution interval for the problem of inaccurate reset intervals, which has good versatility.
[0014] In an optional implementation, the reset register configuration subcircuit includes: a reset sequence configuration register, at least one reset interval configuration register, and a reset release operation register, the number of the reset interval configuration registers is the same as the number of the intellectual property cores, and each reset interval configuration register is used to control an intellectual property core to be adjusted to a reset operation state after a release time interval corresponding to itself;
[0015] A reset sequence configuration register, used for indicating the reset release operation sequence of the reset interval configuration register to configure the intellectual property core when the first preset byte bit of the reset sequence configuration register is invalid;
[0016] A first reset interval configuration register is used to determine the reset release operation sequence of the intellectual property core corresponding to itself according to its own identification information; monitor the clock cycle in the reset interval counting subcircuit; when it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the first intellectual property core corresponding to itself has been reached, control the second preset byte of the reset release operation register to be valid, wherein the first reset interval configuration register is any one of the at least one reset interval configuration register;
[0017] The reset generation subcircuit is used to configure the state of the first intellectual property core to a reset release operation state when recognizing that the second preset byte is valid;
[0018] or,
[0019] When the first preset byte of the reset sequence configuration register is valid, the reset sequence configuration register is used to configure the reset release operation sequence of the intellectual property core, wherein, when the reset sequence configuration register configures the reset release operation sequence of the intellectual property core, the placeholder position of the bytes other than the first preset byte and the third preset byte in the reset sequence configuration register determines the reset release operation sequence of the intellectual property core, wherein the first preset byte and the third preset byte are bytes at fixed positions in the reset sequence configuration register;
[0020] A second reset interval configuration register is used to monitor the clock cycle in the reset interval counting subcircuit; when it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the second intellectual property core corresponding to itself has been reached, the second preset byte of the reset release operation register is controlled to be valid, wherein the second reset interval configuration register is any one of the at least one reset interval configuration register;
[0021] The reset generation sub-circuit is used to configure the state of the second intellectual property core to a reset release operation state when recognizing that the second preset byte is valid.
[0022] Specifically, by setting the reset sequence configuration register and the reset interval configuration register, the reset release operation sequence and time interval of the intellectual property core can be flexibly configured. This enables the system to adapt to different application requirements and working modes. Moreover, by accurately controlling the reset release operation sequence and time interval of the intellectual property core, unnecessary power consumption can be avoided. By operating in a specific reset release operation sequence, instability of the system during startup can be avoided. This helps to improve the reliability and stability of the system. A reasonable reset release operation sequence can ensure that each intellectual property core is activated at the right time, thereby optimizing the performance of the system and improving the response speed and processing capability of the system. Furthermore, this reset control mechanism makes system management and maintenance more convenient.
[0023] In an optional implementation, the resetting register configuration subcircuit further includes: resetting a mask register;
[0024] The reset mask register is used to mask the target intellectual property core. The state of the masked target intellectual property core is not controlled by the reset generation subcircuit and maintains the original state, wherein the target intellectual property core is any intellectual property core to be masked.
[0025] Specifically, by resetting the mask register, the target IP core can be flexibly shielded so that its state is not controlled by the reset generation subcircuit and remains in its original state. This can increase the flexibility of the system and allow special processing of certain IP cores according to specific needs. Moreover, by shielding unnecessary IP cores, system resources can be saved and resource utilization can be improved.
[0026] In an optional implementation, the reset register configuration subcircuit further includes: a reset operation register;
[0027] A reset operation register, used to receive a start execution instruction sent by a reset sequence configuration register or a reset interval configuration register; according to the start execution instruction, the fourth preset byte of the reset operation register is set to be valid;
[0028] The reset generation sub-circuit is further used to configure the state of the third intellectual property core to a reset operation state when the fourth preset byte is confirmed to be valid, wherein the third intellectual property core is any intellectual property core.
[0029] Specifically, the reset operation register receives the start execution instruction and sets a specific byte to be valid. This allows the reset generation subcircuit to accurately identify when the reset operation is performed, thereby accurately controlling the reset state of the intellectual property core. By setting the bytes of the reset operation register, the triggering conditions of the reset operation can be flexibly configured according to specific needs. This increases the programmability of the system so that it can adapt to different application scenarios and requirements. Accurate reset operation control helps ensure that the system is correctly reset under specific conditions, thereby improving the reliability and stability of the system.
[0030] In an optional embodiment, the reset interval counting subcircuit includes a single counter, a multi-counter, a selector, and a processor;
[0031] A selector, used for receiving a selection signal generated by a reset register configuration subcircuit;
[0032] The processor is used to control the single counter to perform work when the selection signal is valid, so as to determine the execution time corresponding to the reset release operation of each intellectual property core;
[0033] or,
[0034] When the selection signal is invalid, the multi-counter is controlled to work to determine the execution time corresponding to the reset release operation of each intellectual property core.
[0035] Specifically, through the control of the selector and the processor, a single counter or multiple counters can be flexibly selected to determine the execution time corresponding to the reset release operation of the intellectual property core according to the selection signal generated by the reset register configuration subcircuit. This flexibility enables the circuit to adapt to different application requirements and working modes. Selecting to use a single counter or multiple counters according to actual conditions can effectively utilize system resources. In some cases, using a single counter is more resource-saving, while in other cases, using multiple counters is more suitable for processing complex reset release operation sequences. Selecting a suitable counter can improve the efficiency of determining the execution time. A single counter is suitable for a simple reset release operation sequence, while multiple counters can simultaneously process the reset release operations of multiple intellectual property cores, improving parallel processing capabilities. Moreover, selecting a suitable counter according to actual needs can reduce system power consumption. In the case where multiple reset release operations do not need to be processed simultaneously, using a single counter can reduce unnecessary power consumption.
[0036] In an optional implementation manner, the processor is specifically configured to:
[0037] Based on the execution time corresponding to the reset release operation of the third intellectual property core, control the single counter to count the clock cycle;
[0038] When the preset number of clock cycles is reached, determining the execution time corresponding to the reset release operation of the second intellectual property core, wherein the number of preset clock cycles is determined according to the release time interval corresponding to the reset release operation of the preconfigured intellectual property core;
[0039] Clear the statistical count value in the single counter.
[0040] Specifically, the processor can achieve precise control of the reset release of the intellectual property core by controlling a single counter to count clock cycles and determining the execution time of the reset release operation according to the preset number of clock cycles. The number of preset clock cycles is determined according to the release time interval corresponding to the reset release operation of the preconfigured intellectual property core, thereby ensuring that the time interval between the reset release operations of each intellectual property core meets the requirements. Accurate reset release operation control helps to ensure that the system performs reset release at the correct time, avoiding system failure or instability caused by inaccurate reset release time. By reasonably controlling the execution time of the reset release operation, unnecessary waiting time can be avoided and the performance and efficiency of the system can be improved. After determining the execution time of the reset release operation, the statistical count value in the single counter is cleared to prepare for the next reset release operation, thereby ensuring the accuracy and continuity of the count. Therefore, this design can be applied to the reset release operations of multiple intellectual property cores, and has good versatility and scalability.
[0041] In an optional implementation manner, the processor is specifically configured to:
[0042] Extracting the release time interval configured in each reset interval configuration register respectively;
[0043] determining a number of clock cycles based on the release time interval;
[0044] Taking the preset time as the starting time, counting is performed in parallel on multiple counters to count the number of clock cycles respectively;
[0045] Determine the time when the number of clock cycles counted by the counter corresponding to the second intellectual property core reaches the same number of clock cycles as the release time interval configured in the reset interval configuration register corresponding to itself, as the execution time corresponding to the reset release operation of the second intellectual property core.
[0046] Specifically, by extracting the configuration information in the reset interval configuration register, the processor can flexibly determine the release time interval of each intellectual property core to meet different application requirements. Taking the effective time of the second preset byte of the reset release operation register as the starting time, parallel counting on multiple counters can accurately count the number of clock cycles, thereby accurately determining the execution time corresponding to the reset release operation of each intellectual property core. Accurate reset execution time control helps to ensure that the system performs reset release at the correct time, avoiding system failure or instability caused by inaccurate reset release time. Moreover, by reasonably configuring the release time interval and accurately controlling the reset execution time, unnecessary waiting time can be avoided, and the performance and efficiency of the system can be improved. Since the parallel counting method of multiple counters can process the reset release operations of multiple intellectual property cores at the same time, the parallel processing capability of the system will also be improved. Flexible configuration and precise control make the circuit suitable for various application scenarios and intellectual property core types, and it has high versatility.
[0047] In an optional implementation, the reset control circuit further includes: a reset synchronization subcircuit;
[0048] The reset synchronization subcircuit is used to instruct the reset generation subcircuit to output the signals sequentially synchronously or asynchronously, wherein the output signal is used to control the state of the intellectual property core to be adjusted to a preset state, which is a reset operation state or a reset release operation state.
[0049] Specifically, the reset synchronization subcircuit can instruct the reset generation subcircuit to output the signals output in sequence synchronously, thereby ensuring the synchronization of the signals that control the state adjustment of the intellectual property core. This helps to avoid system errors or instability caused by asynchronous signals. In addition to synchronous output, the reset synchronization subcircuit can also instruct the signal to be output asynchronously. This enables the reset control circuit to adapt to different system requirements and operating modes, providing more flexibility. By outputting signals synchronously or asynchronously, the reset synchronization subcircuit can accurately control the state adjustment of the intellectual property core to a preset state, that is, a reset operation state or a reset release operation state. This helps to ensure that the system switches states at the right time, improving the reliability and stability of the system. The presence of the reset synchronization subcircuit makes the reset control circuit easier to integrate into the entire system and facilitates debugging and maintenance.
[0050] In a second aspect, the present invention provides a reset control method, which is applied to a system on chip, wherein the system on chip includes multiple subsystems, each subsystem is composed of at least one intellectual property core, and the reset control circuit includes: a reset generation subcircuit, a reset register configuration subcircuit, and a reset interval counting subcircuit; the method includes:
[0051] When the system on chip is not in the working state, the reset generation subcircuit sequentially adjusts the states of all the intellectual property cores to the reset operation state according to the first indication information of the reset register configuration subcircuit;
[0052] The reset register configuration subcircuit determines the configuration mode of the reset release operation sequence and the reset release operation sequence of the intellectual property core;
[0053] The reset interval counting subcircuit determines the execution time of the reset release operation of each intellectual property core according to the configuration mode of the reset release operation sequence;
[0054] When the reset register configuration subcircuit detects that the system on chip is in working state, the reset register configuration subcircuit controls the reset generation subcircuit to complete the reset release operation of one or more intellectual property cores according to the reset release operation sequence and execution time. A reset control method provided by the present invention has the following advantages:
[0055] When the system is not in working state, in order to reduce the system power consumption of the system on chip, when the system on chip is not in working state, the working state of the system on chip is first set to the reset operation state through the reset generation subcircuit, and the reset configuration register configuration subcircuit is used to determine the configuration mode of the reset release operation sequence and the reset release operation sequence of each intellectual property core. The reset interval counting subcircuit determines the execution time of each intellectual property core to perform the reset release operation according to the configuration mode of the reset release operation sequence; then, when the reset register configuration subcircuit detects that the system on chip is in working state, according to the reset release operation sequence and the execution time, the reset generation subcircuit is controlled to complete the reset release operation of one or more intellectual property cores. In this way, the reset configuration register configuration subcircuit and the reset interval counting subcircuit work together to ensure that the reset release operation is performed only when the system needs it, further reducing power consumption. Compared with the related art of realizing reset assert or de-assert operations by configuring the reset register and setting the instruction execution interval through software, the hardware execution of related operations is usually faster than software execution. Moreover, the hardware can accurately perform the reset release operation at the specified time under the control of the system clock to ensure the accuracy and stability of the system. Furthermore, hardware-executed reset release operations usually consume less power than software-executed ones. Hardware can directly control the on / off of the circuit, avoiding the calculation and data transmission during software execution, thereby reducing power consumption. Once the registers are defined, there is no need to adjust the instruction execution interval for the problem of inaccurate reset intervals, which has good versatility.
[0056] In a third aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the reset control method of the first aspect or any corresponding embodiment thereof.
[0057] In a fourth aspect, the present invention provides a computer program product, comprising computer instructions for causing a computer to execute the reset control method of the first aspect or any corresponding embodiment thereof. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0059] Figure 1 It is a structural diagram of the CPU provided in the related art controlling each IPR through the RCU to realize independent reset operation;
[0060] Figure 2 is a schematic diagram of a reset control circuit structure provided by an embodiment of the present invention;
[0061] Figure 3 is a schematic diagram of another reset control circuit structure provided by an embodiment of the present invention;
[0062] Figure 4 It is a schematic diagram of the principle of implementing a reset release operation using the reset control circuit of the present application provided by an embodiment of the present invention;
[0063] Figure 5 It is another principle schematic diagram of implementing a reset release operation using the reset control circuit of the present application provided by an embodiment of the present invention;
[0064] Figure 6 is a schematic diagram of the overall structure of a reset control circuit provided by an embodiment of the present invention;
[0065] Figure 7 It is a schematic diagram of a reset control method provided by an embodiment of the present invention;
[0066] Figure 8 It is a schematic diagram of a simple overall flow chart of a reset control method provided by an embodiment of the present invention;
[0067] Fig. 9 A comparative diagram of implementing the reset sequence control register configuration using the method of the embodiment of the present application and the method in the related art;
[0068] Fig.10 is a schematic diagram of an application example in a specific application scenario provided by an embodiment of the present invention;
[0069] Fig.11 It is a schematic diagram of an application example in another specific application scenario provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0070] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0071] With the development of technology, the integration of digital circuits is getting higher and higher, and the design is becoming more and more complex. Especially SoC, which is generally composed of multiple subsystems, each of which is composed of several or even dozens of IPs and interconnected by NoC.
[0072] In order to ensure the normal operation of each sub-circuit, a software reset function is provided for each sub-circuit when designing the SoC, so that when one of the sub-circuits is abnormal, it can be reset independently. Figure 1 As shown, Figure 1 The diagram shows that the central processing unit (CPU) is connected to the reset control unit (RCU), and each IPR in multiple IPs is controlled by the RCU to realize independent reset operation.
[0073] Before the SoC chip is started, each subcircuit is in a reset state. During the startup process, each subcircuit needs to be reset and released in sequence (called reset de-assert) so that it can enter the working state normally. At the same time, in response to design requirements such as low power consumption of the chip, certain IP / subsystems will be reset one by one in sequence when the chip is working normally (called reset assert). Reset assert and reset de-assert are generally implemented through software, that is, according to the reset release sequence requirements, each reset register or different bits of the same reset register are configured one by one at a certain interval, and an asynchronous reset signal is generated for each register or 1 bit configured.
[0074] In the related art, it is necessary to configure the reset register and set the instruction execution interval through software to realize the reset and sequentially assert or de-assert. The above method has the problems of low configuration accuracy and low efficiency.
[0075] To solve the above problems, an embodiment of the present invention provides a reset control circuit, such as Figure 2As shown, the reset control circuit is applied to a system on chip, the system on chip includes multiple subsystems, each subsystem is composed of at least one intellectual property core, and the reset control circuit includes: a reset generation subcircuit 201, a reset register configuration subcircuit 202, and a reset interval counter subcircuit 203;
[0076] The reset generation subcircuit 201 is used to adjust the states of all intellectual property cores to the reset operation state in sequence according to the indication information of the reset register configuration subcircuit 202 when the system on chip is not in the working state;
[0077] The reset register configuration subcircuit 202 is used to determine the configuration mode of the reset release operation sequence and the reset release operation sequence of the intellectual property core;
[0078] The reset interval counter subcircuit 203 determines the execution time of the reset release operation of each intellectual property core according to the configuration mode of the reset release operation sequence;
[0079] The reset register configuration subcircuit 202 is also used to control the reset generation subcircuit 201 to complete the reset release operation of one or more intellectual property cores according to the reset release operation sequence and execution time when detecting that the system on chip is in the working state.
[0080] Specifically, in order to reduce the system power consumption of the system on chip, when the system on chip is not in the working state, the working state of the system on chip is first set to the reset operation state through the reset generation sub-circuit 201.
[0081] The reset configuration register configuration subcircuit is used to determine the configuration mode of the reset release operation sequence and the reset release operation sequence of each intellectual property core. The reset register configuration subcircuit 202 includes: a reset sequence configuration register, at least one reset interval configuration register, and a reset release operation register.
[0082] In an optional example, the reset register configuration subcircuit 202 can determine the reset release operation sequence based on whether the first preset byte in the reset sequence configuration register is valid in the configuration mode of determining the reset release operation sequence. When the first preset byte is valid, the reset release operation sequence is determined by the reset sequence configuration register. Alternatively, when the first preset byte is invalid, the reset release operation sequence is determined by each reset interval configuration register.
[0083] Of course, in another optional example, a flag bit may be directly configured in the reset register configuration circuit to indicate the reset release operation sequence, for example, the reset release operation sequence is determined by a reset sequence configuration register, or the reset release operation sequence is determined by each reset interval configuration register.
[0084] In another optional example, a separate sequence configuration subcircuit is directly set in the reset register configuration circuit to carry the reset release operation sequence of each intellectual property core.
[0085] Specifically, any of the above optional implementations may be used, and no specific limitation is made here.
[0086] In a specific application example of the present application, the configuration method of the reset release operation sequence and the reset release operation sequence of the intellectual property core are determined based on whether the first preset byte in the reset sequence configuration register is valid.
[0087] The reset interval counter sub-circuit 203 is used to determine the execution time of the reset release operation of each intellectual property core according to the configuration mode of the reset release operation sequence.
[0088] Specifically, the system can adapt to different application requirements and working modes. In order to reduce the system on chip, when the chip is working normally, some intellectual property cores will be reset and released one by one or reset in sequence.
[0089] Therefore, the execution time of each intellectual property core performing the reset release operation needs to be determined according to the configuration mode of the reset release operation sequence. That is, there needs to be a certain release time interval between two adjacent intellectual property cores when they are released.
[0090] In a specific example, the release time interval can be measured by a clock cycle as a unit time. For example, the release time interval is one or more clock cycles.
[0091] The reset and restart configuration subcircuit, when detecting that the system on chip is in working state, controls the reset generation subcircuit 201 to complete the reset release operation of one or more intellectual property cores according to the reset release operation sequence and the determined execution time.
[0092] A reset control circuit provided by an embodiment of the present invention, when the system is not in working state, in order to reduce the system power consumption of the system on chip, when the system on chip is not in working state, the working state of the system on chip is first set to the reset operation state through the reset generation subcircuit 201, and the reset configuration register configuration subcircuit is used to determine the configuration mode of the reset release operation sequence and the reset release operation sequence of each intellectual property core. The reset interval counter subcircuit 203 determines the execution time of each intellectual property core to perform the reset release operation according to the configuration mode of the reset release operation sequence; then, when the reset register configuration subcircuit 202 detects that the system on chip is in working state, according to the reset release operation sequence and the execution time, controls the reset generation subcircuit 201 to complete the reset release operation of one or more intellectual property cores. In this way, the reset configuration register configuration subcircuit and the reset interval counter subcircuit 203 work together to ensure that the reset release operation is performed only when the system needs it, further reducing power consumption. Compared with the related art of realizing reset assert or de-assert operations by configuring the reset register and setting the instruction execution interval through software, hardware execution of related operations is usually faster than software execution. Moreover, the hardware can accurately perform the reset release operation at the specified time under the control of the system clock to ensure the accuracy and stability of the system. Furthermore, the reset release operation executed by hardware usually consumes less power than the software. The hardware can directly control the switch of the circuit, avoiding the calculation and data transmission during the software execution process, thereby reducing power consumption. And once the register is defined, there is no need to adjust the instruction execution interval for the problem of inaccurate reset interval, which has good versatility.
[0093] Based on the above embodiments, the present invention also provides another reset control circuit. Figure 3 As shown, the reset register configuration subcircuit 202 includes: a reset sequence configuration register, at least one reset interval configuration register, and a reset release operation register.
[0094] The number of reset interval configuration registers is the same as the number of intellectual property cores, and each reset interval configuration register is used to control an intellectual property core to be adjusted to a reset operation state after a release time interval corresponding to itself.
[0095] A reset sequence configuration register, used for indicating the reset release operation sequence of the reset interval configuration register to configure the intellectual property core when the first preset byte bit of the reset sequence configuration register is invalid;
[0096] A first reset interval configuration register is used to determine the reset release operation sequence of the intellectual property core corresponding to itself according to its own identification information; monitor the clock cycle in the reset interval counter subcircuit 203; when it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the first intellectual property core corresponding to itself has been reached, control the second preset byte of the reset release operation register to be valid, wherein the first reset interval configuration register is any one of the at least one reset interval configuration register;
[0097] The reset generating sub-circuit 201 is used to configure the state of the first intellectual property core to a reset release operation state when recognizing that the second preset byte is valid;
[0098] or,
[0099] When the first preset byte of the reset sequence configuration register is valid, the reset sequence configuration register is used to configure the reset release operation sequence of the intellectual property core, wherein, when the reset sequence configuration register configures the reset release operation sequence of the intellectual property core, the placeholder position of the bytes other than the first preset byte and the third preset byte in the reset sequence configuration register determines the reset release operation sequence of the intellectual property core, wherein the first preset byte and the third preset byte are bytes at fixed positions in the reset sequence configuration register;
[0100] A second reset interval configuration register is used to monitor the clock cycle in the reset interval counter subcircuit 203; when it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the second intellectual property core corresponding to itself has been reached, the second preset byte of the reset release operation register is controlled to be valid, wherein the second reset interval configuration register is any one of the at least one reset interval configuration register;
[0101] The reset generation sub-circuit 201 is used to configure the state of the second intellectual property core to a reset release operation state when it is recognized that the second preset byte is valid.
[0102] Specifically, in a specific example, assuming that the number of intellectual property cores is 30, a reset sequence configuration register may be configured, the reset sequence configuration register may be 32 bits wide, and the highest bit is the first preset byte, that is, the reset sequence valid bit.
[0103] Specifically, the highest bit is also used to indicate whether the reset interval counter subcircuit 203 is valid. In a specific example, if the highest bit is invalid, it means that the reset interval counter subcircuit 203 is valid. On the contrary, if the highest bit is valid, it means that the reset interval counter subcircuit 203 is invalid.
[0104] When the reset interval counter subcircuit 203 is valid, the reset release operation sequence is configured by the reset interval configuration register. The reset release operation sequence of the intellectual property core is determined based on the identification information of the reset interval configuration register. For example, the identification information of the reset interval configuration register is 0. The reset release operation sequence of the corresponding intellectual property core is ranked as 0, and so on, the reset release operation sequence of other intellectual property cores is determined.
[0105] The following description is made by taking the first reset interval configuration register as an example, wherein the first reset interval configuration register is any one of the at least one reset interval configuration register. The first reset interval configuration register needs to monitor the clock cycle in the reset interval counter subcircuit 203. When it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the first intellectual property core corresponding to itself has been reached, the second preset byte of the reset release operation register is controlled to be valid.
[0106] Then, when the reset generating sub-circuit 201 recognizes that the second preset byte is valid, it configures the state of the first intellectual property core to be a reset release operation state.
[0107] Specifically, the second preset byte is, for example, the lowest bit of the reset release operation register, and the second preset byte is valid, for example, the lowest bit of the reset release operation register is set to 1. Then, at this time, when the reset generation circuit recognizes that the lowest bit of the reset release operation register is 1, the state of the first intellectual property core is configured to the reset release operation state.
[0108] On the contrary, if the highest bit is valid, it means that the reset release operation sequence is configured by the reset sequence configuration register. The reset release operation sequence of the specific intellectual property core is determined based on the position of the bytes other than the first preset byte and the third preset byte in the reset sequence configuration register, where the first preset byte and the third preset byte are bytes at fixed positions in the reset sequence configuration register.
[0109] For example, the third preset byte is the position of the lower 31 bits in the reset interval configuration register, and the lower 30 bits of the reset sequence configuration register are used to set the reset release operation sequence.
[0110] Specifically, when the highest bit is valid, it indicates whether the lower 30 bits are valid. The lowest bit of the lower 30 bits indicates the reset released first, the second lowest bit indicates the reset released second, and so on. The highest bit of the 30 bits indicates the reset released last.
[0111] Of course, if the number of intellectual property cores increases, the number of reset sequence configuration registers may also be expanded according to the number of reset release operations to be performed.
[0112] Thereafter, the second reset interval configuration register is used to monitor the clock cycle in the reset interval counter subcircuit 203; when it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the second intellectual property core corresponding to itself has been reached, the second preset byte of the reset release operation register is controlled to be valid. The second reset interval configuration register is any one of the at least one reset interval configuration registers.
[0113] Then, when the reset generation sub-circuit 201 recognizes that the second preset byte is valid, it configures the state of the second intellectual property core to the reset release operation state.
[0114] Specifically, as described above, the second preset byte is, for example, the lowest bit of the reset release operation register, and the second preset byte is valid, for example, the lowest bit of the reset release operation register is set to 1. Then, at this time, when the reset generation circuit recognizes that the lowest bit of the reset release operation register is 1, the state of the second intellectual property core is configured to the reset release operation state.
[0115] In an optional example, the reset interval counter subcircuit 203 includes a single counter, a plurality of counters, a selector, and a processor.
[0116] A selector, used to receive a selection signal generated by the reset register configuration subcircuit 202;
[0117] The processor is used to control the single counter to perform work when the selection signal is valid, so as to determine the execution time corresponding to the reset release operation of each intellectual property core;
[0118] or,
[0119] When the selection signal is invalid, the multi-counter is controlled to work to determine the execution time corresponding to the reset release operation of each intellectual property core.
[0120] Specifically, there are two ways to configure the reset interval configuration register:
[0121] One is to configure the interval between two reset assert / de-asserts, that is, the reset / release interval of two adjacent reset signals. The characteristic of this method is that the counting starts from the reset / release of the previous reset signal.
[0122] See Figure 4 As shown, Figure 4The reset sequence configuration register includes 32 bits from 0 to 31. The highest bit is the valid bit, the second highest bit is the reserved bit, and the lower 30 bits are used to set the reset release operation sequence of different intellectual property cores. For example, the order of reset release operations is rst0, rst1, rst2, ..., rst31, etc.
[0123] exist Figure 4 A reset interval register corresponding to each intellectual property core is also set in , for example Figure 4 On the left side, the same identification information rst0-rst31 as that of the intellectual property core is set to distinguish different reset interval registers. Figure 4 The left side of the figure also illustrates the reset release operation register and the reset operation register to be introduced below. The reset release operation register includes 31 bits, of which the lower 30 bits are used to indicate whether the release of different intellectual property cores is successful. The lower 31 bits are the release status bits, which are used to indicate whether the reset release register is valid. When the reset release register is valid, this byte is also the second preset byte mentioned in the previous text, that is, when the second preset byte is valid, the reset generation subcircuit 201 will perform the reset release operation on the intellectual property core.
[0124] Similarly, the reset operation register includes 31 bits, wherein the lower 30 bits are used to indicate whether the reset of different intellectual property cores is successful. The lower 31 bits are the start status bits, which are used to indicate whether the reset operation register is valid. When the reset operation register is valid, the byte is also the fourth preset byte to be mentioned below, that is, when the fourth preset byte is valid, the reset generation subcircuit 201 will perform the reset operation on the intellectual property core.
[0125] Figure 4 The right side of the middle diagram illustrates the clock signal and different reset interval configuration registers, which are based on different clock cycles and control the highest bit in the reset release operation register to be valid.
[0126] For example, the reset release operation register Rst0 (illustrated as Reset0 in the figure) is valid at time t0, while the reset release operation register Rst1 (illustrated as Reset1 in the figure) is valid at time t1, and so on. Figure 4 In the above, the execution time of the reset release operation of the previous intellectual property core is taken as the start point, and the execution time of the reset release operation of the next instruction property core is calculated according to the release time interval.
[0127] The other is the interval between configuration and reset start / release flag, all configuration values are calculated starting from the start / release flag. The characteristic of this method is that it does not need to configure the reset sequence register, and the value in the reset interval configuration register can be directly taken out as the comparison value of the reset interval counter.
[0128] See Figure 5 shown. Figure 5 The reset sequence configuration register includes 32 bits from 0 to 31. The highest bit is the valid bit, the second highest bit is the reserved bit, and the lower 30 bits are used to set the reset release operation sequence of different intellectual property cores. For example, the order of reset release operations is rst0, rst1, rst2, ..., rst31, etc.
[0129] exist Figure 5 A reset interval register corresponding to each intellectual property core is also set in , for example Figure 5 On the left side, the same identification information rst0-rst31 as that of the intellectual property core is set to distinguish different reset interval registers. Figure 5 The left side of the figure also illustrates the reset release operation register and the reset operation register to be introduced below. The reset release operation register includes 31 bits, of which the lower 30 bits are used to indicate whether the release of different intellectual property cores is successful. The lower 31 bits are the release status bits, which are used to indicate whether the reset release register is valid. When the reset release register is valid, this byte is also the second preset byte mentioned in the previous text, that is, when the second preset byte is valid, the reset generation subcircuit 201 will perform the reset release operation on the intellectual property core.
[0130] Similarly, the reset operation register includes 31 bits, wherein the lower 30 bits are used to indicate whether the reset of different intellectual property cores is successful. The lower 31 bits are the start status bits, which are used to indicate whether the reset operation register is valid. When the reset operation register is valid, the byte is also the fourth preset byte to be mentioned below, that is, when the fourth preset byte is valid, the reset generation subcircuit 201 will perform the reset operation on the intellectual property core.
[0131] Figure 5 The right side of the middle diagram illustrates the clock signal and different reset interval configuration registers, which are based on different clock cycles and control the highest bit in the reset release operation register to be valid.
[0132] For example, the reset release operation register Rst0 (shown as Reset0 in the figure) is valid at time t0. The reset release operation register Rst1 (shown as Reset1 in the figure) is valid at time t0+t1, and so on. All IP cores start at time t0 when executing the reset release operation, and after adding the preset time interval, they determine the time when they execute the reset release operation.
[0133] Since the two methods of calculating the timing of the reset release operation are different, the reset interval counter subcircuit 203 includes two counters, one of which is a single counter and the other is a multiple counter.
[0134] Among them, when the most significant bit of the reset sequence configuration register is configured to 1, it means that the reset sequence defined by the reset sequence configuration register is valid, and the counter only needs to count one by one according to the value in the reset interval configuration register, that is, one counter can complete the generation of multiple asynchronous resets, and the selector selects a single counter. The characteristic of this method is that it saves counter hardware resources, but the start of each reset interval count depends on the generation of the previous reset. When the corresponding bit of the reset mask register is "1", it means that the corresponding reset needs to be masked, that is, not all resets are asserted or de-assert. When the hardware judges that the mask is "1", it will take out the value of the next reset interval configuration register in sequence for counting.
[0135] When the most significant bit of the reset sequence configuration register is configured to 0, it means that the reset sequence defined by the reset sequence configuration register is invalid. The value in the corresponding reset interval configuration register is directly taken out, and the reset start / release signal is used as the starting point to perform parallel counting on multiple counters. The resulting reset sequence is only determined by the value of each reset interval configuration register. The characteristic of this method is that software personnel do not need to configure the reset sequence. For the counting method of multiple counters, the configuration of the reset mask register directly affects whether the corresponding counter is started. Compared with a single counter, it will not interfere with the counting process.
[0136] Therefore, the processor is specifically used to:
[0137] Based on the execution time corresponding to the reset release operation of the third intellectual property core, control the single counter to count the clock cycle;
[0138] When the preset number of clock cycles is reached, determining the execution time corresponding to the reset release operation of the second intellectual property core, wherein the number of preset clock cycles is determined according to the release time interval corresponding to the reset release operation of the preconfigured intellectual property core;
[0139] Clear the statistical count value in the single counter.
[0140] The above functional principle of the processor is Figure 5 The corresponding example matches. That is, after the current reset release operation register performs the reset release operation at the current moment, the statistical count value of the single counter is cleared, and the number of clock cycles is counted based on the current moment. When the number of clock cycles corresponding to the preset time interval is reached, it is determined that the execution time corresponding to the reset release operation of the next intellectual property core has arrived. The second intellectual property core introduced in the previous article is the intellectual property core that needs to perform the reset release operation immediately after the third intellectual property core.
[0141] Alternatively, the processor is specifically configured to:
[0142] Extracting the release time interval configured in each reset interval configuration register respectively;
[0143] determining a number of clock cycles based on the release time interval;
[0144] Taking the preset time as the starting time, counting is performed in parallel on multiple counters to count the number of clock cycles respectively;
[0145] Determine the time when the number of clock cycles counted by the counter corresponding to the second intellectual property core reaches the same number of clock cycles as the release time interval configured in the reset interval configuration register corresponding to itself, as the execution time corresponding to the reset release operation of the second intellectual property core.
[0146] In this case, Figure 5 The corresponding examples match. That is, each time when the intellectual property core performs the reset release operation is based on a certain reference time to determine the release time interval. The release time interval is stored in the reset interval configuration register corresponding to the intellectual property core. Then the preset time is used as the starting time, for example Figure 5 Where t0 is the starting time, and multiple counters are counted in parallel to count the number of clock cycles. When it is determined that the number of cycles corresponding to the release time interval corresponding to a certain intellectual property core is reached, this moment is the execution time corresponding to the reset release operation of the intellectual property core.
[0147] In an optional example, when the first preset byte of the reset sequence configuration register is valid, the reset sequence configuration register is used to configure the reset release operation sequence of the intellectual property core, and the reset release operation sequence of the intellectual property core is determined according to the lower 30 bits of the reset sequence configuration register in the aforementioned method steps. In fact, in this specific application scenario, different intellectual property cores may have different requirements for reset release operations. For example, some may need to perform reset release operations when the upper system starts working, while others may perform reset release operations in a certain time period. Therefore, in addition to being executed in sequence according to the operation sequence configured in the lower 30 bits, the reset sequence configuration can also configure a priority for each intellectual property core, such as immediately starting one or more intellectual property cores corresponding to the priority after the upper system starts working. Then, other intellectual property cores are configured to perform reset release operations as needed. The principle of the clock cycle is also applicable, that is, different priority levels correspond to different execution times, and the execution time is also determined according to the number of clock cycles.
[0148] In an optional example, the reset register configuration subcircuit 202 further includes: a reset operation register;
[0149] A reset operation register, used to receive a start execution instruction sent by a reset sequence configuration register or a reset interval configuration register; according to the start execution instruction, the fourth preset byte of the reset operation register is set to be valid;
[0150] The reset generating sub-circuit 201 is further used to configure the state of the third intellectual property core to a reset operation state when the fourth preset byte is confirmed to be valid, wherein the third intellectual property core is any intellectual property core.
[0151] Specifically, the reset operation register is used to configure the start of the reset assert. When the reset sequence configuration register or the reset interval configuration register sends a start execution instruction, the reset operation register sets the fourth preset byte (eg, the lowest bit of the register) to "1" according to the start execution instruction, that is, the fourth preset byte is valid.
[0152] After the reset generation module recognizes the information, it starts to work and generates a reset assert signal. Then, according to the aforementioned operation principle of the configuration mode, configuration sequence, and execution time of the reset release operation sequence, the configuration mode, configuration sequence, and execution time of the reset operation sequence are determined to complete the reset operation of an intellectual property core.
[0153] The most specific application scenario of the reset operation is that when the system on chip is not in working state, the state of all intellectual property cores is adjusted to the reset operation state in sequence according to the indication information of the reset register configuration subcircuit 202. Of course, in the subsequent specific application process, there may be a need to perform a reset operation on a certain intellectual property core.
[0154] When all the intellectual property cores that need to perform reset operations have completed the reset assertion, the highest bit status position of the register is set to "1".
[0155] Alternatively, in some cases, when the reset assert fails, the highest status bit of the register maintains the reset value "0". At the same time, bits 30 to 1 of the register represent the assert status of 30 resets, and "1" indicates that the corresponding reset assert fails.
[0156] Among them, the number of reset assert registers can be expanded according to the number of resets.
[0157] In an optional example, the reset register configuration subcircuit 202 further includes: resetting a mask register;
[0158] The reset mask register is used to mask the target intellectual property core. The state of the masked target intellectual property core is not controlled by the reset generation subcircuit 201 and remains in the original state, wherein the target intellectual property core is any intellectual property core to be masked.
[0159] Specifically, this register is used to mask out unnecessary resets and implement flexible configuration of reset generation. When a bit in the reset mask register is "1", the corresponding reset is not controlled by the reset generation module and remains in its original state.
[0160] In an optional example, the reset control circuit further includes: a reset synchronization subcircuit 204;
[0161] The reset synchronization subcircuit 204 is used to instruct the reset generation subcircuit 201 to output the signals sequentially synchronously or asynchronously, wherein the output signal is used to control the state of the intellectual property core to be adjusted to a preset state, which is a reset operation state or a reset release operation state.
[0162] Specifically, the reset synchronization subcircuit 204 is composed of a selector and a synchronization unit, and supports the selection of the reset synchronization function. When the selection signal bypass signal is 0, the asynchronous reset output by the reset generation module is synchronized according to the corresponding clock domain and then output; when the bypass signal is 1, the asynchronous reset is directly output.
[0163] Figure 6The overall structure of the reset control circuit is shown in FIG. Figure 6 As shown, because Figure 6 The functions of each module in the above text have been described in detail, so no further elaboration is needed. It should be noted that the reset generation sub-circuit 201 is composed of a plurality of reset self-feedback circuits, see Figure 6 As shown, the reset self-feedback circuits 0 to n are included, and the reset synchronization sub-circuit 204 is composed of a plurality of reset synchronization counters and selectors. The selection is used to configure whether to execute the bypass function.
[0164] In this embodiment, an embodiment of a reset control method is also provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a reset control circuit including, for example, a set of executable instructions. Although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0165] Figure 7 FIG. 1 is a flow chart of a reset control method provided by an embodiment of the present invention. Figure 7 As shown, the method is applied to a system on chip, which includes multiple subsystems, each of which is composed of at least one intellectual property core, and the reset control circuit includes: a reset generation subcircuit, a reset register configuration subcircuit, and a reset interval counting subcircuit; the method flow includes the following steps:
[0166] Step S701, when the system on chip is not in the working state, the reset generation subcircuit sequentially adjusts the states of all intellectual property cores to the reset operation state according to the first indication information of the reset register configuration subcircuit.
[0167] Step S702: The reset register configuration subcircuit determines the configuration mode of the reset release operation sequence and the reset release operation sequence of the intellectual property core.
[0168] Step S703: the reset interval counting subcircuit determines the execution time of the reset release operation of each intellectual property core according to the configuration mode of the reset release operation sequence.
[0169] Step S704, when the reset register configuration subcircuit detects that the system on chip is in working state, the reset register configuration subcircuit controls the reset generation subcircuit to complete the reset release operation on one or more intellectual property cores according to the reset release operation sequence and execution time.
[0170] In an optional example, the reset register configuration subcircuit includes: a reset sequence configuration register, at least one reset interval configuration register, and a reset release operation register, the number of the reset interval configuration registers is the same as the number of the intellectual property cores, and each reset interval configuration register is used to control an intellectual property core to be adjusted to a reset operation state after a release time interval corresponding to itself;
[0171] The reset register configuration subcircuit determines the configuration mode of the reset release operation sequence and the reset release operation sequence of the intellectual property core, including:
[0172] When the first preset byte bit of the reset sequence configuration register is invalid, instructing the reset interval configuration register to configure the reset release operation sequence of the intellectual property core;
[0173] Determine the reset release operation sequence of the intellectual property core corresponding to itself according to the identification information of the first reset interval configuration register itself;
[0174] or,
[0175] When the first preset byte of the reset sequence configuration register is valid, the reset sequence configuration register is used to configure the reset release operation sequence of the intellectual property core, wherein, when the reset sequence configuration register configures the reset release operation sequence of the intellectual property core, the placeholder positions of the bytes other than the first preset byte and the third preset byte in the reset sequence configuration register determine the reset release operation sequence of the intellectual property core, wherein the first preset byte and the third preset byte are both bytes in fixed positions in the reset sequence configuration register.
[0176] In an optional example, the reset interval counting subcircuit includes a single counter, a multi-counter, a selector, and a processor; the reset interval counting subcircuit determines the execution time of each intellectual property core performing the reset release operation according to the configuration mode of the reset release operation sequence, specifically including:
[0177] receiving, via the selector, a selection signal generated by the reset register configuration subcircuit;
[0178] When the selection signal is valid, the processor controls the single counter to perform work to determine the execution time corresponding to the reset release operation of each intellectual property core;
[0179] or,
[0180] When the selection signal is invalid, the processor controls the operation of multiple counters to determine the execution time corresponding to the reset release operation of each intellectual property core.
[0181] Specifically, the processor controls the single counter to perform work to determine the execution time corresponding to the reset release operation of each intellectual property core, specifically including:
[0182] Based on the execution time corresponding to the reset release operation of the third intellectual property core, control the single counter to count the clock cycle;
[0183] When the preset number of clock cycles is reached, determining the execution time corresponding to the reset release operation of the second intellectual property core, wherein the number of preset clock cycles is determined according to the release time interval corresponding to the reset release operation of the preconfigured intellectual property core;
[0184] Clear the statistical count value in the single counter.
[0185] The processor controls the operation of multiple counters to determine the execution time corresponding to the reset release operation of each intellectual property core, specifically including:
[0186] Extracting the release time interval configured in each reset interval configuration register respectively;
[0187] determining a number of clock cycles based on the release time interval;
[0188] Taking the preset time as the starting time, counting is performed in parallel on multiple counters to count the number of clock cycles respectively;
[0189] Determine the time when the number of clock cycles counted by the counter corresponding to the second intellectual property core reaches the same number of clock cycles as the release time interval configured in the reset interval configuration register corresponding to itself, as the execution time corresponding to the reset release operation of the second intellectual property core.
[0190] In an optional example, the method further includes:
[0191] The reset synchronization subcircuit instructs the reset generation subcircuit to output signals sequentially synchronously or asynchronously, wherein the output signal is used to control the state of the intellectual property core to be adjusted to a preset state, which is a reset operation state or a reset release operation state.
[0192] In a specific example, an example of a method for implementing a general configurable reset control unit is shown below. The method flow includes:
[0193] 1) Software configuration reset sequence register;
[0194] If the reset sequence is configured, the highest bit is set to 1, and the lower 30 bits define the reset sequence;
[0195] If the reset sequence is not configured, the highest bit remains reset to 0;
[0196] 2) Software configuration reset interval register;
[0197] If the reset sequence is configured, the configuration values of each reset interval register are t0, t1, t2, ..., tn;
[0198] If the reset sequence is not configured, the configuration values of the registers in each reset interval are t0, t0+t1, t0+t2, ..., t0+tn respectively;
[0199] 3) Software configuration reset mask register;
[0200] 4) Software configuration resets the assert register / resets the de-assert register;
[0201] 5) Determine if the lowest bit of the reset assert register / reset de-assert register is 1, and start the reset generation logic;
[0202] 6) Determine the effective bit of the reset sequence register;
[0203] If the valid bit of the reset sequence register is 1, the single counter is started, counts to t0, outputs reset0, and clears the counter; counts to t1, outputs reset1, and clears the counter; counts to t2, outputs reset2, and clears the counter; and so on, until resetn is output; if a bit of the reset mask register is 1, the corresponding reset is held, and the value of the next reset interval register is taken for counting and comparison.
[0204] Alternatively, if the valid bit of the reset sequence register is 0, the multiple counters are started, and counters 0, 1, 2 to n are started at the same time, and count to t0, t0+t1, t0+t2, ..., t0+tn respectively, and output reset0, reset1, reset2, ..., resetn; if a bit of the reset mask register is 1, the corresponding counter does not start counting.
[0205] 7) Determine whether to bypass the reset synchronization. If bypass is "1", the reset is directly output; if bypass is "0", the reset is synchronized and then output;
[0206] 8) Determine whether all resets have been released. If all have been released, the highest position of the reset start register is set to 1. The processor reads this status and continues to the next step of the boot process;
[0207] Alternatively, if the reset release fails, the highest bit of the reset enable register maintains the reset value 0, and at the same time, the status of each reset is written into bits 30 to 1 of the reset enable register. The processor can obtain the enable information of each reset by reading the register.
[0208] Figure 8 A simple flowchart of the whole process of the method is shown in FIG. , which specifically includes:
[0209] Configure registers, reset start, determine the reset sequence configuration register valid bits, so as to identify whether the counter uses a single counter or multiple counters for counting operations; start the reset generation logic, determine whether the reset synchronization unit bypass is valid, and if so, reset the output asynchronously. Otherwise, reset the synchronous output. Then determine whether all resets have assert / de-assert. If yes, set the highest bit of the reset assert / de-assert register to 1, otherwise, set the highest bit of the reset assert / de-assert register to 0, and update each reset state, and end.
[0210] Since the whole process has been introduced in detail in the previous article, I will not go into details here.
[0211] Fig. 9 A comparative schematic diagram of implementing the reset sequence control register configuration using the method of the embodiment of the present application and the method in the related art is shown in FIG. Fig. 9 As shown: In the left figure, the data corresponding to the left side of the arrow, such as t0+1, represents time, t0 is the starting time, 1 is the instruction response time. In t0+t1+2, t0 is the starting time, t1 is the preset time interval, and 2 is the response time of the two instructions. The left side of the right figure takes the clock cycle as an example to count the time interval.
[0212] Fig. 9 The middle left figure is the code logic of the reset operation / release reset operation implemented by software in the related art. As can be seen from the figure, many functions and codes need to be written. The disadvantage of this solution is that it is necessary to write complex program codes, which are prone to errors, have high requirements on staff, require reaction time and response time for instruction execution, delay progress, and are not versatile. Codes need to be changed according to actual needs every time. The entire operation is not only cumbersome, error-prone, but also inefficient. The schematic diagram on the right is the hardware configuration process used in the embodiment of the present application. The configuration process is simple and easy to operate, and does not involve the reaction time and response time of software instruction execution. It is only necessary to count the number of clock cycles to determine the release time interval, and the method of calculating the execution time is simpler and easier to understand. Moreover, the hardware configuration does not require higher professionalism of the staff. This method is also more efficient.
[0213] In addition to the above, the present invention also supports the following application scenarios:
[0214] 1. It is based on the universal reset control circuit to realize the real-time control of reset without perception;
[0215] The present invention is based on a universal reset control circuit, and implements multiple resets to assert and de-assert one by one in a certain order and interval according to the defined reset configuration sequence. The purpose of "one-time configuration" and "permanent availability" of the reset sequence and interval is achieved. However, when the chip is in normal working state, there will be a need to reset some modules, such as PCIE linkdown reset. Fig.10 As shown in:
[0216] ① The reset control unit receives the link down reset request sent by PCIE and generates an interrupt to notify the CPU. After receiving the interrupt, the CPU enters the reset configuration process;
[0217] ②The CPU configures the reset mask register to mask out resets that do not need to be asserted;
[0218] ③CPU configures the reset assert register and starts the reset assert process;
[0219] ④ The reset control unit generates PCIE related resets in sequence and intervals according to the configuration.
[0220] In the above example, if the method of the present invention is adopted, when the same reset register configuration is used and the same reset process is started, only the reset mask register needs to be modified to realize the control of some reset signals without affecting other resets, thus achieving the purpose of real-time control of the reset without perception. At the same time, the expected reset interval can also be achieved.
[0221] Second, it is based on the universal reset control circuit to achieve customized reset control through efuse;
[0222] After the chip is taped out, the hardware circuit has been solidified. For different application scenarios, there are different combinations of internal chip modules, which brings about the need for different reset configuration processes.
[0223] The present invention can also be applied to application scenarios in which a customized reset control circuit is implemented through efuse.
[0224] That is, according to the usage of the subsystem or IP inside the chip, confirm the subsystem or IP that needs reset control, and burn the reset configuration register including the value of the reset mask register into efuse. After the chip is powered on, the configuration in efuse can be used directly to complete the customized reset generation.
[0225] like Fig.11 As shown in the figure, the same SoC chip has different application scenarios. Fig.11In the figure, component 1 only uses two of the four subsystems, system 1 and system 2, and system 3 and system 4 are not used. Therefore, the reset configuration data related to system 1 and system 2 are injected into the efuse of component 1, including reset sequence, reset interval, etc. Component 2 uses system 1 and system 3 among the four subsystems, and IP0, IP1, IP4, and IP5 in system 4. IP2, IP3, IP6, and IP7 in system 2 and system 4 are not used. Therefore, the reset configuration data of the related IPs in system 1 and system 3 and system 4 are injected into the efuse of the component.
[0226] In addition to the above, the scale and complexity of SoCs are gradually increasing, resulting in increasingly large reset control management units. When designing the reset architecture of SoCs, the software and hardware can be divided first to give full play to their respective advantages.
[0227] The above embodiment of the present invention is a reset control circuit with a wide range of applications and based on hardware implementation. Therefore, the idea of "software configuration, hardware curing" can also be applied to clock management, power management and initialization operations, combining the flexibility of software with the accuracy of hardware to improve the design robustness, security and reliability of mass-produced chip reset, clock, power management and other aspects.
[0228] The reset control method provided in this embodiment, when the system is not in working state, in order to reduce the system power consumption of the system on chip, when the system on chip is not in working state, the working state of the system on chip is first set to the reset operation state through the reset generation subcircuit, and the reset configuration register configuration subcircuit is used to determine the configuration mode of the reset release operation sequence and the reset release operation sequence of each intellectual property core. The reset interval counting subcircuit determines the execution time of each intellectual property core to perform the reset release operation according to the configuration mode of the reset release operation sequence; then, when the reset register configuration subcircuit detects that the system on chip is in working state, according to the reset release operation sequence and the execution time, the reset generation subcircuit is controlled to complete the reset release operation of one or more intellectual property cores. In this way, the reset configuration register configuration subcircuit and the reset interval counting subcircuit work together to ensure that the reset release operation is performed only when the system needs it, further reducing power consumption. Compared with the related art of realizing reset assert or de-assert operations by configuring the reset register and setting the instruction execution interval through software, the hardware execution of related operations is usually faster than software execution. Moreover, the hardware can accurately perform the reset release operation at the specified time under the control of the system clock to ensure the accuracy and stability of the system. Furthermore, hardware-executed reset release operations usually consume less power than software-executed ones. Hardware can directly control the on / off of the circuit, avoiding the calculation and data transmission during software execution, thereby reducing power consumption. Once the registers are defined, there is no need to adjust the instruction execution interval for the problem of inaccurate reset intervals, which has good versatility.
[0229] The embodiment of the present invention also provides a computer-readable storage medium. The reset control circuit provided by the above embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium and downloaded through a network, so that the reset control circuit described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor or hardware, the reset control circuit shown in the above embodiment is implemented.
[0230] A part of the present invention can be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide a reset control circuit and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of computer program instructions in computer-readable media includes but is not limited to source files, executable files, installation package files, etc., and accordingly, the way in which computer program instructions are executed by a computer includes but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium can be any available computer-readable storage medium or communication medium accessible to the computer.
[0231] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined by the appended claims.
Claims
1. A reset control circuit, characterized in that: The reset control circuit is applied to a system on chip, the system on chip includes a plurality of subsystems, each of the subsystems is composed of at least one intellectual property core, and the reset control circuit includes: a reset generation subcircuit, a reset register configuration subcircuit, and a reset interval counting subcircuit; The reset generation subcircuit is used to adjust the states of all the intellectual property cores to the reset operation state in sequence according to the indication information of the reset register configuration subcircuit when the system on chip is not in the working state; The reset register configuration subcircuit is used to determine the configuration mode of the reset release operation sequence and the reset release operation sequence of the intellectual property core; The reset interval counting subcircuit determines the execution time of the reset release operation of each of the intellectual property cores according to the configuration mode of the reset release operation sequence; The reset register configuration subcircuit is also used to control the reset generation subcircuit to complete the reset release operation of one or more intellectual property cores according to the reset release operation sequence and the execution time when it is detected that the on-chip system is in a working state.
2. The reset control circuit according to claim 1, characterized in that: The reset register configuration subcircuit includes: a reset sequence configuration register, at least one reset interval configuration register, and a reset release operation register, the number of the reset interval configuration registers is the same as the number of the intellectual property cores, and each of the reset interval configuration registers is used to control an intellectual property core to be adjusted to a reset operation state after a release time interval corresponding to itself; The reset sequence configuration register is used to instruct the reset interval configuration register to configure the reset release operation sequence of the intellectual property core when the first preset byte bit of the reset sequence configuration register is invalid; A first reset interval configuration register is used to determine the reset release operation sequence of the intellectual property core corresponding to itself according to its own identification information; monitor the clock cycle in the reset interval counting subcircuit; when it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the first intellectual property core corresponding to itself has been reached, control the second preset byte of the reset release operation register to be valid, wherein the first reset interval configuration register is any one of the at least one reset interval configuration register; The reset generation sub-circuit is used to configure the state of the first intellectual property core to a reset release operation state when recognizing that the second preset byte is valid; or, When the first preset byte of the reset sequence configuration register is valid, the reset sequence configuration register is used to configure the reset release operation sequence of the intellectual property core, wherein, when the reset sequence configuration register configures the reset release operation sequence of the intellectual property core, the placeholder position of the bytes other than the first preset byte and the third preset byte in the reset sequence configuration register determines the reset release operation sequence of the intellectual property core, wherein the first preset byte and the third preset byte are both bytes at fixed positions in the reset sequence configuration register; A second reset interval configuration register is used to monitor the clock cycle in the reset interval counting subcircuit; when it is determined based on the clock cycle that the execution time corresponding to the reset release operation of the second intellectual property core corresponding to itself has been reached, the second preset byte of the reset release operation register is controlled to be valid, wherein the second reset interval configuration register is any one of the at least one reset interval configuration register; The reset generation sub-circuit is used to configure the state of the second intellectual property core to a reset release operation state when it is recognized that the second preset byte is valid.
3. The reset control circuit according to claim 2, characterized in that: The reset register configuration subcircuit further includes: resetting the mask register; The reset mask register is used to mask the target intellectual property core, and the state of the masked target intellectual property core is not controlled by the reset generation subcircuit and maintains the original state, wherein the target intellectual property core is any intellectual property core to be masked.
4. The reset control circuit according to claim 2, characterized in that: The reset register configuration subcircuit further includes: a reset operation register; The reset operation register is used to receive a start-up execution instruction sent by the reset sequence configuration register or the reset interval configuration register; according to the start-up execution instruction, the fourth preset byte of the reset operation register is set to be valid; The reset generation sub-circuit is further used to configure the state of the third intellectual property core to a reset operation state when it is confirmed that the fourth preset byte is valid, wherein the third intellectual property core is any intellectual property core.
5. The reset control circuit according to claim 4, characterized in that: The reset interval counting subcircuit includes a single counter, a multi-counter, a selector, and a processor; The selector is used to receive a selection signal generated by the reset register configuration subcircuit; The processor is used to control the single counter to perform work when the selection signal is valid, so as to determine the execution time corresponding to the reset release operation of each of the intellectual property cores; or, When the selection signal is invalid, the multi-counter is controlled to work so as to determine the execution time corresponding to the reset release operation of each of the intellectual property cores.
6. The reset control circuit according to claim 5, characterized in that: The processor is specifically used for: Based on the execution time corresponding to the reset release operation of the third intellectual property core, controlling the single counter to count the clock cycle; When the preset number of clock cycles is reached, determining the execution time corresponding to the reset release operation of the second intellectual property core, wherein the number of the preset clock cycles is determined according to the release time interval corresponding to the reset release operation of the preconfigured intellectual property core; Clear the statistical count value in the single counter.
7. The reset control circuit according to claim 5, characterized in that: The processor is specifically used for: Respectively extracting the release time interval configured in each of the reset interval configuration registers; determining a number of clock cycles based on the release time interval; Taking a preset time as a starting time, counting in parallel on the multiple counters, and counting the number of the clock cycles respectively; Determine the moment when the number of clock cycles counted by the counter corresponding to the second intellectual property core reaches the same number of clock cycles as the release time interval configured in the reset interval configuration register corresponding to itself, as the execution moment corresponding to the reset release operation of the second intellectual property core.
8. The reset control circuit according to any one of claims 1 to 7, characterized in that: The reset control circuit further comprises: a reset synchronization subcircuit; The reset synchronization subcircuit is used to instruct the reset generation subcircuit to output the signals sequentially output synchronously or asynchronously, wherein the output signal is used to control the state of the intellectual property core to be adjusted to a preset state, and the preset state is the reset operation state or the reset release operation state.
9. A reset control method, characterized in that: The method is applied to a system on chip, wherein the system on chip includes a plurality of subsystems, each of which is composed of at least one intellectual property core, and the reset control circuit includes: a reset generation subcircuit, a reset register configuration subcircuit, and a reset interval counting subcircuit; the method includes: When the system on chip is not in the working state, the reset generation subcircuit sequentially adjusts the states of all the intellectual property cores to the reset operation state according to the first indication information of the reset register configuration subcircuit; The reset register configuration subcircuit determines a configuration mode of a reset release operation sequence, and a reset release operation sequence of the intellectual property core; The reset interval counting subcircuit determines the execution time of each of the intellectual property cores performing the reset release operation according to the configuration mode of the reset release operation sequence; When the reset register configuration subcircuit detects that the system on chip is in working state, the reset register configuration subcircuit controls the reset generation subcircuit to complete the reset release operation on one or more intellectual property cores according to the reset release operation sequence and the execution time.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the reset control method according to any one of claims 1 to 7.
