Distributed interrupt control methods, distributed interrupt systems and devices
By using a distributed interrupt control method, interrupt signal transmission is performed in a multi-chip system using a serial communication protocol and a daisy-chain topology. This solves the problems of low bus transmission efficiency and poor reliability, and enables flexible and scalable interrupt handling.
Patent Information
- Application Number
- CN202611041500.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-14
- Publication Date
- 2026-11-10
- Estimated Expiration
- 2046-07-14
AI Technical Summary
In multi-chip systems, transmitting interrupt signals via a bus results in low data transmission efficiency and poor overall reliability. Furthermore, the system is highly dependent on the bus and is prone to interrupt signals failing to be transmitted in a timely manner due to bus failures.
A distributed interrupt control method is adopted, which uses a serial communication protocol and a daisy-chain topology to connect chips. Cross-chip data transmission is performed through the interrupt controller on each chip, avoiding reliance on complex buses and dedicated cross-chip modules, and realizing flexible and scalable interrupt routing.
It improves data transmission scalability and overall reliability, reduces dependence on the bus, avoids performance bottlenecks and reliability risks, and achieves highly flexible and scalable interrupt handling.
Smart Images

Figure CN122547725B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a distributed interrupt control method, a distributed interrupt system, and a device. Background Technology
[0002] In existing multi-die system architectures, cross-die interrupt transmission mainly relies on bus communication mechanisms.
[0003] However, transmitting interrupt signals via the bus consumes a significant amount of bus bandwidth, leading to reduced data transmission efficiency. Furthermore, the excessive reliance on cross-die modules and bus links means that if a cross-die bus fails or hangs, critical cross-die interrupt signals cannot be transmitted in a timely manner, causing the system to be unable to respond to critical errors.
[0004] Therefore, transmitting interrupt signals via the bus reduces the data transmission efficiency and overall reliability of the system. Summary of the Invention
[0005] The main objective of this application is to provide a distributed interrupt control method, a distributed interrupt system, and a device, which aims to solve the technical problems of poor data transmission scalability and low overall reliability caused by interrupt signal transmission via a bus.
[0006] To achieve the above objectives, this application proposes a distributed interrupt control method applied to a distributed interrupt system. The distributed interrupt system includes multiple chips interconnected via physical links. Each chip is configured with an interrupt controller. Data transmission between the chips is performed across chips via a serial communication protocol. The physical links between the chips form a daisy-chain topology. The distributed interrupt control method includes: When any interrupt controller receives an interrupt request, the interrupt controller forwards the interrupt request to the target chip via a serial communication protocol based on the target chip information carried in the interrupt request.
[0007] In one embodiment, each chip is internally configured with multiple functional sub-modules, a pre-distributor, and a protocol conversion module. Each functional sub-module is configured with an independent interrupt control unit, and each interrupt control unit manages an interrupt source. Before the step of any interrupt controller forwarding the interrupt request to the destination chip based on the destination chip information carried in the interrupt request, the method further includes: The pre-distributor receives interrupt requests sent by the interrupt control unit of the local chip or interrupt requests sent to the local chip via the serial communication protocol by the interrupt control unit of the remote chip, and determines whether the target chip is the local chip. If it is a local chip, the interrupt request is sent to the corresponding interrupt controller, and the corresponding interrupt controller forwards the interrupt request to the local chip; If it is not a local chip, the interrupt request is sent to the corresponding protocol conversion module, which then sends the interrupt request to the target chip.
[0008] In one embodiment, each interrupt control unit is configured with a domain isolation module, and each interrupt is pre-configured with a domain attribute register. The step of the pre-distributor receiving an interrupt request sent by the interrupt control unit of the local chip or an interrupt request sent to the local chip by the interrupt control unit of a remote chip through the serial communication protocol includes: Each interrupt control unit, based on the domain attribute register corresponding to each interrupt, merges interrupt requests belonging to the same domain from the corresponding interrupt source into a single signal and sends it to the corresponding pre-distributor.
[0009] In one embodiment, each interrupt is configured with an interrupt control register, the domain isolation module generates a register mask signal according to the domain of each interrupt, and after the step of any interrupt controller forwarding the interrupt request to the destination chip via a serial communication protocol based on the destination chip information carried in the interrupt request, the method further includes: When the interrupt controller of the target chip receives the interrupt request, it responds to the interrupt request by determining whether the operating domain of the target chip is consistent with the domain to which the interrupt request belongs, and whether the access permission of the operating domain is equal to or higher than the access permission of the corresponding interrupt control register. If the running domain is the same as the domain to which the interrupt request belongs, and the access permission of the running domain is equal to or higher than the access permission of the interrupt control register, then access to the corresponding interrupt control register is permitted.
[0010] In one embodiment, the access permissions of the register are the highest permissions of the current domain mode, which is determined based on a preset domain attribute configuration table during the chip initialization phase.
[0011] In one embodiment, each interrupt control unit is further configured with an internal state machine, and each interrupt is further configured with an enable register, an inject register, a type register, and a status register. The enable register is used to control whether the interrupt is enabled, the inject register is used to support software-injected interrupts, the type register is used to identify whether the corresponding interrupt is level-triggered or edge-triggered, and the status register is used to store the interrupt status. The step of the pre-distributor receiving an interrupt request sent by the interrupt control unit of the local chip or an interrupt request sent to the local chip by the interrupt control unit of the remote chip through the serial communication protocol includes: Each interrupt control unit's internal state machine sends the interrupt request from the corresponding interrupt source to the corresponding pre-distributor based on the enable register, inject register, type register, and status register.
[0012] In one embodiment, the protocol conversion module is configured with an interrupt state machine, which is used to control the state transition of an interrupt. The step of the corresponding protocol conversion module sending the interrupt request to the target chip includes: The corresponding protocol conversion module sends the interrupt request to the destination chip according to the interrupt state machine, wherein the interrupt state machine includes at least one of the following: idle state, waiting to be sent state, sent state, and cleared state.
[0013] Furthermore, to achieve the above objectives, this application also proposes a distributed interrupt system, which includes: The distributed interrupt system includes multiple chips interconnected by physical links. Each chip is equipped with an interrupt controller. The chips transmit data across chips via a serial communication protocol, and the physical links between the chips form a daisy-chain topology. Any interrupt controller is used to forward the interrupt request to the target chip via a serial communication protocol when it receives an interrupt request, based on the target chip information carried in the interrupt request.
[0014] In one embodiment, each chip is internally configured with multiple functional sub-modules, a pre-distributor and a protocol conversion module. Each functional sub-module is configured with an independent interrupt control unit. Each interrupt control unit manages an interrupt source. Each interrupt control unit is configured with a domain isolation module. Each interrupt is pre-configured with a domain attribute register. The interrupt control unit is also used to send the interrupt request of the corresponding interrupt source to the corresponding pre-distributor, determine whether the target chip is a local chip, if it is a local chip, send the interrupt request to the corresponding interrupt controller, and the corresponding interrupt controller forwards the interrupt request to the local chip; if it is not a local chip, send the interrupt request to the corresponding protocol conversion module. The protocol conversion module is used to send the interrupt request to the target chip.
[0015] In addition, to achieve the above objectives, this application also proposes a distributed interrupt control device, which includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the distributed interrupt control method described above.
[0016] One or more technical solutions proposed in this application have at least the following technical effects: This application's distributed interrupt system includes multiple chips interconnected via physical links. Each chip is equipped with an interrupt controller, and the chips transmit data across chips via a serial communication protocol. The physical links between the chips form a daisy-chain topology. It can be understood that this application configures an interrupt controller on each chip, allowing interrupt handling capabilities to be distributed across various nodes, avoiding the performance bottlenecks and reliability risks associated with a single central interrupt processor. Furthermore, by employing a serial communication protocol for cross-chip interrupt transmission and utilizing a daisy-chain topology to connect the chips, a flexible and scalable physical network is constructed with minimal physical pins and wiring resources.
[0017] When any interrupt controller receives an interrupt request, it forwards the interrupt request to the target chip via a serial communication protocol based on the target chip information carried in the interrupt request. This achieves an interrupt routing mechanism that does not rely on complex buses and dedicated cross-chip modules, is compatible with the cross-die operation of interrupt controllers, and achieves greater flexibility and scalability. It solves the problems of poor data transmission scalability and low overall reliability caused by interrupt signal transmission via bus. Attached Figure Description
[0018] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0019] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0020] Figure 1 This is an architecture diagram of the distributed interrupt system provided in Embodiment 1 of the distributed interrupt control method of this application; Figure 2 This is a daisy-chain topology diagram provided in Embodiment 1 of the distributed interruption control method of this application; Figure 3 This is a schematic diagram of the first scenario of the distributed interrupt control method provided in Embodiment 2 of this application; Figure 4 This is a schematic diagram of a second scenario for the distributed interrupt control method provided in Embodiment 2 of this application; Figure 5 This is a schematic diagram of a third scenario for the distributed interrupt control method provided in Embodiment 3 of this application; Figure 6This is a schematic diagram of the fourth scenario of the distributed interrupt control method provided in Embodiment 3 of this application; Figure 7 This is a schematic diagram of the device structure of the hardware operating environment involved in the distributed interrupt control method in this application embodiment.
[0021] The purpose, features, and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0022] It should be understood that the specific embodiments described herein are merely illustrative of the technical solutions of this application and are not intended to limit this application.
[0023] To better understand the technical solution of this application, a detailed description will be provided below in conjunction with the accompanying drawings and specific implementation methods.
[0024] It should be noted that the executing entity in this embodiment can be a computing service device with data processing, network communication, and program execution functions, such as a tablet computer, personal computer, or mobile phone, or an electronic device or distributed interrupt system capable of implementing the above functions. The following description uses a distributed interrupt system as an example to illustrate this embodiment and the subsequent embodiments.
[0025] Based on this, this application provides a distributed interrupt control method. In this embodiment, the distributed interrupt control method includes: When any interrupt controller receives an interrupt request, the interrupt controller forwards the interrupt request to the target chip via a serial communication protocol based on the target chip information carried in the interrupt request.
[0026] It should be noted that the distributed interrupt control method in this embodiment is applied to a distributed interrupt system, refer to... Figure 1 The distributed interrupt system comprises multiple chips interconnected by physical links, each chip is configured with an interrupt controller, and the chips transmit data across chips via a serial communication protocol; refer to Figure 2 The physical links between the chips form a daisy-chain topology.
[0027] Serial communication protocols transmit data bit by bit through one or more data lines, requiring fewer pins compared to parallel communication. The serial communication protocol can be either I2C (Inter-Integrated Circuit) or SPI (Serial Peripheral Interface). This embodiment preferably uses the lower-cost and more reliable I2C protocol. A daisy-chain topology connects multiple devices end-to-end via physical links, forming a chain from which signals can be transmitted sequentially.
[0028] It should be noted that this daisy-chain topology can be either a unidirectional or bidirectional daisy-chain, such as... Figure 2 The diagram shows a unidirectional daisy-chain topology formed by chips 0 to 4.
[0029] An interrupt request is a signal issued by a hardware device (such as a peripheral) or software. It is used to notify the processor of events that require immediate handling. The interrupt request carries destination chip information, which identifies the chip that needs to process the interrupt.
[0030] When an interrupt controller on any chip in a distributed interrupt system receives an interrupt request, it parses the information attached to the request: the destination chip information. Instead of relying on a traditional data bus, the interrupt controller encapsulates the interrupt request into a data packet conforming to a pre-established serial communication protocol between chips, based on the destination chip information. This packet is then transmitted via a daisy-chain topology physical link until it reaches the specified destination chip.
[0031] Specifically, the way to send data packets to the destination chip through the physical link of the daisy chain topology can be as follows: when the destination chip is not an adjacent chip, the data packet is sent to the adjacent chip, and the adjacent chip sends the data packet to the destination chip in the same way.
[0032] It is understood that this application configures an interrupt controller on each chip, enabling interrupt handling capabilities to be distributed across various nodes, thus avoiding the performance bottlenecks and reliability risks associated with a single central interrupt processor. Simultaneously, by employing a serial communication protocol for cross-chip interrupt transmission and utilizing a daisy-chain topology to connect chips, a flexible and scalable physical network is constructed with minimal physical pins and wiring resources.
[0033] Specifically, refer to Figure 1Each functional submodule (e.g., functional submodule 0 to functional submodule n) integrates an independent interrupt control unit to manage interrupt requests generated by its corresponding peripherals or local events. The interrupt outputs of all functional submodules converge to a central pre-distributor, which is responsible for the initial routing of interrupts according to a preset strategy. The output of the pre-distributor is connected to the main interrupt controller for unified scheduling and distribution to each processor core. On the other hand, through the protocol conversion module int to iic, some interrupts are encapsulated into serial communication data packets and sent to other chips or remote nodes via the serial communication protocol bus. The protocol conversion module iic to int is used to receive remote interrupt requests from the external serial bus, unpack them, and inject them into the pre-distributor to achieve cross-chip interrupt interoperability. Finally, the interrupt controller interacts bidirectionally with multiple processor cores (processor core 0 to processor core n) through the shared bus to complete the final delivery and response of interrupts.
[0034] When any interrupt controller receives an interrupt request, it forwards the interrupt request to the target chip via a serial communication protocol based on the target chip information carried in the interrupt request. This achieves an interrupt routing mechanism that does not rely on complex buses and dedicated cross-chip modules, is compatible with the cross-die operation of interrupt controllers, and achieves greater flexibility and scalability. It solves the problems of poor data transmission scalability and low overall reliability caused by interrupt signal transmission via bus.
[0035] Based on the first embodiment of this application, in the second embodiment of this application, the same or similar content as the above embodiment can be referred to the above description, and will not be repeated hereafter. On this basis, each chip is internally configured with multiple functional sub-modules, a pre-distributor, and a protocol conversion module. Each functional sub-module is configured with an independent Interrupt Control Unit (intc), and each interrupt control unit manages an interrupt source. Before the step of any interrupt controller forwarding the interrupt request to the destination chip according to the destination chip information carried in the interrupt request, the method further includes: The pre-distributor receives interrupt requests sent by the interrupt control unit of the local chip or interrupt requests sent to the local chip via the serial communication protocol by the interrupt control unit of the remote chip. It determines whether the destination chip is a local chip. If it is a local chip, it sends the interrupt request to the corresponding interrupt controller, which forwards the interrupt request to the local chip. If it is not a local chip, it sends the interrupt request to the corresponding protocol conversion module, which then sends the interrupt request to the destination chip.
[0036] It should be noted that a functional submodule is an independent logical unit within the chip that performs a specific function, such as a CPU core, a GPU core, a memory controller, or a specific I / O interface controller; a functional submodule is also the source of interrupt signals. The interrupt control unit (intc) within each functional submodule is responsible for preprocessing interrupts generated by the peripherals of the current submodule.
[0037] The pre-distributor receives interrupt requests from various interrupt control units within the local chip, as well as interrupt statuses from remote dies transmitted via a serial communication protocol (using I2C as an example). The pre-distributor determines the distribution based on the destination chip information corresponding to each interrupt (including remote interrupts). Reference Figure 3 The pre-distributor determines whether the target of the interrupt is the current chip or a remote chip based on the destination chip information carried in the interrupt request; or, the pre-distributor determines whether the chip identifier of the destination chip of the remote interrupt is consistent with that of the local chip.
[0038] If the destination of the interrupt is determined to be the processor core of this chip, the interrupt is forwarded to the local interrupt controller. Upon receiving the interrupt from the pre-distributor, the local interrupt controller will forward the interrupt to the corresponding processor core on this chip via the chip's internal bus, based on the interrupt configuration information. If the destination of the interrupt is determined to be the processor core of a remote chip, the interrupt is forwarded to the protocol conversion module (int_to_iic), which then forwards the interrupt to the remote chip via the IIC protocol.
[0039] Specifically, to achieve bidirectional conversion between interrupt requests and the serial communication protocol, the protocol conversion module in this embodiment includes two modules: interrupt to IIC (int_to_iic) and IIC to interrupt (iic_to_int). See reference... Figure 4 The interrupt-to-IIC module (int_to_IIC) is responsible for converting interrupt requests that need to be sent to a remote chip into a data format that conforms to the IIC protocol and then sending it out. The interrupt-to-IIC module internally includes: an interrupt state machine, register space, protocol conversion interface, and the first IIC module.
[0040] The interrupt state machine is used to control the state transitions during interrupt transfers across chips. The states of the interrupt state machine include at least: IDLE state: Initial state, indicating that it is waiting to send without interruption; PENDING status: This indicates that an interrupt has been triggered, but it has not been sent out yet because the IIC bus is busy or it is not yet the turn of the interrupt. SENT status: indicates that the corresponding interrupt has been successfully sent to the remote chip via the IIC protocol; CLEAR status: Indicates that the current interrupt has been cleared.
[0041] The register space is used to record the current transmission status of each interrupt. When the state of the interrupt state machine changes, the corresponding status bits in the registers are also updated synchronously, allowing software to query the transmission status of the interrupt through register access.
[0042] The protocol conversion interface is responsible for converting the register access protocol (reg access) into the APB (Advanced Peripheral Bus) protocol required by the IIC module. This interface has two input sources: interrupt information and IIC configuration information, thus enabling 2-to-1 multiplexing. During the configuration phase, register access takes over the IIC's APB interface for initializing the IIC module; during the interrupt transmission phase, interrupt information takes over the IIC's APB interface for sending interrupt data.
[0043] The first IIC module is used to implement the standard IIC protocol and is responsible for transmitting interrupt data to the remote chip via a physical link.
[0044] Reference Figure 5 The IIC-to-interrupt module (iic_to_int) receives IIC data from a remote chip, restores the IIC data to an interrupt request signal, and then outputs it to the local pre-distributor. Internally, the IIC-to-interrupt module includes a control state machine, register space, a protocol conversion interface, and a second IIC module.
[0045] The control state machine manages the process of receiving remote interrupts from the I2C interface. The states of the control state machine include at least: IDLE state: Initial state, after the iic module configuration phase is completed, it enters the READ_RXFIFO state; READ_RXFIFO state: In this state, the flag register of the IIC module is continuously read to check if new data has arrived; when a valid flag is read, the system enters the READ_RDATA state. READ_RDATA state: In this state, the RDATA register of the iic module is read to obtain the received data; after reading is completed, the state jumps back to IDLE state and the read data is transferred to the output interrupt.
[0046] The register space is used to record the interrupt reception status and can generate a clear signal.
[0047] The second IIC module implements the standard IIC protocol and is responsible for receiving IIC input data from remote chips.
[0048] Specifically, refer to Figure 6 The domain isolation module receives configuration data from the register interface, the current security domain status signal, and external non-security domain forced signals. Through internal comparison logic and mask generation circuitry, it dynamically outputs global domain masking signals and domain-specific masking signals for different security domains (such as security domain, non-security domain, root domain, and trusted domain). Each interrupt control subunit independently manages a specific interrupt source. Internally, it includes a combinational logic module for signal preprocessing or priority encoding, a register group for storing enable states and domain attributes, a main masking logic module for integrating software configuration and hardware domain policies, and a state machine for managing the interrupt suspension, activation, and clearing lifecycle. Based on the decision result of the main masking logic, each interrupt control subunit accurately routes the interrupt request and outputs it to the corresponding target domain interrupt signal line (including non-security domain interrupt output, security domain interrupt output, root domain interrupt output, and trusted domain interrupt output), thereby achieving fine-grained interrupt isolation and targeted distribution based on security domain attributes at the hardware level.
[0049] In one feasible implementation, the protocol conversion module is configured with an interrupt state machine, which controls the state transitions of interrupts. The step of the corresponding protocol conversion module sending the interrupt request to the target chip includes: The corresponding protocol conversion module sends the interrupt request to the destination chip according to the interrupt state machine, wherein the interrupt state machine includes at least one of the following: idle state, waiting to be sent state, sent state, and cleared state.
[0050] Taking the interrupt-to-iIC module (int_to_iIC) as an example, the interrupt state machine inside the protocol conversion module is responsible for managing the complete lifecycle of each cross-chip interrupt to be sent. This interrupt state machine includes: Idle state (IDLE): The initial state, indicating that there is currently no interruption and it is waiting to send, or the serial communication link is in an idle state; PENDING status: This indicates that an interrupt request has been received, but because the serial communication link is occupied by other interrupts or the bus is busy, the interrupt request has not yet started to be sent and is waiting for the link to become available. SENT status: Indicates that the interrupt request has been successfully sent to the remote chip via the serial communication protocol, and is waiting for confirmation of completion. Clear status (CLEAR): This indicates that the interrupt request has been successfully received and processed by the remote chip, the current interrupt transmission process has ended, and it is ready to clear the relevant status.
[0051] During interrupt transmission, the protocol conversion module sends the interrupt request to the destination chip based on the state transitions of the interrupt state machine. Specifically: When the pre-distributor hands over an interrupt request to the protocol conversion module, the interrupt state machine transitions from the idle state to the pending-to-send state, indicating that the interrupt is ready but not yet sent. The protocol conversion module continuously monitors the busy / idle status of the serial communication link. When the link is idle, the interrupt state machine transitions to the sent state and encapsulates the interrupt request into a data packet conforming to the serial communication protocol via the protocol conversion interface and the ICC module, then sends it out. After transmission, the interrupt state machine waits for confirmation from the remote chip. Upon confirmation, it transitions to the clear state, completing the interrupt transmission, and finally returns to the idle state to prepare for the next interrupt.
[0052] Interrupt state machines can precisely control each stage of an interrupt, from reception and waiting to transmission and acknowledgment. This ensures that interrupt requests are orderly buffered when the serial communication link is busy, avoiding conflicts; and that they are sent promptly when the link is idle, minimizing transmission latency. In a daisy-chain topology where multiple chips share a link, the transmission of multiple interrupts can proceed in an orderly manner, avoiding conflicts and contention, and ensuring that each interrupt reliably reaches its destination. This achieves reliable state management of the cross-chip interrupt transmission process, ensuring that each interrupt is delivered to the destination chip in an orderly and complete manner.
[0053] Specifically, the preprocessing module receives the original interrupt request signal and performs preliminary filtering or synchronization; the configuration register group stores the software configuration information of the interrupt source, including the interrupt enable bit, target security domain attributes, and priority parameters; the main masking logic module, as the core decision unit, has its inputs connected to the global domain masking signal from the domain isolation module, the dedicated masking signal for the current domain, and the local enable signal in the configuration register, respectively. Through a combination of OR and AND gates, it comprehensively determines whether the interrupt should be allowed to pass; if the masking conditions are not met, the interrupt request is blocked; if all masking conditions are lifted, the valid interrupt signal is sent to the interrupt state machine; this state machine manages the interrupt's lifecycle, including setting the interrupt to a pending state, transitioning to an active state after processor response, and performing a clear operation after processing, ultimately generating and outputting a final interrupt trigger signal pointing to a specific security domain (such as a non-security domain, security domain, root domain, or trusted domain); refer to Figure 6 .
[0054] By introducing a pre-distributor layer inside the chip, which is specifically responsible for the initial routing decision of interrupt requests, the core interrupt controller does not need to handle all the source sending logic of interrupts. This hierarchical approach to interrupt handling reduces the load on the interrupt controller.
[0055] Meanwhile, by configuring an independent interrupt control unit for each functional submodule, distributed management of interrupt sources is achieved. For interrupts that need to be transmitted across chips, because this architecture distributes interrupt processing to various submodules and pre-distributor levels, when an interrupt in one submodule fails, its impact is limited to that module and will not spread to the interrupt processing of other submodules. This significantly reduces the coupling between system interrupt processing modules and improves system reliability and maintainability.
[0056] Based on the first and second embodiments of this application, in the third embodiment of this application, the same or similar content as the above embodiments can be referred to the above description, and will not be repeated hereafter. On this basis, each interrupt control unit is configured with a domain isolation module, and each interrupt is pre-configured with a domain attribute register. The specific implementation of the pre-distributor receiving interrupt requests sent by the interrupt control unit of the local chip or interrupt requests sent to the local device by the interrupt control unit of the remote chip through the serial communication protocol can be as follows: Each interrupt control unit, based on the domain attribute register corresponding to each interrupt, merges interrupt requests belonging to the same domain from the corresponding interrupt source into a single signal and sends it to the corresponding pre-distributor.
[0057] Traditionally, a centralized interrupt control approach is used. In this approach, interrupts generated by all peripherals within the chip converge to a single interrupt handler (e.g., PLIC), which then handles arbitration and forwarding. This centralized architecture presents the following problems in large-scale chips: First, all interrupts flow through the same interrupt handler, resulting in extremely complex interrupt routing paths. As chip size increases, path latency and complexity increase significantly. Second, the single interrupt handler bears the burden of processing all interrupts, becoming a performance bottleneck and a potential single point of failure.
[0058] To address this issue, this embodiment further enhances the functionality of the interrupt control unit (INTC). In this embodiment, each interrupt control unit is equipped with a domain isolation module, and a domain attribute register (DOM register) is pre-configured for each interrupt. This domain attribute register stores the security domain information to which the interrupt belongs, and this security domain information can be pre-configured by the chip.
[0059] In the interrupt handling process, each interrupt control unit, based on the domain attribute register corresponding to each interrupt, merges multiple interrupt requests from interrupt sources belonging to the same security domain into a single signal, and then sends it to the corresponding pre-dispatch unit. Specifically, the domain isolation module reads the configuration of the domain attribute registers of each interrupt, groups interrupts with the same domain attribute into one category, and uses internal logic to merge multiple interrupt requests within the same domain into a single aggregated interrupt signal for output.
[0060] Because each interrupt control unit classifies and merges interrupts at their source based on their security attributes through domain isolation modules and domain attribute registers, multiple interrupt requests from the same security domain are integrated into a single signal. This significantly reduces the number of interrupt signals output by the interrupt control unit to the pre-distributor, reduces the wiring complexity of internal interrupt interconnection and the processing pressure on subsequent modules, and achieves the effect of interrupt aggregation and preprocessing, making it suitable for large-scale chip application scenarios.
[0061] Meanwhile, since interrupts are processed separately by domain at the source, interrupt signals from different security domains are physically isolated onto different aggregated signal lines. This effectively prevents interrupts from non-security domains from interfering with interrupt signals from security domains, ensuring the safe isolation of interrupts.
[0062] like Figure 6 The diagram shows the internal logic circuit structure of the domain isolation module. The domain isolation module mainly includes a register interface module, a domain matching comparator group, mask generation logic, and a multiplexer. The register interface module is used to receive the interrupt domain attribute register value configured by the software. <reg>The domain matching comparator group works in parallel. On the one hand, it compares the target domain identifier (req) of the current interrupt request with the processor's current running domain identifier (dom_cur_value). On the other hand, it compares the current running domain identifier with predefined security domain constants (such as _mask). <secure>、<NON_SECURE>、 <root> 、 <realm>The matching and decoding are performed; the mask generation logic merges the above comparison results with the register configuration value through an "OR" operation to generate a comprehensive masking signal; finally, the multiplexer routes the comprehensive masking signal to the corresponding output port according to the domain matching and decoding results, and generates independent masking control signals (intr_mask_non_sec (non-secure world interrupt), intr_mask_sec (secure world interrupt), intr_mask_root (root domain interrupt), intr_mask_realm (realm domain interrupt)) for the non-secure domain, secure domain, root domain, and trusted domain, respectively, thereby ensuring at the hardware level that interrupt requests can only be passed to their authorized target secure domain, and achieving strict inter-domain isolation.
[0063] like Figure 3 The diagram illustrates the internal logic architecture of the pre-distributor. This pre-distributor mainly includes an interrupt input interface array, a priority arbitration module, a routing policy lookup table (Routing LUT), a protocol encapsulation / decapsulation unit, and a multi-output distribution matrix. The interrupt input interface array receives raw interrupt request signals in parallel from multiple functional sub-modules or remote nodes. The priority arbitration module performs hardware-level priority sorting and conflict resolution on multiple interrupt requests arriving simultaneously, ensuring that high-priority events are processed first. The routing policy lookup table stores preset interrupt routing rules and queries the target processor core or target communication port based on the interrupt source ID or attribute tag. For interrupts requiring cross-chip transmission, the protocol encapsulation unit converts them into serial communication data packets and sends them via the int to iic interface; conversely, the iic to int interface receives external data packets and restores them to local interrupt signals. Finally, the multi-output distribution matrix, based on the arbitration result and routing query conclusion, accurately delivers the interrupt request to the corresponding input channel of the main interrupt controller or directly to a specific processor core, achieving low-latency, high-concurrency interrupt pre-scheduling and dynamic load balancing.
[0064] In one feasible implementation, each interrupt is configured with an interrupt control register, the domain isolation module generates a register mask signal according to the domain of each interrupt, and after the step of any interrupt controller forwarding the interrupt request to the destination chip via a serial communication protocol based on the destination chip information carried in the interrupt request, the method further includes: When the interrupt controller of the target chip receives the interrupt request, it responds to the interrupt request by determining whether the operating domain of the target chip is consistent with the domain to which the interrupt request belongs, and whether the access permission of the operating domain is equal to or higher than the access permission of the corresponding interrupt control register. If the operating domain is consistent with the domain to which the interrupt request belongs, and the access permission of the operating domain is equal to or higher than the access permission of the interrupt control register, then access to the corresponding interrupt control register is allowed.
[0065] Within each interrupt control unit, the domain isolation module generates a corresponding register mask signal based on the domain attributes of each interrupt. This mask signal is used to block register access requests that do not meet the domain requirements. Specifically, when software or hardware attempts to access the interrupt control register of an interrupt, the domain isolation module reads the configuration of the domain attribute register corresponding to that interrupt, checks whether the current accessor's execution domain is consistent with the domain to which the interrupt belongs, and determines whether the access permission of the execution domain is equal to or higher than the access permission of the corresponding interrupt control register; if they are inconsistent or the access permission of the execution domain is lower than the access permission of the interrupt control register, the access is blocked.
[0066] The access permissions of the registers are the highest permissions of the current domain mode, which is determined based on a preset domain attribute configuration table during the chip initialization phase.
[0067] During chip initialization, the current domain mode is determined based on a preset domain attribute configuration table. Register access permissions are set to the highest level for the current domain mode. For example, in the Trust Zone CCA (Confidential Computing Architecture), multiple domains are supported, including root, realm, sec, and non-sec. The root world has the highest access permission, allowing access to all interrupt control registers; permissions decrease sequentially for the realms of realm, secure, and non-secure. In the traditional Trust Zone architecture, the secure world has the highest access permission among the sec and non-sec domains.
[0068] The operating domain refers to the current secure operating mode of the chip. For example, in the Trust Zone CCA architecture, it can be Root, Realm, Secure, or Non-secure mode, while in the traditional Trust Zone architecture, it can be Secure or Non-secure mode.
[0069] After an interrupt request is forwarded to the destination chip, the interrupt controller of the destination chip, upon receiving the interrupt request, will respond by determining whether the current operating domain of the destination chip is consistent with the security domain to which the interrupt request belongs; and whether the access permission level of the operating domain is equal to or higher than the access permission level required by the interrupt control register to be accessed. Access to the corresponding interrupt control register is only permitted when the operating domain is the same as the interrupt domain and the access permission of the operating domain is equal to or higher than the access permission of the interrupt control register. If either condition is not met, a register masking signal generated by the domain isolation module will prevent the access, thereby ensuring that only entities with the appropriate domain permissions can operate on specific interrupt resources.
[0070] This embodiment places a domain isolation module in each interrupt control unit to isolate interrupts from different security domains and adapts to both Trust Zone CCA and traditional Trust Zone domain modes to ensure interrupt security. At the same time, this distributed interrupt control architecture effectively reduces the coupling between interrupts, ensuring that a failure in one interrupt will not affect the interrupt process of other submodules.
[0071] Based on the first, second, and third embodiments of this application, in the fourth embodiment of this application, the content that is the same as or similar to the above embodiments can be referred to the above description, and will not be repeated hereafter. On this basis, each interrupt control unit is also configured with an internal state machine, and each interrupt is also configured with an enable register, an inject register, a type register, and a status register. The enable register is used to control whether the interrupt is enabled, the inject register is used to support software-injected interrupts, the type register is used to identify whether the corresponding interrupt is level-triggered or edge-triggered, and the status register is used to store the interrupt status. The step of the pre-distributor receiving an interrupt request sent by the interrupt control unit of the local chip or an interrupt request sent to the local chip by the interrupt control unit of the remote chip through the serial communication protocol includes: Each interrupt control unit's internal state machine sends the interrupt request from the corresponding interrupt source to the corresponding pre-distributor based on the enable register, inject register, type register, and status register.
[0072] In this embodiment, each interrupt control unit is equipped with an internal state machine, and each interrupt source is configured with independent enable, inject, type, and status registers. When the interrupt control unit needs to send the interrupt request of the interrupt source to the pre-dispatch unit, it does not directly pass out the external hardware interrupt signal, but instead generates the output by the internal state machine after comprehensive processing of multiple input sources.
[0073] Specifically, the internal state machine continuously monitors external hardware interrupt input signals. Simultaneously, the internal state machine reads the configuration of the type register to correctly identify the triggering mode of the interrupt signal; if the type register is configured for edge-triggered, the state machine only responds to the rising or falling edge of the signal; if configured for level-triggered, the state machine determines the triggering mode based on the valid state of the level.
[0074] The internal state machine also reads the value of the enable register. If the enable register indicates that the interrupt is disabled, the state machine will ignore all inputs and will not generate an interrupt output.
[0075] In addition, the internal state machine monitors the inject register. When software writes a trigger value to the inject register, the internal state machine treats it as a valid interrupt input, just like a hardware interrupt, and generates an interrupt request. The internal state machine also updates the status register in real time, recording the current status of the interrupt (e.g., triggered, waiting, responded to), for software querying and debugging.
[0076] Finally, the internal state machine generates a final interrupt request signal based on the comprehensive judgment result of all the above inputs (hardware interrupt, enable, inject, type, status) and sends it to the corresponding pre-dispatcher.
[0077] Because each interrupt source is equipped with an independent internal state machine and a set of control registers (enable register, inject register, type register, and status register), the control and processing logic of each interrupt is completely independent, enabling fine-grained management of interrupt sources. Through the enable register, the system can independently disable or enable any interrupt without requiring global configuration through the upper-level interrupt controller, improving the flexibility of interrupt control and facilitating power management. Through the type register, the system can adapt to the interrupt characteristics of different peripherals, supporting both level-triggered and edge-triggered interrupts, enhancing the system's versatility and compatibility. Through the inject register, convenient debugging and self-testing methods are provided for the software, simulating interrupt scenarios without relying on actual hardware events, reducing development and testing complexity. Through the status register, the software can query the exact status of each interrupt in real time, facilitating system diagnostics and synchronization operations.
[0078] The internal state machine automatically and in real-time identifies the validity of interrupts, handles software injection requests, maintains interrupt states, and ultimately decides whether to propagate the interrupt upwards based on the configuration of these registers and external input signals. Since all these processes are automatically completed by the internal state machine at the very source of the interrupt, without software intervention or transmission to the upper-level interrupt handler via the bus, this greatly reduces the burden on the upper-level interrupt controller and decreases the number of system bus interactions and bandwidth usage.
[0079] In one feasible implementation, when an interrupt request passes sequentially through each intermediate chip (including adjacent chips) along a daisy chain, the protocol conversion module of each intermediate chip includes the following functions before receiving and forwarding the interrupt request: The intermediate chip's domain isolation module obtains the current chip's operating domain and determines whether the operating domain has the authority to forward the interrupt request. If the current chip's operating domain has the authority to forward the request, the intermediate chip's protocol conversion module forwards the interrupt request to the next chip based on the path information. If the current chip's operating domain does not have the authority to forward the request, the intermediate chip's protocol conversion module terminates the forwarding of the interrupt request and reports a path permission violation interruption to the local interrupt controller through the domain isolation module.
[0080] When the interrupt request reaches the destination chip, the interrupt controller of the destination chip verifies whether the path is consistent with the preset trusted path based on the path information of the interrupt request; if they are consistent, the interrupt request is processed normally; if they are inconsistent, a path tampering interrupt is reported.
[0081] When multiple chips are connected in a daisy-chain topology, interrupt requests physically pass through each intermediate chip in the chain during transmission from the source chip to the destination chip. In traditional architectures, these intermediate chips can only passively forward interrupts and cannot perform security audits on the interrupt content, posing a security risk. A compromised low-privilege chip could become an attack springboard, intercepting, tampering with, or maliciously forwarding interrupts.
[0082] This embodiment introduces a forwarding permission verification mechanism in the protocol conversion module of each intermediate chip. When an interrupt request passes through an intermediate chip, the chip's domain isolation module determines whether the current chip's operating domain has the permission to forward the interrupt. For example, in a Trust Zone CCA architecture, a chip running in a non-secure domain should not be allowed to forward interrupt requests from the root domain; otherwise, high-security interrupts may be spied on or blocked by low-security chips. This ensures that interrupts can only be transmitted between trusted security domains.
[0083] In one feasible implementation, in the step where the domain isolation module of the intermediate chip determines whether the current chip's operating domain has the authority to forward the interrupt request, the method further includes: When the protocol conversion module of the intermediate chip receives the interrupt request, it first parses the interrupt security label carried in the interrupt request data packet. The interrupt security label includes the following information: the security domain to which the interrupt source belongs, the chip identifier that initiated the interrupt request, the original priority level of the interrupt request, and the integrity check code of the interrupt request. The domain isolation module of the intermediate chip obtains the current operating domain of the chip and reads the cross-domain forwarding policy table stored locally. This cross-domain forwarding policy table is generated based on the preset security policy configuration table during the system initialization phase and is dynamically updated by the chip in the high security domain (root domain) through the domain isolation module during runtime. The domain isolation module performs a three-level progressive permission judgment based on the security domain to which the interrupt source belongs in the interrupt security label, the current operating domain of the chip, and the rules in the cross-domain forwarding policy table: Level 1 Judgment: The domain isolation module determines whether there is a direct forwarding relationship between the current chip's operating domain and the security domain to which the interrupt source belongs. If the cross-domain forwarding policy table stipulates that direct forwarding between these two domains is prohibited, it is determined that there is no forwarding permission, forwarding is terminated, and a domain isolation violation interrupt is reported; this ensures that only inter-domain forwarding explicitly permitted by the cross-domain forwarding policy table can proceed, preventing low-security-domain chips from attempting to forward interrupts to high-security-domains, or illegal interrupt transmission between different isolation domains.
[0084] Second-level judgment: If the first-level judgment passes, the domain isolation module further judges whether the current security status of the current chip's operating domain meets the forwarding requirements. The security status includes: whether the current chip is in a security-locked mode, whether the current chip's root of trust has been verified, and whether the current chip has any unprocessed security alarms. If any security status does not meet the requirements, it is determined that there is no forwarding permission, forwarding is terminated, and a security status violation interruption of the chip is reported; even if forwarding is allowed between two domains, if the intermediate chip itself is in an insecure state (such as unverified root of trust, in a security-locked mode, or with unprocessed security alarms), its forwarding interruption should not be allowed, otherwise the chip may become an attack springboard, injecting malicious interruptions into the high-security domain.
[0085] The third level of judgment: If both the first and second levels of judgment pass, the domain isolation module further determines whether the original priority level of the interrupt request exceeds the highest priority threshold allowed for forwarding by the current chip's operating domain. This priority threshold is configured separately for the source and destination domains in the cross-domain forwarding policy table to prevent low-security-domain chips from being flooded with high-priority interrupts. If the interrupt priority exceeds the allowed threshold, it is determined that there is no forwarding permission, forwarding is terminated, and an over-priority interrupt is reported. Even if the first two levels of judgment pass, if a low-security-domain chip attempts to forward high-priority interrupts to a high-security-domain, it may cause an interrupt storm attack in the high-security-domain. Attackers can continuously send high-priority interrupts, causing the processor cores in the high-security-domain to continuously process interrupts and be unable to perform normal tasks. By limiting the priority threshold, it is ensured that low-security-domain chips can only forward interrupts with a priority not higher than the threshold, effectively preventing this type of attack.
[0086] If all three levels of judgment pass, the domain isolation module of the intermediate chip generates a forwarding authorization signal. The protocol conversion module forwards the interrupt request to the next chip according to the authorization signal and updates the interrupt security label before forwarding. The label records the chip's identifier and forwarding timestamp for the destination chip to perform path integrity verification.
[0087] This embodiment introduces an interrupt security tag into each interrupt request data packet, carrying key security attributes such as the security domain to which the interrupt source belongs, the initiating chip identifier, and the original priority, and is protected by an integrity checksum. This allows the intermediate chip to accurately determine the source and attributes of the interrupt without relying on external context information or trusting upper-layer software. The integrity checksum ensures that the tag content cannot be tampered with throughout the transmission process, preventing the intermediate chip or other attackers from forging or modifying the interrupt's security attributes.
[0088] In one feasible implementation, during the process of the corresponding protocol conversion module sending the interrupt request to the destination chip, when a fault occurs in one of the intermediate chips in the daisy-chain topology, the method further includes: The protocol conversion module of the adjacent upstream chip of the faulty chip detects that the faulty chip has continuously timed out without responding through the interrupt state machine and generates a link fault detection signal. The domain isolation module of the adjacent upstream chip determines whether the security domain to which the faulty chip belongs is allowed to be bypassed according to the preset fault handling strategy. If it is allowed, the protocol conversion module of the adjacent upstream chip sends a topology reconfiguration broadcast message through the serial communication protocol to notify all other chips on the daisy chain to update their local chip topology information table. The topology reconfiguration broadcast message carries the identifier of the bypassed faulty chip and the new path calculation rules. After receiving the message, each chip updates its local chip topology information table and marks the faulty chip as unavailable. When a subsequent interrupt request needs to pass through the bypassed faulty chip, the protocol conversion module of the source chip recalculates the transmission path according to the updated chip topology information table and sends the interrupt request directly to the downstream adjacent chip of the faulty chip, bypassing the faulty node. If the bypassed faulty chip subsequently recovers, the chip's protocol conversion module will send a topology recovery broadcast message via serial communication protocol after startup, notifying all other chips in the daisy chain to re-add the chip to the list of available nodes. During topology reconfiguration, the domain isolation module ensures that only chips with sufficient security domain privileges can initiate or respond to topology reconfiguration operations, preventing low-privilege chips from maliciously triggering topology changes.
[0089] Because of the domain isolation module, only chips in the same security domain as the faulty chip or with sufficiently high privileges can decide whether to bypass it. For example, in the Trust Zone CCA architecture, only chips in the Root domain can decide to bypass another Root domain chip; while a chip in a Non-secure domain, even if it detects that a downstream chip is unresponsive, has no right to initiate topology reconfiguration and can only report a permission violation and interruption. This improves link security.
[0090] It should be noted that the above examples are only for understanding this application and do not constitute a limitation on the distributed interrupt control method of this application. Any simple modifications based on this technical concept are within the protection scope of this application.
[0091] This application also provides a distributed interrupt system; please refer to [reference needed]. Figure 1 The distributed interruption system includes: The distributed interrupt system includes multiple chips interconnected by physical links. Each chip is equipped with an interrupt controller. The chips transmit data across chips via a serial communication protocol, and the physical links between the chips form a daisy-chain topology. Any interrupt controller is used to forward the interrupt request to the target chip via a serial communication protocol when it receives an interrupt request, based on the target chip information carried in the interrupt request.
[0092] In one embodiment, each chip is internally configured with multiple functional sub-modules, a pre-distributor and a protocol conversion module. Each functional sub-module is configured with an independent interrupt control unit. Each interrupt control unit manages an interrupt source. Each interrupt control unit is configured with a domain isolation module. Each interrupt is pre-configured with a domain attribute register. The interrupt control unit is also used to send the interrupt request of the corresponding interrupt source to the corresponding pre-distributor, determine whether the target chip is a local chip, if it is a local chip, send the interrupt request to the corresponding interrupt controller, and the corresponding interrupt controller forwards the interrupt request to the local chip; if it is not a local chip, send the interrupt request to the corresponding protocol conversion module. The protocol conversion module is used to send the interrupt request to the target chip.
[0093] In one embodiment, each interrupt control unit is configured with a domain isolation module, and each interrupt is pre-configured with a domain attribute register; Each interrupt control unit is also used to merge interrupt requests belonging to the same domain from the corresponding interrupt source into a single signal based on the domain attribute register corresponding to each interrupt, and send it to the corresponding pre-distributor.
[0094] In one embodiment, each interrupt is configured with an interrupt control register, and the domain isolation module generates a register masking signal according to the domain of each interrupt; The interrupt controller of the target chip is configured to, upon receiving the interrupt request, determine whether the operating domain of the target chip is consistent with the domain to which the interrupt request belongs, and determine whether the access permission of the operating domain is equal to or higher than the access permission of the corresponding interrupt control register; if the operating domain is consistent with the domain to which the interrupt request belongs, and the access permission of the operating domain is equal to or higher than the access permission of the interrupt control register, then access to the corresponding interrupt control register is permitted.
[0095] In one embodiment, the access permission of the register is the highest permission of the current domain mode, which is determined based on a preset domain attribute configuration table during the chip initialization phase; the current domain mode includes a Trust Zone CCA architecture and a Trust Zone architecture. The Trust Zone CCA architecture supports Root mode, Realm mode, Secure mode, or Non-secure mode, with Root mode having the highest access permission; the Trust Zone architecture supports Secure mode or Non-secure mode, with Secure mode having the highest access permission.
[0096] In one embodiment, each interrupt control unit is further configured with an internal state machine, and each interrupt is further configured with an enable register, an inject register, a type register and a status register. The enable register is used to control whether the interrupt is enabled, the inject register is used to support software injection interrupts, the type register is used to identify whether the corresponding interrupt is level-triggered or edge-triggered, and the status register is used to save the interrupt status. Any interrupt control unit is further configured to send the interrupt request of the corresponding interrupt source to the corresponding pre-distributor based on the enable register, inject register, type register and status register of the corresponding internal state machine.
[0097] In one embodiment, the protocol conversion module is configured with an interrupt state machine, which is used to control the state transitions of an interrupt; The protocol conversion module is also used to send the interrupt request to the destination chip according to the interrupt state machine.
[0098] The distributed interrupt system provided in this application, employing the distributed interrupt control method in the above embodiments, can solve the technical problems of poor data transmission scalability and low overall reliability caused by interrupt signal transmission via bus. Compared with the prior art, the beneficial effects of the distributed interrupt system provided in this application are the same as those of the distributed interrupt control method provided in the above embodiments, and other technical features of the distributed interrupt system are the same as those disclosed in the methods of the above embodiments, and will not be repeated here.
[0099] This application provides a distributed interrupt control device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the distributed interrupt control method in Embodiment 1 above.
[0100] The following is for reference. Figure 7 The diagram illustrates a structure suitable for implementing the distributed interrupt control device of the embodiments of this application. The distributed interrupt control device in the embodiments of this application may include, but is not limited to, mobile terminals such as mobile phones, tablets, laptops, digital broadcast receivers, PDAs (Personal Digital Assistants), PMPs (Portable Media Players), in-vehicle terminals (e.g., in-vehicle navigation terminals), and fixed terminals such as digital televisions and desktop computers. Figure 7 The distributed interrupt control device shown is merely an example and should not impose any limitations on the functionality and scope of use of the embodiments of this application.
[0101] like Figure 7 As shown, the distributed interrupt control device may include a processing unit 1001 (e.g., a central processing unit, a graphics processing unit, etc.) that can perform various appropriate actions and processes according to a program stored in read-only memory (ROM) 1002 or a program loaded from storage device 1003 into random access memory (RAM) 1004. The RAM 1004 also stores various programs and data required for the operation of the distributed interrupt control device. The processing unit 1001, ROM 1002, and RAM 1004 are interconnected via a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Typically, the following systems can be connected to the I / O interface 1006: input devices 1007 including, for example, touchscreens, touchpads, keyboards, mice, image sensors, microphones, accelerometers, gyroscopes, etc.; output devices 1008 including, for example, liquid crystal displays (LCDs), speakers, vibrators, etc.; storage devices 1003 including, for example, magnetic tapes, hard disks, etc.; and communication devices 1009. Communication device 1009 allows the distributed interrupt control device to communicate wirelessly or wiredly with other devices to exchange data. While the figure shows distributed interrupt control devices with various systems, it should be understood that implementation or possession of all the systems shown is not required. More or fewer systems may be implemented alternatively.
[0102] Specifically, according to the embodiments disclosed in this application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments disclosed in this application include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from storage device 1003, or installed from ROM 1002. When the computer program is executed by processing device 1001, it performs the functions defined in the methods of the embodiments disclosed in this application.
[0103] The distributed interrupt control device provided in this application, employing the distributed interrupt control method in the above embodiments, can solve the technical problems of poor data transmission scalability and low overall reliability caused by interrupt signal transmission via bus. Compared with the prior art, the beneficial effects of the distributed interrupt control device provided in this application are the same as those of the distributed interrupt control method provided in the above embodiments, and other technical features of this distributed interrupt control device are the same as those disclosed in the previous embodiment method, and will not be repeated here.
[0104] It should be understood that the various parts disclosed in this application can be implemented using hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in any suitable manner in one or more embodiments or examples.
[0105] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
[0106] This application provides a computer-readable storage medium having computer-readable program instructions (i.e., a computer program) stored thereon, the computer-readable program instructions being used to execute the distributed interrupt control method in the above embodiments.
[0107] The computer-readable storage medium provided in this application may be, for example, a USB flash drive, but is not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections having one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, system, or device. The program code contained on the computer-readable storage medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination thereof.
[0108] The aforementioned computer-readable storage medium may be included in a distributed interrupt control device; or it may exist independently and not be assembled into a distributed interrupt control device.
[0109] The aforementioned computer-readable storage medium carries one or more programs, which, when executed by a distributed interrupt control device, cause the distributed interrupt control device to execute the aforementioned distributed interrupt control method.
[0110] Computer program code for performing the operations of this application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, and C++, as well as conventional procedural programming languages such as "C" or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).
[0111] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0112] The modules described in the embodiments of this application can be implemented in software or hardware. The names of the modules do not necessarily limit the functionality of the unit itself.
[0113] The readable storage medium provided in this application is a computer-readable storage medium that stores computer-readable program instructions (i.e., a computer program) for executing the above-described distributed interrupt control method. This solves the technical problems of poor data transmission scalability and low overall reliability caused by interrupt signal transmission via a bus. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as those of the distributed interrupt control method provided in the above embodiments, and will not be repeated here.
[0114] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the distributed interrupt control method described above.
[0115] The computer program product provided in this application can solve the technical problems of poor data transmission scalability and low overall reliability caused by interrupt signal transmission via bus. Compared with the prior art, the beneficial effects of the computer program product provided in this application are the same as those of the distributed interrupt control method provided in the above embodiments, and will not be repeated here.
[0116] The above descriptions are merely some embodiments of this application and do not limit the scope of protection of this application. Any equivalent structural transformations made based on the technical concept of this application and the content of this specification and drawings, or direct / indirect applications in other related technical fields, are included within the scope of protection of this application. All actions involving the acquisition of signals, information, or data in this application are performed in accordance with the relevant data protection laws and policies of the country where the application is located and with authorization from the owner of the corresponding device.< / realm> < / root> < / secure> < / reg>
Claims
1. A distributed interrupt control method, characterized in that, The distributed interrupt control method is applied to a distributed interrupt system, which includes multiple chips interconnected by physical links. Each chip is configured with an interrupt controller, and the chips transmit data across chips via a serial communication protocol. The physical links between the chips form a daisy-chain topology. When any interrupt controller receives an interrupt request, the interrupt controller forwards the interrupt request to the target chip via a serial communication protocol based on the target chip information carried in the interrupt request. Each chip internally comprises multiple functional sub-modules, a pre-distributor, and a protocol conversion module. Each functional sub-module is equipped with an independent interrupt control unit, and each interrupt control unit manages an interrupt source. Before the step of any interrupt controller forwarding the interrupt request to the destination chip based on the destination chip information carried in the interrupt request, the method further includes: The pre-distributor receives interrupt requests sent by the interrupt control unit of the local chip or interrupt requests sent to the local chip via the serial communication protocol by the interrupt control unit of the remote chip, and determines whether the target chip is the local chip. If it is a local chip, the interrupt request is sent to the corresponding interrupt controller, and the corresponding interrupt controller forwards the interrupt request to the local chip; If it is not a local chip, the interrupt request is sent to the corresponding protocol conversion module, which then sends the interrupt request to the target chip.
2. The distributed interruption control method as described in claim 1, characterized in that, Each interrupt control unit is configured with a domain isolation module, and each interrupt is pre-configured with a domain attribute register. The steps of the pre-distributor receiving interrupt requests sent by the interrupt control unit of the local chip or interrupt requests sent to the local chip by the interrupt control unit of a remote chip through the serial communication protocol include: Each interrupt control unit, based on the domain attribute register corresponding to each interrupt, merges interrupt requests belonging to the same domain from the corresponding interrupt source into a single signal and sends it to the corresponding pre-distributor.
3. The distributed interruption control method as described in claim 2, characterized in that, Each interrupt is configured with an interrupt control register. The domain isolation module generates a register mask signal based on the domain of each interrupt. After the step of any interrupt controller forwarding the interrupt request to the destination chip via a serial communication protocol based on the destination chip information carried in the interrupt request, the method further includes: When the interrupt controller of the target chip receives the interrupt request, it responds to the interrupt request by determining whether the operating domain of the target chip is consistent with the domain to which the interrupt request belongs, and whether the access permission of the operating domain is equal to or higher than the access permission of the corresponding interrupt control register. If the running domain is the same as the domain to which the interrupt request belongs, and the access permission of the running domain is equal to or higher than the access permission of the interrupt control register, then access to the corresponding interrupt control register is permitted.
4. The distributed interruption control method as described in claim 3, characterized in that, The access permissions of the registers are the highest permissions of the current domain mode, which is determined based on a preset domain attribute configuration table during chip initialization. The current domain mode includes Trust Zone CCA architecture and Trust Zone architecture. Trust Zone CCA architecture supports Root mode, Realm mode, Secure mode, or Non-secure mode, with Root mode having the highest access permissions. Trust Zone architecture supports Secure mode or Non-secure mode, with Secure mode having the highest access permissions.
5. The distributed interruption control method as described in claim 1, characterized in that, Each interrupt control unit is also configured with an internal state machine, and each interrupt is also configured with an enable register, an inject register, a type register, and a status register. The enable register is used to control whether the interrupt is enabled, the inject register is used to support software-injected interrupts, the type register is used to identify whether the corresponding interrupt is level-triggered or edge-triggered, and the status register is used to store the interrupt status. The steps of the pre-distributor receiving interrupt requests sent by the interrupt control unit of the local chip or interrupt requests sent to the local chip by the interrupt control unit of the remote chip through the serial communication protocol include: Each interrupt control unit's internal state machine sends the interrupt request from the corresponding interrupt source to the corresponding pre-dispatch unit based on the enable register, inject register, type register, and status register.
6. The distributed interruption control method as described in claim 1, characterized in that, The protocol conversion module is configured with an interrupt state machine, which is used to control the state transitions of interrupts. The step of the corresponding protocol conversion module sending the interrupt request to the target chip includes: The corresponding protocol conversion module sends the interrupt request to the destination chip according to the interrupt state machine, wherein the interrupt state machine includes at least one of the following: idle state, waiting to be sent state, sent state, and cleared state.
7. A distributed interrupt system, characterized in that, The distributed interrupt system includes multiple chips interconnected by physical links. Each chip is equipped with an interrupt controller. The chips transmit data across chips via a serial communication protocol. The physical links between the chips form a daisy-chain topology. Any interrupt controller is used to forward the interrupt request to the target chip via a serial communication protocol when it receives an interrupt request, based on the target chip information carried in the interrupt request. Each chip is internally configured with multiple functional sub-modules, a pre-distributor, and a protocol conversion module. Each functional sub-module is configured with an independent interrupt control unit, and each interrupt control unit manages an interrupt source. The interrupt control unit is further configured to determine whether the target chip is a local chip. If it is a local chip, the interrupt request is sent to the corresponding interrupt controller, which forwards the interrupt request to the local chip. If it is not a local chip, the interrupt request is sent to the corresponding protocol conversion module, which sends the interrupt request to the target chip.
8. The distributed interrupt system as described in claim 7, characterized in that, Each interrupt control unit is equipped with a domain isolation module, and each interrupt is pre-configured with a domain attribute register; The interrupt control unit is also used to send the interrupt request of the corresponding interrupt source to the corresponding pre-distributor.
9. A distributed interrupt control device, characterized in that, The distributed interrupt control device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, the computer program being configured to implement the steps of the distributed interrupt control method as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Chain type multi-chip system and communication method
CN115576889A
Serial interrupt bus protocol
CN1157046A
