Embedded Systems
By designing AXI2AHB protocol conversion logic and address mapping logic in an embedded system, the integration of the AXI protocol kernel and AHB protocol memory is achieved, solving the problem of low memory access efficiency, improving system performance and responsiveness, and improving functional security sex.
Patent Information
- Application Number
- CN202411040170.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2044-07-31
AI Technical Summary
The prior art is difficult to achieve smooth integration of the AXI protocol core and the AHB protocol memory, resulting in inefficient memory access.
Design an embedded system, including a kernel, memory module and a bus bridge. The bus bridge has built-in AXI2AHB protocol conversion logic, and converts the address of the AXI protocol into AHB protocol through physical address mapping logic and virtual address mapping logic to realize the kernel and AHB protocol. Memory integration, and ECC verification code generation and inspection logic are set in the bus bridge to ensure the correctness of data transmission.
It realizes smooth integration of the AXI protocol kernel and AHB protocol memory, improves the response speed of the kernel access memory, reduces frequent rewritten operations of Flash, enhances system performance and responsiveness, and improves functional security.
Smart Images

Figure CN118568035B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of integrated circuits, and in particular to an embedded system. Background Art
[0002] In advanced embedded systems, the core is usually equipped with a bus interface that supports the AXI (Advanced eXtensibleInterface) protocol (abbreviated as AXI bus interface) to support high-performance, high-bandwidth and low-latency memory access. However, not all current memories are equipped with AXI bus interfaces, and many memories currently rely on the AHB (Advanced High-performance Bus) protocol. Therefore, a conversion module is needed to convert the AXI protocol to the AHB protocol, so that the AXI protocol core and the AHB protocol memory can be smoothly integrated. Summary of the invention
[0003] The object of the present invention is to provide an embedded system capable of realizing smooth integration of a kernel of an AXI protocol and a memory of an AHB protocol.
[0004] To achieve the above object, the present invention provides the following technical solutions:
[0005] The invention provides an embedded system, which comprises a kernel, a memory module and a bus bridge. The kernel has an AXI bus interface, the memory module has an AHB bus matrix, two ends of the bus bridge are respectively connected to the AXI bus interface and the AHB bus matrix, and an AXI2AHB protocol conversion logic is provided inside the bus bridge to realize conversion from the AXI protocol to the AHB protocol.
[0006] In one embodiment, the memory module includes Flash and SRAM, the Flash is used to store system calibration parameters, and the AXI2AHB protocol conversion logic also includes a physical address mapping logic, and the physical address mapping logic is used to map access to the Flash to the SRAM.
[0007] In one embodiment, the physical address mapping logic includes: the embedded system is configured with a physical address mapping source area starting address, a physical address mapping target area starting address and a physical address mapping range mask; the physical address mapping range mask is the physical address mapping address range of the physical address mapping logic, its high bits are all ones, its low bits are all zeros, and the high bits are the address bits that need to be compared in the physical address mapping logic; when the high bit of the AXI effective address signal entering and exiting the AXI bus interface is equal to the high bit of the starting address of the physical address mapping source area, the physical address mapping match signal is output as high, and a physical mapping address signal is formed, the high bit of the physical address mapping address signal is the high bit of the starting address of the physical address mapping target area, and the low bit of the physical mapping address signal is the low bit of the AXI effective address signal; in other cases, the physical address mapping match signal is output as low.
[0008] In one embodiment, the AXI2AHB protocol conversion logic further includes a virtual address mapping logic, which is used to map access to a virtual address to the SRAM, and the virtual address mapping logic includes: the embedded system is configured with a virtual address mapping target area start address and a virtual address mapping range mask, and the virtual address mapping source area start address is a fixed value; the virtual address mapping range mask is a virtual mapping address range of the virtual address mapping logic, and its high and low bits are all zero, the middle bit is configurable, and the high and middle bits are address bits that need to be compared in the virtual address mapping logic; when the AXI bus interface enters and exits If the high bit of the XI effective address signal is equal to the high bit of the starting address of the source area of the virtual address mapping and the median bit of the AXI effective address signal is less than the median bit of the virtual address mapping range mask, the virtual address mapping match signal is output as high, and a virtual mapping address signal is formed, the high bit of the virtual mapping address signal is the high bit of the starting address of the target area of the virtual address mapping, the median bit of the virtual mapping address signal is the median bit of the AXI effective address signal plus the median bit of the starting address of the target area of the virtual address mapping, and the low bit of the virtual mapping address signal is the low bit of the AXI effective address signal; in other cases, the virtual address mapping match signal is output as low.
[0009] In one embodiment, the AXI2AHB protocol conversion logic also includes: the embedded system is also configured with a physical address mapping enable signal, a virtual address mapping enable signal, a first AND gate, a second AND gate, a first selector, and a second selector, the physical address mapping match signal and the physical address mapping enable signal are respectively input to the two input ends of the first AND gate, the output end of the first AND gate is connected to the selection end of the first selector, the virtual address mapping match signal and the virtual address mapping enable signal are respectively input to the two input ends of the second AND gate, the output end of the second AND gate is connected to the selection end of the second selector, the AXI effective address signal is input to the zeroth input end of the first selector, the physical mapping address signal is input to the first input end of the first selector, the output end of the first selector is connected to the zeroth input end of the second selector, the virtual mapping address signal is input to the first input end of the second selector, and the output of the second selector is used as the AHB address signal entering and exiting the AHB bus matrix.
[0010] In one embodiment, the bus bridge further includes an AXI bus port, an AHB bus port, a register group, and a PPB bus port. The AXI bus port is used to interface with the AXI bus interface, the AHB bus port is used to interface with the AHB bus matrix, the register group is used to store data required by the AXI2AHB protocol conversion logic, the AXI bus port, the AHB bus port, and the register group are all connected to the AXI2AHB protocol conversion logic, and the PPB bus port is connected to the register group for configuring data to the register group.
[0011] In one embodiment, the bus bridge also includes address remapping rule checking logic and an interrupt signal port. The address remapping rule checking logic is connected to the interrupt signal port and the register group. The physical address mapping logic and the virtual address mapping logic are collectively referred to as address remapping logic. The address remapping rule checking logic checks the address remapping logic and triggers an interrupt event through the interrupt signal port if illegal address remapping logic is found.
[0012] In one implementation, the address remapping rule checking logic checks the address remapping logic and determines the address remapping logic as illegal if the following conditions are found:
[0013] a) The configured remapping address range is illegal;
[0014] b) The configured source region contains an illegal address in the memory space;
[0015] c) The configured target area contains illegal addresses in the memory space;
[0016] d) The configured source address fails to align with the configured remap address range;
[0017] e) The configured target address fails to align with the configured remap address range;
[0018] f) Multiple configured source areas overlap;
[0019] g) Multiple configured target areas overlap;
[0020] h) The configured source area is not Flash;
[0021] i) There is an address overflow in the configured target area.
[0022] In one embodiment, the bus bridge further includes an ECC check code generation and checking logic connected to the AHB bus port, and performs ECC encoding and checking on the data transmission of the AHB bus port; the ECC check code generation and checking logic includes ECC generation logic, ECC checking logic, an error output port, and an error injection port. The ECC generation logic is connected to both the AHB bus port and the AHB bus matrix, generates an ECC check code according to the write data from the AHB bus port to the AHB bus matrix, and sends the ECC check code to the AHB bus matrix after merging with the write data; the ECC check logic is connected to both the AHB bus port and the AHB bus matrix, and performs checking on the read data containing the ECC check code obtained from the AHB bus matrix by the AHB bus port. If an error is detected in the data transmission, the error is transmitted to the corresponding functional safety module through the error output port for error processing; the error injection port is connected to the ECC generation logic, and flips the specified bit of the input signal of the ECC generation logic to test the functional correctness of the ECC check code generation and checking logic.
[0023] In one embodiment, the AXI2AHB protocol conversion logic has two identical groups, which are designed to be redundant with each other, one group is used as the main group, and the other group is used for synchronous monitoring. The input signals of the two are the same, and address conversion processing is performed independently. The output AHB address signal is compared. If the result does not match, the error information is passed to the corresponding functional safety module for error handling.
[0024] Compared with the prior art, the technical solution of the present invention has the following beneficial effects:
[0025] The embedded system of the present invention is provided with a bus bridge, and the bus bridge is provided with AXI2AHB protocol conversion logic for converting the AXI protocol and the AHB protocol, thereby realizing smooth integration of the kernel of the AXI protocol and the memory of the AHB protocol. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.
[0027] Figure 1 A schematic diagram of the structure of an embedded system provided by the first embodiment of the present invention;
[0028] Figure 2 for Figure 1 The structural diagram of the bus bridge shown in;
[0029] Figure 3 for Figure 2 Schematic diagram of the physical address mapping logic (part of the address remapping logic) in the bus bridge shown in;
[0030] Figure 4 for Figure 2 Schematic diagram of the virtual address mapping logic (another part of the address remapping logic) in the bus bridge shown in;
[0031] Figure 5 for Figure 2 Partial schematic diagram of AXI2AHB protocol conversion logic in the bus bridge shown in;
[0032] Figure 6 for Figure 2 Schematic diagram of ECC check code generation and checking logic in the bus bridge shown in . DETAILED DESCRIPTION
[0033] The technical solutions in the embodiments of the present invention will be described clearly and completely below. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by those skilled in the art without creative work belong to the scope of protection of the present invention. It should be noted that the description order of the following embodiments is not used as a limitation on the preferred order of the embodiments of the present invention. In the following embodiments, the description of each embodiment has its own emphasis. For the parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.
[0034] See also Figure 1As shown, the first embodiment of the present invention provides an embedded system, which includes a kernel, a memory module and a bus bridge. The kernel has an AXI bus interface, the memory module has an AHB bus matrix, the two ends of the bus bridge are respectively connected to the AXI bus interface and the AHB bus matrix, and an AXI2AHB protocol conversion logic is provided inside to realize the conversion from the AXI protocol to the AHB protocol.
[0035] The embedded system of the present invention is provided with a bus bridge, and the bus bridge is provided with AXI2AHB protocol conversion logic for converting the AXI protocol and the AHB protocol, thereby realizing smooth integration of the kernel of the AXI protocol and the memory of the AHB protocol.
[0036] Please refer to Figure 1 , Figure 2 As shown, in one embodiment, the memory module includes Flash and SRAM, the Flash is used to store system calibration parameters, and the AXI2AHB protocol conversion logic also includes a physical address mapping logic (not shown, the physical address mapping logic and the virtual address mapping logic to be described later are collectively referred to as Figure 2 The address remapping logic shown in ), the physical address mapping logic is used to map accesses directed to the Flash to the SRAM.
[0037] Of course, the memory module may also include ROM. In the development of ECU (automotive electronic control unit), parameter calibration is a key step that can be used to optimize the performance of the engine and the whole vehicle. The calibrated parameters are usually stored in the Flash memory. However, one of the characteristics of Flash is that it does not support byte-by-byte erasure, which means that once any parameter needs to be modified, the content of the entire Sector needs to be erased and rewritten, including all other parameters that do not need to be modified. If this operation is done directly, a large amount of unnecessary data rewriting and possible performance degradation will result. In order to overcome this shortcoming, the present invention sets a physical address mapping logic to map the access to the Flash to the SRAM. In this way, the system will first read and copy all the calibration parameters stored in the Flash to the SRAM, and then perform address remapping so that the address originally pointing to the parameters in the Flash now points to the corresponding position in the SRAM, so that these parameters can be modified directly in the SRAM to achieve online tuning without frequent erasing and writing operations on the Flash. When all parameter modifications are completed, the updated parameters are burned back to the Flash for system use. The present invention realizes flexible access and modification of data in the Flash and SRAM.
[0038] In addition, the physical address mapping logic can also be set outside the bus bridge, specifically in front of or behind the AHB bus matrix or in the storage controller of the memory module, but this will increase the memory access path, affect performance, and increase power consumption. The physical address mapping logic of the present invention is set in the bus bridge and directly combined with the AXI2AHB protocol conversion logic, which can significantly improve the response speed of the kernel accessing the memory, thereby enhancing the performance and responsiveness of the entire embedded system, and to a certain extent, suppressing the growth of power consumption.
[0039] See also Figure 3 As shown, in one embodiment, the physical address mapping logic includes: the embedded system is configured with a physical address mapping source area starting address, a physical address mapping target area starting address and a physical address mapping range mask; the physical address mapping range mask is the physical address mapping address range of the physical address mapping logic, the high bits of which are all one, the low bits are all zero, and the high bits are the address bits that need to be compared in the physical address mapping logic; when the high bits of the AXI effective address signal coming in and out of the AXI bus interface are equal to the high bits of the starting address of the physical address mapping source area, the physical address mapping match signal is output as high, and a physical mapping address signal is formed, the high bits of the physical mapping address signal are the high bits of the starting address of the physical address mapping target area, and the low bits of the physical mapping address signal are the low bits of the AXI effective address signal; in other cases, the physical address mapping match signal is output as low. Wherein, the AXI effective address signal includes an AXI effective write address signal and an AXI effective read address signal.
[0040] See also Figure 4 As shown, in one embodiment, in order to facilitate memory management, the AXI2AHB protocol conversion logic also includes a virtual address mapping logic (not shown, the virtual address mapping logic and the physical address mapping logic described above are collectively referred to as Figure 2The address remapping logic shown in the figure), the virtual address mapping logic is used to map the access pointing to the virtual address to the SRAM, the virtual address mapping logic includes: the embedded system is configured with the starting address of the virtual address mapping target area and the virtual address mapping range mask, the starting address of the virtual address mapping source area is a fixed value; the virtual address mapping range mask is the virtual mapping address range of the virtual address mapping logic, the high and low bits of which are all zero, the middle bits are configurable, the high and middle bits are the address bits that need to be compared in the virtual address mapping logic; when the high bits of the AXI effective address signals entering and exiting the AXI bus interface are If the high bit of the starting address of the source area of the virtual address mapping and the median bit of the AXI effective address signal is less than the median bit of the virtual address mapping range mask, the virtual address mapping match signal is output as high, and a virtual mapping address signal is formed, the high bit of the virtual mapping address signal is the high bit of the starting address of the target area of the virtual address mapping, the median bit of the virtual mapping address signal is the median bit of the AXI effective address signal plus the median bit of the starting address of the target area of the virtual address mapping, and the low bit of the virtual mapping address signal is the low bit of the AXI effective address signal; if it is other cases, the virtual address mapping match signal is output as low.
[0041] See also Figure 5 As shown, in one embodiment, the AXI2AHB protocol conversion logic also includes: the embedded system is also configured with a physical address mapping enable signal, a virtual address mapping enable signal, a first AND gate, a second AND gate, a first selector, and a second selector, the physical address mapping match signal and the physical address mapping enable signal are respectively input to the two input ends of the first AND gate, the output end of the first AND gate is connected to the selection end of the first selector, the virtual address mapping match signal and the virtual address mapping enable signal are respectively input to the two input ends of the second AND gate, the output end of the second AND gate is connected to the selection end of the second selector, the AXI effective address signal is input to the zeroth input end of the first selector, the physical mapping address signal is input to the first input end of the first selector, the output end of the first selector is connected to the zeroth input end of the second selector, the virtual mapping address signal is input to the first input end of the second selector, and the output of the second selector is used as the AHB address signal entering and exiting the AHB bus matrix.
[0042] Because not all addresses of the Flash in the system need to be remapped, the physical address mapping match signal and the physical address mapping enable signal are used to judge and distinguish. When both are high, it means that the physical address remapping is performed at this time, and the physical mapping address signal is output. Otherwise, the address remapping is not performed, and the AXI effective address signal is output. Similarly, the virtual address mapping match signal and the virtual address mapping enable signal are used to judge and distinguish. When both are high, it means that the virtual address remapping is performed at this time, and the virtual mapping address signal is output. Otherwise, the virtual address remapping is not performed, and the AXI effective address signal (or physical mapping address signal) is output. Moreover, the physical address mapping logic is judged at the previous level and the virtual address mapping logic is judged at the next level because the priority of the virtual address mapping logic is higher than that of the physical address mapping logic. Of course, as needed, the priority of the physical address mapping logic can also be higher than that of the virtual address mapping logic. Moreover, the physical address mapping logic can include multiple areas, and each area is judged and distinguished according to the above-mentioned physical address mapping match signal and the physical address mapping enable signal, and the priority order is set according to the above-mentioned priority order.
[0043] Please refer back to Figure 2 As shown, in one embodiment, the bus bridge further includes an AXI bus port, an AHB bus port, a register group, and a PPB (Private Peripheral Bus) bus port. The AXI bus port is used to interface with the AXI bus interface, the AHB bus port is used to interface with the AHB bus matrix, and the register group is used to store data required by the AXI2AHB protocol conversion logic. The AXI bus port, the AHB bus port, and the register group are all connected to the AXI2AHB protocol conversion logic, and the PPB bus port is connected to the register group to configure data to the register group. Specifically, the register group also stores the data required by the physical address mapping logic and the virtual address mapping logic, and also stores the data required by the address remapping rule checking logic to be described later.
[0044] Please continue reading Figure 2 As shown, in one embodiment, the bus bridge also includes an address remapping rule checking logic and an interrupt signal port. The address remapping rule checking logic is connected to the interrupt signal port and the register group. The physical address mapping logic and the virtual address mapping logic are collectively referred to as address remapping logic. The address remapping rule checking logic checks the address remapping logic, and triggers an interrupt event through the interrupt signal port if illegal address remapping logic is found.
[0045] Specifically, in one implementation, the address remapping rule checking logic checks the address remapping logic and determines the address remapping logic as illegal if the following conditions are found:
[0046] a) The configured remapping address range is illegal;
[0047] b) The configured source region contains an illegal address in the memory space;
[0048] c) The configured target area contains illegal addresses in the memory space;
[0049] d) The configured source address fails to align with the configured remap address range;
[0050] e) The configured target address fails to align with the configured remap address range;
[0051] f) Multiple configured source areas overlap;
[0052] g) Multiple configured target areas overlap;
[0053] h) The configured source area is not Flash;
[0054] i) There is an address overflow in the configured target area.
[0055] The address remapping logic described herein includes the physical address mapping logic and the virtual address mapping logic. For example, the configured remapping address range is illegal, including an illegal physical mapping address range or an illegal virtual mapping address range, such as a physical mapping address range or a virtual mapping address range that is not an integer multiple of the minimum configurable address range, or exceeds the maximum configurable address range.
[0056] Please refer to Figure 2 , Figure 6As shown, in one embodiment, the bus bridge further includes an ECC (Error Correction Code) check code generation and checking logic connected to the AHB bus port, and performs ECC encoding and checking on the data transmission of the AHB bus port; the ECC check code generation and checking logic includes ECC generation logic, ECC checking logic, error output port, and error injection port. The ECC generation logic is connected to both the AHB bus port and the AHB bus matrix, generates an ECC check code according to the write data from the AHB bus port to the AHB bus matrix, and sends the ECC check code to the AHB bus matrix after merging with the write data; the ECC check logic is connected to both the AHB bus port and the AHB bus matrix, and checks the read data containing the ECC check code obtained from the AHB bus matrix by the AHB bus port. If an error is detected in the data transmission, the error is transmitted to the corresponding functional safety module through the error output port for error processing; the error injection port is connected to the ECC generation logic, and flips the specified bit of the input signal of the ECC generation logic to test the functional correctness of the ECC check code generation and checking logic.
[0057] The write data includes a combined signal of an AHB address signal, a write data signal, and a transmission attribute (including a write signal, a transmission size signal, a burst type signal, and a protection control signal, etc.). The write data and the ECC check code are sent to the AHB bus matrix together and then stored in the memory. The read data of the ECC check code includes an AHB address signal, a read data signal, an ECC check code, and a combined signal of a transmission attribute. The types of errors detected in data transmission include address errors, data errors, and transmission attribute errors. Regardless of the type, they are transmitted to the corresponding functional safety module through the error output port for error processing. In this way, the functional safety of AHB transmission (between the AHB bus port and the AHB bus matrix) is improved.
[0058] Finally, in one embodiment, the AXI2AHB protocol conversion logic has two identical groups, which are designed to be redundant with each other, one group is used as the main group, and the other group is used for synchronization monitoring. The input signals of the two groups are the same, and the address conversion processing is performed independently, and the output AHB address signal is compared. If the result does not match, the error information is transmitted to the corresponding functional safety module for error processing. In this way, the functional safety of the entire system can be improved.
[0059] Compared with the prior art, the technical solution of the present invention has the following beneficial effects:
[0060] The embedded system of the present invention is provided with a bus bridge, and the bus bridge is provided with an AXI2AHB protocol conversion logic to convert the AXI protocol and the AHB protocol, thereby realizing the smooth integration of the kernel of the AXI protocol and the memory of the AHB protocol. Moreover, the AXI2AHB protocol conversion logic is provided with a physical address mapping logic setting, which maps the address pointing to the Flash to the SRAM, and can directly modify the calibrated parameters in the SRAM to realize online tuning, without the need to perform frequent erase and write operations on the Flash, and can significantly improve the response speed of the kernel accessing the memory, thereby enhancing the performance and responsiveness of the entire embedded system, and to a certain extent, also suppressing the growth of power consumption.
[0061] The above is only a specific implementation of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be covered within the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims. In addition, the specification uses specific examples to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. The content of this specification should not be understood as a limitation on the present invention.
Claims
1. An embedded system, characterized in that: The embedded system comprises a kernel, a memory module and a bus bridge, wherein the kernel has an AXI bus interface, the memory module has an AHB bus matrix, the two ends of the bus bridge are respectively connected to the AXI bus interface and the AHB bus matrix, and the bus bridge has an AXI2AHB protocol conversion logic inside to realize the conversion from the AXI protocol to the AHB protocol; The memory module includes Flash and SRAM, the Flash is used to store system calibration parameters, the AXI2AHB protocol conversion logic also includes a physical address mapping logic, and the physical address mapping logic is used to map access to the Flash to the SRAM; The physical address mapping logic includes: the embedded system is configured with a physical address mapping source area starting address, a physical address mapping target area starting address and a physical address mapping range mask; the physical address mapping range mask is the physical address mapping address range of the physical address mapping logic, the high bits of which are all ones, the low bits of which are all zeros, and the high bits are the address bits that need to be compared in the physical address mapping logic; when the high bits of the AXI effective address signal entering and exiting the AXI bus interface are equal to the high bits of the starting address of the physical address mapping source area, the physical address mapping match signal is output as high, and a physical mapping address signal is formed, the high bits of the physical address mapping address signal are the high bits of the starting address of the physical address mapping target area, and the low bits of the physical mapping address signal are the low bits of the AXI effective address signal; in other cases, the physical address mapping match signal is output as low; The AXI2AHB protocol conversion logic also includes a virtual address mapping logic, which is used to map the access to the virtual address to the SRAM, and the virtual address mapping logic includes: the embedded system is configured with a virtual address mapping target area start address and a virtual address mapping range mask, and the virtual address mapping source area start address is a fixed value; the virtual address mapping range mask is a virtual mapping address range of the virtual address mapping logic, and its high and low bits are all zero, and the middle bit is configurable, and the high and middle bits are address bits that need to be compared in the virtual address mapping logic; when the AXI valid AXI in and out of the AXI bus interface is If the high bit of the address signal is equal to the high bit of the starting address of the source area of the virtual address mapping and the median bit of the AXI effective address signal is less than the median bit of the virtual address mapping range mask, the virtual address mapping match signal is output as high, and a virtual mapping address signal is formed, the high bit of the virtual mapping address signal is the high bit of the starting address of the target area of the virtual address mapping, the median bit of the virtual mapping address signal is the median bit of the AXI effective address signal plus the median bit of the starting address of the target area of the virtual address mapping, and the low bit of the virtual mapping address signal is the low bit of the AXI effective address signal; in other cases, the virtual address mapping match signal is output as low.
2. The embedded system according to claim 1, characterized in that: The AXI2AHB protocol conversion logic also includes: the embedded system is also configured with a physical address mapping enable signal, a virtual address mapping enable signal, a first AND gate, a second AND gate, a first selector, and a second selector, the physical address mapping match signal and the physical address mapping enable signal are respectively input to the two input ends of the first AND gate, the output end of the first AND gate is connected to the selection end of the first selector, the virtual address mapping match signal and the virtual address mapping enable signal are respectively input to the two input ends of the second AND gate, the output end of the second AND gate is connected to the selection end of the second selector, the AXI effective address signal is input to the zeroth input end of the first selector, the physical mapping address signal is input to the first input end of the first selector, the output end of the first selector is connected to the zeroth input end of the second selector, the virtual mapping address signal is input to the first input end of the second selector, and the output of the second selector is used as the AHB address signal entering and exiting the AHB bus matrix.
3. The embedded system according to claim 2, characterized in that: The bus bridge also includes an AXI bus port, an AHB bus port, a register group, and a PPB bus port. The AXI bus port is used to connect to the AXI bus interface, the AHB bus port is used to connect to the AHB bus matrix, the register group is used to store data required by the AXI2AHB protocol conversion logic, the AXI bus port, the AHB bus port, and the register group are all connected to the AXI2AHB protocol conversion logic, and the PPB bus port is connected to the register group for configuring data to the register group.
4. The embedded system according to claim 3, characterized in that: The bus bridge also includes address remapping rule checking logic and an interrupt signal port. The address remapping rule checking logic is connected to the interrupt signal port and the register group. The physical address mapping logic and the virtual address mapping logic are collectively referred to as address remapping logic. The address remapping rule checking logic checks the address remapping logic and triggers an interrupt event through the interrupt signal port if illegal address remapping logic is found.
5. The embedded system according to claim 4, characterized in that: The address remapping rule checking logic checks the address remapping logic and determines the address remapping logic as illegal if the following conditions are found: a) The configured remapping address range is illegal; b) The configured source region contains an illegal address of the memory space; c) the configured target area contains an illegal address of the memory space; d) The configured source address fails to align with the configured remap address range; e) The configured target address fails to align with the configured remap address range; f) There is overlap between the configured multiple source areas; g) There is overlap between the configured multiple target areas; h) The configured source area is not Flash; i) There is an address overflow in the configured target area.
6. The embedded system according to claim 3, characterized in that: The bus bridge also includes an ECC check code generation and checking logic connected to the AHB bus port, which performs ECC encoding and checking on the data transmission of the AHB bus port; the ECC check code generation and checking logic includes ECC generation logic, ECC checking logic, error output port, and error injection port. The ECC generation logic is connected to the AHB bus port and the AHB bus matrix, generates ECC check code according to the write data of the AHB bus port to the AHB bus matrix, and sends it to the AHB bus matrix after merging with the write data; the ECC check logic is connected to the AHB bus port and the AHB bus matrix, and checks the read data containing the ECC check code obtained from the AHB bus matrix by the AHB bus port. If the data transmission is detected to be erroneous, it is transmitted to the corresponding functional safety module through the error output port for error processing; the error injection port is connected to the ECC generation logic, and flips the specified bit of the input signal of the ECC generation logic to test the functional correctness of the ECC check code generation and checking logic.
7. The embedded system according to claim 1, characterized in that: The AXI2AHB protocol conversion logic has two identical groups, which are designed to be redundant with each other. One group is used as the main one and the other is used for synchronous monitoring. The input signals of the two groups are the same, and address conversion processing is performed independently. The output AHB address signal is compared. If the result does not match, the error information is passed to the corresponding functional safety module for error handling.
