A fully symmetrical PCIe Switch routing configuration method and device
The PCIe Switch port attributes are configured through software to achieve automatic route mapping, which solves the problem of PCIe Switch being unable to adapt to different topologies in traditional technology, improves the flexibility and delay consistency of the device on the single board, and reduces implementation complexity.
Patent Information
- Application Number
- CN202410330198.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-21
- Publication Date
- 2024-10-22
- Estimated Expiration
- 2044-03-21
AI Technical Summary
Traditional PCIe Switch cannot realize automatic routing configuration, which limits the flexibility of the location of CPU and SSD disks on the board, and cannot be applied to PCIe topologies of different product forms.
Through the software to receive and broadcast routing configuration information, configure the attributes of each port of the PCIe Switch, including uplink and downlink ports, to achieve flexible mapping of port attributes and packet forwarding. It adopts a full-switch symmetric structure to ensure consistent delay of each port.
It achieves consistent delay between PCIe Switch ports, reduces implementation complexity, allows CPU and SSD disks to be flexibly placed on a single board, and improves the convenience and applicability of board-level design.
Smart Images

Figure CN118041776B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of switching equipment, and in particular relates to a fully symmetrical PCIe Switch routing configuration method and device. Background Art
[0002] PCIe Switch is an expansion device in the PCIe topology. It is widely used in board devices of large storage systems or server platforms. It is used to expand the number of PCIe channels (lanes) and complete data exchange between PCIe channels, thereby enhancing the expansion capability of the PCIe device of the main CPU. The popularity of NVMe SSD and the growth of storage capacity continue to promote the demand for PCIe Switch in storage applications, and also derive various product forms. For different product forms, the layout of network cards, SSD disks and CPUs on the product board may be different. If the upstream port or downstream port of the PCIe Switch chip itself is fixed, it will limit the position of the CPU and SSD disk on the single board, which is not friendly to board-level design.
[0003] In addition, the PCIe Switch in traditional technology cannot achieve automatic routing and needs to obtain the topology structure. For example, Chinese patent application CN116319586A discloses a general network device forwarding system and method based on software forwarding, which is applied to network switching and configures the switching plane. It requires software to manage the complex mapping relationship between the ingress link and the egress link, and is not suitable for the topology structure of PCIe. Chinese patent CN104601475B discloses a method for message forwarding based on router ports, which is applied to the controller in the software-defined network SDN. It is necessary to obtain the topological path of the switch according to the network IP address in order to find the egress port.
[0004] In view of this, a technical solution is needed to arbitrarily configure each port and its attributes of the PCIe Switch through software to improve the applicability of the PCIe Switch. Summary of the invention
[0005] The object of the present invention is to provide a fully symmetrical PCIe Switch routing configuration method and device, aiming to configure the properties of each port of the PCIe Switch through software to enrich the applicability of the PCIe Switch.
[0006] According to a first aspect of the present invention, a fully symmetric PCIe Switch routing configuration method is provided, comprising:
[0007] Receive the routing configuration information of the PCIe Switch from the software, and broadcast the routing configuration information to the routing table entry of each port in the PCIe Switch, wherein the routing configuration information includes port attributes and a mapping relationship between each port and a device identifier, and the port attributes include an upstream port or a downstream port;
[0008] When a host or endpoint device sends a message to the PCIe Switch, the message is parsed at the inbound port to obtain the destination device identifier of the message, and the outbound port corresponding to the destination device identifier is determined through the mapping relationship of the routing table entry to send the message to the outbound port.
[0009] Preferably, the receiving software's routing configuration information for the PCIe Switch further includes:
[0010] The CPU in the PCIe Switch chip is called by software, and the routing configuration information is written into the routing configuration table in the chip through the CPU.
[0011] Preferably, when the port attribute is 1, the port is configured as an uplink port, and when the port attribute is 0, the port is configured as a downlink port.
[0012] Preferably, parsing the message at the inbound port to obtain the destination device identifier of the message further includes:
[0013] If the message is sent by the host, it is determined to be a downlink routing path, a routing table entry is queried in the downlink routing module of the ingress port, and an egress indication tag is generated according to the matched destination device identifier.
[0014] Preferably, parsing the message at the inbound port to obtain the destination device identifier of the message further includes:
[0015] If the message is sent by an endpoint device, it is determined to be an uplink routing path, a routing table entry is queried in the uplink routing module of the ingress port, and an egress indication tag is generated according to a matched destination device identifier.
[0016] According to a second aspect of the present invention, a fully symmetrical PCIe Switch routing configuration device is provided, comprising:
[0017] A routing configuration unit, configured to receive routing configuration information of the PCIe Switch from software, and broadcast the routing configuration information to routing table entries of each port in the PCIe Switch, wherein the routing configuration information includes port attributes and a mapping relationship between each port and a device identifier, wherein the port attributes include an uplink port or a downlink port;
[0018] The message transmission unit is used to parse the message at the input port when the host or endpoint device sends a message to the PCIe Switch to obtain the destination device identifier of the message, determine the output port corresponding to the destination device identifier through the mapping relationship of the routing table entry, and send the message to the output port.
[0019] Compared with the related art, the technical solution of the present invention has the following advantages:
[0020] The ports of PCIe Switch adopt a fully symmetrical structure, which makes the delay between each port the same and imperceptible to users. Each port adopts a set of logic implementation, and only software needs to define the function, which reduces the complexity of implementation. The port attributes can be flexibly configured through software, so that devices such as CPU and SSD can be flexibly placed on a single board, making board-level design more convenient.
[0021] Other features and advantages of the present invention will be described in the following description, and partly become apparent from the description, or be understood by practicing the present invention. The purpose and other advantages of the present invention can be realized and obtained by the structures and processes indicated in the description, claims and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or related technologies, the drawings required for use in the embodiments or related technical descriptions are briefly introduced below. It is obvious that the drawings described below are certain embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0023] Figure 1 It is a flow chart of a fully symmetrical PCIe Switch routing configuration method according to the present invention.
[0024] Figure 2 This is a PCIe Switch downstream routing diagram according to an embodiment of the present invention.
[0025] Figure 3 This is a PCIe Switch uplink routing diagram according to an embodiment of the present invention.
[0026] Figure 4 It is a specific processing flow chart of the cfg configuration message according to an embodiment of the present invention. DETAILED DESCRIPTION
[0027] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0028] Based on the above analysis, the present invention proposes a fully symmetrical PCIe Switch routing configuration method and device, which uses a flexible configuration method to arbitrarily configure the properties of each port of the PCIe Switch through software, so as to achieve the purpose of flexible placement of the CPU and SSD on the product board and enrich the applicability of the PCIe Switch. At the same time, under different software configurations, there is no difference in performance and latency between the ports, so that users do not need to perceive the port differences. The software can configure the upstream port UP / downstream port DP properties of the port, configure the device identifier device_id of each DP port, and the enumeration order can be changed; all ports form an upstream routing or downstream routing path through the UP / DP properties configured by the software.
[0029] The PCIe Switch chip is usually configured with an uplink port UP and multiple downlink ports DP, which are connected to the host and the endpoint device (EP) respectively. The present invention first defines a software configuration item up_sel, which is called a port attribute configuration item. When up_sel is 1, it means that the current physical port is UP and is connected to the host. When up_sel is 0, it means that the current physical port is DP and is connected to the EP device.
[0030] Then define the software configuration item device_id, called the device identifier, which can range from 0 to 31 and is used to distinguish different DP ports. Different device_ids can be configured according to product requirements. The DP behaviors under different device_ids are completely consistent and the application may not be aware of them.
[0031] At the same time, the present invention defines egr_id as a global egress port tag. Regardless of whether the message is received by the UP port or the DP port, all messages are eventually forwarded to the corresponding egress port according to the tag. For example, in a 4-port PCIe Switch, egr_id is defined as 4 bits, 1 bit for each port. When the bit corresponding to the port is 1, it means that the message needs to be routed out of this port.
[0032] According to the above definition, the following shows the routing table items of a 4-port PCIe Switch, including PCIe_switch local software configuration table items and host configuration table items. The content of the local software configuration table items is the register configured by the PCIe_switch chip software during the chip power-on startup phase, as shown in Table 1. The host configuration table items are registers configured during the enumeration process during the server system initialization phase, as shown in Table 2. The contents of these two types of registers need to be broadcast to each port, and according to the specific table content, broadcast to different routing sub-table items, including downstream ID routing table, upstream ID routing table and address routing table).
[0033] Table 1
[0034] Up_sel Device_id[4:0] port0 0 0 port1 1 0 port2 0 1 port3 0 2
[0035] Table 2
[0036]
[0037]
[0038] The contents of the host configuration table items are not limited to the memory base address mem_base_address, the memory upper limit address mem_limit_address, the secondary bus number second_bus_number, and the maximum bus number subordinate_bus_number. According to the PCIe protocol, it also includes the IO access base address io_base_address, the IO access upper limit address io_limit_address and other domain segments and routing-related table items.
[0039] See also Figure 1 The fully symmetrical PCIe Switch routing configuration method provided by the present invention includes:
[0040] Step 101: receiving routing configuration information of the PCIe Switch from the software, and broadcasting the routing configuration information to the routing table entries of each port in the PCIe Switch, wherein the routing configuration information includes port attributes and a mapping relationship between each port and a device identifier, and the port attributes include an uplink port or a downlink port.
[0041] In a specific embodiment of the present invention, a 4-port PCIe Switch is taken as an example to illustrate the entire process of downlink routing and uplink routing. Figure 2 and Figure 3The whole process of finding the outgoing port through port routing and finally sending out the PCIe Switch when the messages sent by the host and EP device ports pass through the PCIe Switch is shown respectively. In the present invention, all ports of the PCIe Switch can be configured by software and adopt the same set of logical judgment to realize full-port symmetrical routing.
[0042] Figure 2 The entire data flow of the PCIe Switch downstream routing is shown. Port1 is connected to the host as an upstream port, and port0, port2, and port3 are connected to EP0, EP1, and EP2 as downstream ports, respectively. At this point, the physical connection relationship has been determined, and the software can determine the software configuration items shown in Table 1 based on the connection relationship. The specific execution steps are as follows:
[0043] The software calls the CPU in the PCIe Switch chip to write the configuration of the routing configuration table cfg_table in the chip. The configuration values are shown in Table 1. The up_sel of port1 is configured to 1, indicating that port1 is connected to the host as a UP port, and the up_sel of the other three ports is configured to 0, indicating that port0, port2, and port3 are DP ports connected to EP devices. The device_id of port0, port2, and port3 are configured to 0, 1, and 2 respectively. The specific configuration information is determined by the product. The product in this embodiment connects EP0, EP1, and EP2 to DP ports with device_ids of 0, 1, and 2 respectively.
[0044] Next, the table entry content of cfg_table is broadcasted to the routing table entry of each port. Since in the example of the present invention, all routing decisions are processed at the inlet side of the port, the table entry content needs to be broadcasted to all ports.
[0045] Step 102: When a host or endpoint device sends a message to the PCIe Switch, the message is parsed at the ingress port to obtain a destination device identifier of the message, and an egress port corresponding to the destination device identifier is determined through a mapping relationship of the routing table entry to send the message to the egress port.
[0046] refer to Figure 2, when all ports have received the broadcast configuration information, the system can prepare to send packets. The host first sends out the cfg configuration message pkt0. The function of the configuration message is to configure the register space of UP / DP. The configuration message carries device_id. If the device_id in the message matches the device_id of a port in the aforementioned broadcast table entry, this configuration message will be sent to the port to configure the space register of the port. pkt0 performs routing processing at the entrance of port1. According to the software configuration element up_sel is 1, the direction is judged to be the downlink routing path, and the content of the routing table entry is queried.
[0047] According to the pkt0 indication device_id=0, the port0 of the matching table entry is generated by the downstream routing module, and the egress indication tag egr_id=0001 is generated.
[0048] The logic judgment module sends pkt0 to port0 according to egr_id=0001.
[0049] The host subsequently sends out ordinary packets pkt1 and pkt2. If the packet headers indicate device_id=1 and device_id=2 respectively, the above packet sending steps are repeated until pkt1 and pkt2 arrive at port2 and port3.
[0050] Figure 3 The entire data flow of the PCIe Switch upstream routing is shown. The connection relationship between the ports is similar to Figure 2 The same, that is, port1 is still connected to the host as an uplink port, and port0, port2, and port3 are connected to EP0, EP1, and EP2 as downlink ports respectively. The software configuration items are still as shown in Table 1.
[0051] Software Configuration and Figure 2 The corresponding steps are the same and will not be repeated here. The difference is that the EP0 packet issuance process specifically includes:
[0052] The message pkt1 sent by EP0 passes through port0. Because the up_sel of port0 is 0, it means that the inbound port is DP. It is determined that upstream routing is required, so the routing table content is queried.
[0053] According to the pkt1 indication device_id=1, the port2 of the matching table entry, the upstream routing module generates an egress indication tag egr_id=0100.
[0054] The logic judgment module sends pkt1 to port2 according to egr_id=0100.
[0055] The transport layer (TLP) messages of PCIe mainly include cfg configuration messages, memory access messages, cpl return messages and message messages. The routing methods mainly include ID routing (cfg configuration messages, cpl return messages) and address routing (memory access messages). Among them, cfg configuration messages only support downstream ID routing, cpl messages support upstream ID routing and downstream ID routing, and memory access messages support address routing. The following introduces the implementation process based on downstream ID routing, upstream ID routing and address routing respectively.
[0056] For downstream ID routing, the server performs system initialization, and the host scans the downstream PCIe devices and enumerates the PCIe devices (including PCIe_switch) under the PCIe tree. At this time, the host will send the cfg configuration message. As mentioned above, the configuration message is used to configure the register configuration space of UP, DP and EP. Figure 4 The specific processing flow of the cfg configuration message of the present invention is described:
[0057] Step A1: First, cfg_table broadcasts up_sel to each sub-table item of each port (downstream ID routing, upstream ID routing and address routing are 3 sub-table items), and device_id is broadcast to the downstream ID routing sub-table item of each port (only downstream ID routing needs to use device_id); the above steps are completed in the power-on initialization process of the PCIe_switch chip;
[0058] Step A2: After the chip is powered on and initialized, the host and PCIe_switch chip start to build a link, and then the host starts enumeration and sends the cfg configuration package:
[0059] If the host sends a cfg0 type message, it is marked as pkt0 here; because the up_sel of port1 configured by the software is 1, and the cfg0 message type is to configure the register space of UP itself, pkt0 does not need to perform routing forwarding processing, but directly converts pkt0 into the register configuration operation inside port1 to configure the address space of port1 itself; then directly execute step A5;
[0060] Step A3: If the host sends a cfg1 type message, which is marked as pkt1 here; according to the software configuration element up_sel is 1, and it is a cfg1 type message, it is determined to take the downlink ID routing path, and it is necessary to first forward the pkt1 route to the corresponding DP port; according to the pkt1 indication device_id==0, the port0 of the matching table entry is generated, and the downlink routing module generates an exit indication signal egr_id==0001;
[0061] Step A4: the logic judgment module sends pkt1 to port0 according to egr_id==0001; port0 directly converts pkt1 into the register configuration operation inside port0 to configure the address space of port0;
[0062] Step A5: Assume that pkt0 / pkt1 modifies the mem_base_address field in the space. For example, pkt0 configures the mem_base_address field in the space from 0x0 to 0x200_0000, and pkt1 configures the mem_base_address field in the space from 0x0 to 0x100_0000; then the updated mem_base_address values of port0 and port1 need to be refreshed to cfg_table, as shown in Table 2;
[0063] Step A6: cfg_table broadcasts all updated table entry contents (mem_base_address) to the address routing sub-table entries in each port;
[0064] Step A7: second_bus_number, subordinate_bus_number, mem_limit_address and other routing-related configuration information repeat steps A2 to A6 in the same way. In this way, when the host completes the 4K space configuration of all downstream ports (port0 to port3 in this example), the entire host enumeration process is completed. PCIe_switch also completes the update of cfg_table. At the same time, all routing information of cfg_table is broadcast to the routing sub-table items in each port (uplink ID routing table, downstream ID routing table, address routing table). At this point, subsequent messages sent by the host or ep will be sent to different routing sub-table items according to the message type after passing through the PCIe_switch chip, and each routing sub-table item will determine the outbound port of the message.
[0065] As mentioned earlier, Figure 3This is the scenario of uplink ID routing. When EP sends a message of type cpl or cpld, uplink ID routing will be performed. cpl is a return message without data, and cpld is a return message with data. Uplink ID routing can be routed to EP or host. Uplink ID routing does not require matching device_id and function_id in PCIe_switch. It only needs to determine whether the primary_bus_number carried by the message matches the second_bus_number, subordinate_bus_number ( Figure 3 In the example, primary_bus_number, second_bus_number, and subordinate_bus_number are replaced by pri_bus, 2nd_bus, and sub_bus). Figure 3 The uplink route is forwarded to the EP. The specific steps are as follows:
[0066] Step B1: After the message pkt2 sent by EP0 is received by port0, it is determined that uplink ID routing is required because the up_sel of port0 is 0, indicating that the inbound port is DP;
[0067] Step B2: pkt2 is sent to the upstream ID routing module to query the upstream routing table content; since the pri_bus carried by the pkt2 message is 7, which is within the range of 2nd_bus and sub_bus of port2 (7:9), the outbound port indication egr_id=0100 is generated;
[0068] Step B3: the logic judgment module sends the pkt2 message to port2 according to egr_id==0100;
[0069] Step B4: port2 forwards the message to EP1;
[0070] If the pri_bus carried by the message pkt3 sent by EP0 is not within the range of 2nd_bus and sub_bus of UP (2:15), for example, pri=17 of pkt3, then this message needs to be forwarded to Port1 and finally forwarded to the host.
[0071] The same is true when EP1 and EP2 send cpl and cpld messages. After upstream ID routing, they can be sent to other EPs or to the host.
[0072] In the previous host enumeration process, mem_base_address and mem_limit_address of all ports are configured and broadcasted to the address routing sub-table of each port. If the host or EP sends a mem type message, the message needs to be sent to the address routing module. Figure 4 Describes the scenario where the host sends a mem message to EP0. mem_base_address and mem_limit_address are abbreviated as base_adr and lmt_adr. The specific steps are as follows:
[0073] Step C1: The host sends a message pkt3. After receiving it through port1, the message type of pkt3 is first determined. Since pkt3 is a mem type message, logical determination requires address routing. The address routing in the upstream and downstream directions is determined based on whether the address range is hit. There is no need to distinguish between upstream address routing and downstream address routing.
[0074] Step C2: pkt3 is sent to the address routing module to query the address routing table content; since the mem_address carried by the pkt3 message is 0x120_0000, which is within the range of base_adr and lmt_adr of port0 (0x120_0000:0x1ff_ffff), the output port indication egr_id=0001 is generated;
[0075] Step C3: the logic judgment module sends the pkt3 message to port0 according to egr_id==0001;
[0076] Step C4: port0 forwards the message to EP0.
[0077] If EP0, EP1, and EP2 send mem type messages, the steps are the same as above; the only difference is that the mem messages sent by the host will only reach EP0 to EP2, while the messages sent by EP can go to other EPs or the host (if the address carried by the message sent by EP is outside the address range of the host, the message will be sent to the host).
[0078] The present invention defines local software configuration table items, which together with the host configuration table item content constitute the complete routing table of PCIe_switch, and copy the routing table to the corresponding routing sub-table items in each port by broadcasting. It can be seen from the above three scenarios that when the host or EP sends a message to PCIe_switch, it goes through three main steps: inlet message judgment, route matching, and outlet indication distribution; the specific processing method is different only in route matching, but whether it is uplink ID routing, downlink ID routing or address routing, the delay of route matching is the same. Therefore, whether it is UP or DP, the delay of the entire data path is the same.
[0079] It can be seen that the fully symmetrical PCIe Switch routing configuration method proposed in the present invention has the following advantages compared with the related art:
[0080] The ports of PCIe Switch adopt a fully symmetrical structure, which makes the delay between each port the same and imperceptible to users. Each port adopts a set of logic implementation, and only software needs to define the function, which reduces the complexity of implementation. The port attributes can be flexibly configured through software, so that devices such as CPU and SSD can be flexibly placed on a single board, making board-level design more convenient.
[0081] Accordingly, the present invention provides a fully symmetrical PCIe Switch routing configuration device in a second aspect, comprising:
[0082] A routing configuration unit, configured to receive routing configuration information of the PCIe Switch from software, and broadcast the routing configuration information to routing table entries of each port in the PCIe Switch, wherein the routing configuration information includes port attributes and a mapping relationship between each port and a device identifier, wherein the port attributes include an uplink port or a downlink port;
[0083] The message transmission unit is used to parse the message at the input port when the host or endpoint device sends a message to the PCIe Switch to obtain the destination device identifier of the message, determine the output port corresponding to the destination device identifier through the mapping relationship of the routing table entry, and send the message to the output port.
[0084] The above-mentioned device can be implemented by the fully symmetrical PCIe Switch routing configuration method provided by the embodiment of the first aspect above. The specific implementation method can refer to the description in the embodiment of the first aspect, which will not be repeated here.
[0085] It is understood that the circuit structures, names and parameters described in the above embodiments are only examples. Those skilled in the art can also make easily conceivable combinations and adjustments to the structural features of the above embodiments according to the use requirements, and the concept of the present invention should not be limited to the specific details of the above examples.
[0086] Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent substitutions for some of the technical features therein; and these modifications or substitutions do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A fully symmetric PCIe Switch routing configuration method, It is characterized in that include: Receive the routing configuration information of the PCIe Switch from the software, and broadcast the routing configuration information to the routing table items of each port in the PCIeSwitch, wherein the routing table items include PCIe_switch local software configuration table items and host configuration table items, wherein the local software configuration table items include registers configured by the PCIe_switch chip software during the chip power-on startup phase, and the host configuration table items are registers configured during the enumeration process during the server system initialization phase, wherein the routing configuration information includes port attributes and a mapping relationship between each port and a device identifier, wherein the port attributes include an upstream port or a downstream port; When a host or an endpoint device sends a message to the PCIe Switch, the message is parsed at the inbound port to obtain a destination device identifier of the message, and an outbound port corresponding to the destination device identifier is determined through a mapping relationship of the routing table entry to send the message to the outbound port; The receiving software for routing configuration information of the PCIe Switch further includes: The CPU in the PCIe Switch chip is called by software, and the routing configuration information is written into the routing configuration table in the chip through the CPU; The parsing of the message at the inbound port to obtain the destination device identifier of the message further includes: If the message is sent by the host, it is determined to be a downlink routing path, a routing table entry is queried in the downlink routing module of the ingress port, and an egress indication tag is generated according to a matched destination device identifier; If the message is sent by an endpoint device, it is determined to be an uplink routing path, a routing table entry is queried in the uplink routing module of the ingress port, and an egress indication tag is generated according to a matching destination device identifier; After broadcasting the routing configuration information to the routing table entry of each port in the PCIe Switch, the method further includes: The host first sends a configuration message, which is used to configure the register space of the upstream routing path and the downstream routing path. If the device identifier carried in the configuration message matches the device identifier of the target port in the broadcast table entry, the configuration message is sent to the target port to configure the space register of the port.
2. The fully symmetric PCIe Switch routing configuration method according to claim 1, It is characterized in that When the port attribute is 1, the port is configured as an uplink port, and when the port attribute is 0, the port is configured as a downlink port.
3. A fully symmetrical PCIe Switch routing configuration device, It is characterized in that include: A routing configuration unit, used to receive routing configuration information of the PCIe Switch from the software, and broadcast the routing configuration information to the routing table items of each port in the PCIe Switch, wherein the routing table items include PCIe_switch local software configuration table items and host configuration table items, wherein the local software configuration table items include registers configured by the PCIe_switch chip software during the chip power-on startup phase, and the host configuration table items are registers configured during the enumeration process during the server system initialization phase, wherein the routing configuration information includes port attributes and a mapping relationship between each port and a device identifier, wherein the port attributes include an upstream port or a downstream port; a message transmission unit, configured to parse the message at an inbound port to obtain a destination device identifier of the message when a host or an endpoint device sends a message to the PCIe Switch, determine an outbound port corresponding to the destination device identifier through a mapping relationship of the routing table entry, and send the message to the outbound port; The routing configuration unit is further used to: The CPU in the PCIe Switch chip is called by software, and the routing configuration information is written into the routing configuration table in the chip through the CPU; The message transmission unit is further used for: If the message is sent by the host, it is determined to be a downlink routing path, a routing table entry is queried in the downlink routing module of the ingress port, and an egress indication tag is generated according to a matched destination device identifier; If the message is sent by an endpoint device, it is determined to be an uplink routing path, a routing table entry is queried in the uplink routing module of the ingress port, and an egress indication tag is generated according to a matched destination device identifier.
4. The fully symmetrical PCIe Switch routing configuration device according to claim 3, It is characterized in that When the port attribute is 1, the port is configured as an uplink port, and when the port attribute is 0, the port is configured as a downlink port.
