A PCIe interconnection device and system
Through the coupling control unit of the PCIe interconnection device, multiple upstream ports and downstream ports are gathered, solving the problem of reduced bandwidth of PCIe Gen4 devices on the PCIe Gen3 interface, and achieving full utilization of resources and performance improvement of high-standard PCIe devices.
Patent Information
- Application Number
- CN202111165031.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-30
- Publication Date
- 2024-11-22
- Estimated Expiration
- 2041-09-30
AI Technical Summary
When the PCIe Gen4 device is plugged directly to the PCIe Gen3 interface of the host, the actual bandwidth of the device will drop from 16G to 8G, resulting in a significant drop in performance and wasting resources for high-standard devices.
Provide a PCIe interconnection device, through the coupling control unit, multiple upstream ports and downstream ports are gathered into a communication connection, so that the bandwidth limit value supported by the target PCIe device is not less than the sum of the bandwidth limit value output by each target upstream port, so as to realize Bandwidth convergence, making full use of the resources of high-standard PCIe devices.
Through bandwidth aggregation, multiple low-standard PCIe ports can connect to the same high-standard PCIe device, giving full play to the working performance of high-standard PCIe devices, and improving system performance and resource utilization.
Smart Images

Figure CN113986802B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a PCIe interconnection device and system. Background Art
[0002] At present, when a PCIe Gen4 device is directly plugged into the PCIe Gen3 interface of a host (such as a server), the actual bandwidth used by the PCIe Gen4 device will drop from 16G to 8G, causing a significant drop in performance. It can be seen that directly connecting high-standard devices with low-standard interfaces makes the high-standard devices only work according to low-standard bandwidth, wasting the resources of high-standard devices. PCIe (Peripheral Component Interconnect Express) is a high-speed serial computer expansion bus standard.
[0003] Therefore, how to give full play to the working performance of high-standard PCIe devices is a problem that technical personnel in this field need to solve. Summary of the invention
[0004] In view of this, the purpose of this application is to provide a PCIe interconnect device and system to give full play to the working performance of high-standard PCIe devices. The specific scheme is as follows:
[0005] In a first aspect, the present application provides a PCIe interconnect device, including:
[0006] A plurality of upstream ports, wherein the upstream ports are used to connect to a PCIe port of a host;
[0007] At least one downstream port, the downstream port being used to connect a PCIe device;
[0008] a coupling control unit connected to the upstream port and the downstream port respectively, the coupling control unit being used to select at least two target upstream ports and one target downstream port, and to establish a communication connection between each of the target upstream ports and a target PCIe device connected to the target downstream port;
[0009] In the communication connection, the target upstream port is mapped one-to-one with the functional module in the target PCIe device, and the bandwidth limit supported by the target PCIe device is not less than the sum of the bandwidth limits output by each of the target upstream ports.
[0010] Preferably, the coupling control unit is specifically used for:
[0011] Establishing a mapping relationship between an upstream bus number corresponding to the target upstream port, a module number of a functional module in the target PCIe device, and a downstream bus number corresponding to the module number;
[0012] Record each mapping relationship and mark a default mapping relationship in each mapping relationship.
[0013] Preferably, the coupling control unit is further used for:
[0014] Each mapping relationship and the default mapping relationship are shared to the target downstream port.
[0015] Preferably, the coupling control unit is further used for:
[0016] If a first request sent by the host is received through the target upstream port, querying a corresponding mapping relationship based on the upstream bus number corresponding to the target upstream port;
[0017] If the queried mapping relationship is the default mapping relationship, the first request is recorded, and the first request is transmitted to the functional module corresponding to the module number in the default mapping relationship based on the default mapping relationship.
[0018] Preferably, the coupling control unit is further used for:
[0019] If first response data of the first request is received, the first response data is returned to the host based on the default mapping relationship, and the resources occupied by the first request are released.
[0020] Preferably, the coupling control unit is further used for:
[0021] If the queried mapping relationship is not the default mapping relationship, the queried mapping relationship is determined as the currently required mapping relationship, and the module number in the first request is modified to the module number in the currently required mapping relationship to obtain a second request;
[0022] After recording the second request, the second request is transmitted to the target downstream port so that the target downstream port constructs a bidirectional conversion relationship between the downstream bus number in the currently required mapping relationship and the downstream bus number in the default mapping relationship, and based on the bidirectional conversion relationship and the downstream bus number in the default mapping relationship, the second request is transmitted to the functional module corresponding to the module number in the currently required mapping relationship.
[0023] Preferably, the number of the target upstream ports in the communication connection is an even number, and the bandwidth limit supported by the target PCIe device is equal to the sum of the bandwidth limits output by each of the target upstream ports.
[0024] Preferably, the number of the target upstream ports in the communication connection is 2.
[0025] In a second aspect, the present application provides a PCIe interconnection system, comprising: a host, a PCIe device, and a PCIe interconnection device as described in any of the above items.
[0026] It can be seen from the above scheme that the present application provides a PCIe interconnection device, including: multiple upstream ports, the upstream ports are used to connect to the PCIe ports of the host; at least one downstream port, the downstream port is used to connect to the PCIe device; a coupling control unit connected to the upstream port and the downstream port respectively, the coupling control unit is used to select at least two target upstream ports and one target downstream port, and establish a communication connection between each of the target upstream ports and the target PCIe device connected to the target downstream port; in the communication connection, the target upstream port is mapped one-to-one with the functional module in the target PCIe device, and the bandwidth limit supported by the target PCIe device is not less than the sum of the bandwidth limits output by each of the target upstream ports.
[0027] It can be seen that the present application provides a PCIe interconnection device, which is connected between a host PCIe port and a PCIe device, and can aggregate the bandwidth output by at least two PCIe ports to the same target PCIe device. Specifically, the coupling control unit in the PCIe interconnection device provided by the present application can aggregate at least two target upstream ports and one target downstream port into one communication connection, and the bandwidth output by each host PCIe port connected to these target upstream ports can be aggregated to the same target PCIe device. In this way, multiple low-standard PCIe ports can be connected to the same high-standard PCIe device, making full use of the resources of the high-standard PCIe device and giving full play to the working performance of the high-standard PCIe device.
[0028] Correspondingly, a PCIe interconnection system provided by the present application also has the above-mentioned technical effects. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.
[0030] Figure 1 A schematic diagram of a PCIe interconnection device disclosed in this application;
[0031] Figure 2 A connection diagram of a PCIe interconnect device aggregation bandwidth disclosed in this application;
[0032] Figure 3 A connection diagram of another PCIe interconnect device aggregation bandwidth disclosed in this application;
[0033] Figure 4 This is a schematic diagram of another PCIe interconnect device disclosed in this application. DETAILED DESCRIPTION
[0034] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0035] To facilitate the introduction of this application, the background technology involved in this application is first introduced as follows.
[0036] With the continuous development of server applications, the application demand for high-end servers has entered an important stage. Complex architecture implementation supports high-end server systems to achieve high performance indicators, namely high security, high availability, high reliability and other characteristics. Among them, the PCIe subsystem, as the core processing system of the server's IO access, plays a vital role in server system performance, application running speed and other functions.
[0037] As server system complexity and performance continue to increase, the demand for system resources such as IO access bandwidth is also increasing. However, on the other hand, the high-speed PCIe interface resources of the server system are limited by the size and cost of the processor, and it is difficult to increase them significantly. Therefore, additional interface expansion is required through local expansion switching chips.
[0038] The PCIe interfaces currently used by server systems are mainly PCIe Gen3 and Gen4. When a server with a PCIe Gen3 interface is connected to a PCIe Gen4 device, the PCIe Gen4 device has to reduce its own bandwidth for backward compatibility with Gen3, thus failing to fully utilize the high bandwidth characteristics of the PCIe Gen4 device itself. In particular, when a PCIe device has multiple functions, the bandwidth of each function will be halved, which has a significant impact on application performance.
[0039] For example, when a PCIe Gen4 device is directly plugged into the PCIe Gen3 interface of a host, the actual bandwidth used by the PCIe Gen4 device will drop from 16G to 8G, resulting in a significant drop in performance. It can be seen that directly connecting a high-standard device with a low-standard interface makes the high-standard device only work according to the low-standard bandwidth, wasting the resources of the high-standard device. To this end, the present application provides a PCIe interconnection device and system that can give full play to the working performance of high-standard PCIe devices.
[0040] See also Figure 1 As shown, the embodiment of the present application discloses a PCIe interconnect device, including:
[0041] Multiple upstream ports, where the upstream ports are used to connect to the PCIe ports of the host.
[0042] At least one downstream port, where the downstream port is used to connect a PCIe device.
[0043] A coupling control unit connected to the upstream port and the downstream port respectively, the coupling control unit is used to select at least two target upstream ports and one target downstream port, and establish a communication connection between each target upstream port and the target PCIe device connected to the target downstream port.
[0044] In the communication connection, the target upstream port is mapped one-to-one with the functional module in the target PCIe device, and the bandwidth limit supported by the target PCIe device is not less than the sum of the bandwidth limits output by each target upstream port.
[0045] like Figure 1 As shown, a host PCIe port is connected to an upstream port, and a downstream port is connected to a PCIe device. The coupling control unit can aggregate at least two upstream ports and one downstream port into one communication connection. Generally, the host provides 3-4 PCIe ports to the outside world. Too many interfaces will occupy too much hardware resources of the host.
[0046] This embodiment uses a coupling control unit to aggregate at least two target upstream ports and one target downstream port into one communication connection, and the bandwidth output by each host PCIe port connected to all target upstream ports in the communication connection can be aggregated to the same target PCIe device. For example: if two host PCIe ports are both PCIe3.0, then these two host PCIe ports can be connected to the same PCIe Gen4 device through the PCIe interconnect device provided by this embodiment, so that the sum of the bandwidth limits output by the two host PCIe ports, 16G, can be fully received and processed by the PCIe Gen4 device, thereby making full use of the PCIe Gen4 device and working performance.
[0047] Among them, the bandwidth of PCIe3.0 is limited to 8G, while PCIe Gen4 devices use PCIe4.0, which has a bandwidth limit of 16G. PCIe devices can be network cards, storage devices, etc.
[0048] In a specific implementation, the number of target upstream ports in the communication connection is an even number, and the bandwidth limit supported by the target PCIe device is equal to the sum of the bandwidth limits output by each target upstream port.
[0049] Among them, PCIe standards include: PCIe2.0 (bandwidth limit 4G), PCIe3.0 (bandwidth limit 8G), PCIe4.0 (bandwidth limit 16G), PCIe5.0 (bandwidth limit 32G), etc. Since the bandwidth limits between adjacent levels of PCIe standards are 2 times, the number of target upstream ports in a communication connection is 2.
[0050] It can be seen that the present embodiment provides a PCIe interconnect device, which is connected between a host PCIe port and a PCIe device, and can aggregate the bandwidth output by at least two PCIe ports to the same target PCIe device. Specifically, the coupling control unit in the PCIe interconnect device provided by the present application can aggregate at least two target upstream ports and one target downstream port into one communication connection, and the bandwidth output by each host PCIe port connected to these target upstream ports can be aggregated to the same target PCIe device. In this way, multiple low-standard PCIe ports can be connected to the same high-standard PCIe device, making full use of the resources of the high-standard PCIe device and giving full play to the working performance of the high-standard PCIe device.
[0051] Based on the above embodiments, it should be noted that, in a specific implementation manner, the coupling control unit is specifically used to: establish a mapping relationship between the upstream bus number corresponding to the target upstream port, the module number of the functional module in the target PCIe device, and the downstream bus number corresponding to the module number; record each mapping relationship, and mark a default mapping relationship in each mapping relationship.
[0052] In a specific implementation, the coupling control unit is further configured to: share each mapping relationship and the default mapping relationship to the target downstream port.
[0053] Among them, a target downstream port in a communication connection is connected to a target PCIe device through a bus, but this bus is programmed with multiple numbers, so that this bus is reused. That is, different mapping relationships in a communication connection record different upstream bus numbers, different downstream bus numbers, and different module numbers, so that each host PCIe port has a corresponding access path logically.
[0054] See also Figure 2 and Figure 3 , Figure 2 and Figure 3 Merges two upstream ports into one downstream port. Figure 2 In the example, root0 and root1 are host PCIe ports to which two upstream ports are connected respectively. Bridge is a functional module in the coupling control unit, which is used to connect the upstream bus BUS0 corresponding to root0, the upstream bus BUS1 corresponding to root1, and the downstream bus.
[0055] exist Figure 3 In the figure, MUX means coupling control unit; tracker0 and tracker1 are used to record the mapping relationship corresponding to root0 and the mapping relationship corresponding to root1 respectively. Among them, the mapping relationship recorded by tracker0 is: the upstream port number corresponding to root0 - BUS0 (upstream bus number) - BUS2 (downstream bus number) - Func0 (module number), and the space address information corresponding to Func0 is recorded at the same time. The mapping relationship recorded by Tracker1 is: the upstream port number corresponding to root1 - BUS1 (upstream bus number) - BUS3 (downstream bus number) - Func1 (module number), and the space address information corresponding to Func1 is recorded at the same time.
[0056] It should be noted that Figure 2 The downstream port shown is connected to a PCIe device, which has two functional modules: Function0 and Function1. Function0 is used to be accessed by root0 through BUS0 and BUS2, while Function1 is used to be accessed by root1 through BUS1 and BUS3. BUS2 and BUS3 are actually used to represent the same downstream bus. Here, two numbers are used to mark the access paths corresponding to root0 and root1. In other words, the same bus is simulated as two buses in different PCIe systems.
[0057] essentially, Figure 2 It illustrates two logically completely independent PCIe tree systems.
[0058] Among them, Func0 in root0-BUS0-BUS2-terminal device (ie, PCIe device) constitutes a PCIe system; Func1 in root1-BUS1-BUS3-terminal device constitutes another PCIe system.
[0059] Based on the above embodiments, it should be noted that, in a specific implementation, the coupling control unit is also used for: if a first request sent by the host is received through the target upstream port, then querying the corresponding mapping relationship based on the upstream bus number corresponding to the target upstream port; if the queried mapping relationship is a default mapping relationship, then recording the first request, and transmitting the first request to the functional module corresponding to the module number in the default mapping relationship based on the default mapping relationship.
[0060] In a specific implementation, the coupling control unit is further configured to: if first response data of the first request is received, return the first response data to the host based on a default mapping relationship, and release resources occupied by the first request.
[0061] Combination Figure 2 As shown, the two PCIe tree systems can work simultaneously, and two independent applications in the host system can bind the functions under root0 and root1 respectively through the host driver and call the corresponding functions respectively.
[0062] Specifically, application 0 in the host initiates access to Function0 through root0, and the access request enters the coupling control unit through BUS0. Tracker0 of the coupling control unit records the request and forwards it to the downstream port, and then to the terminal device through BUS2. The terminal device maps to Function0 according to the Function number to perform the operation. After the execution is completed, the response is returned to the coupling control unit through BUS2. The coupling control unit completes the resource release of the request by querying the request recorded in tracker0, and returns the response to root0 through BUS0.
[0063] Of course, Function0 of the terminal device can also actively initiate DMA to return data to the host memory. Its return path is BUS2-tracker0-BUS0-root0. This process can be completed according to the standard PCIe process.
[0064] Based on the above embodiments, it should be noted that, in a specific implementation, the coupling control unit is also used for: if the queried mapping relationship is not the default mapping relationship, then the queried mapping relationship is determined as the currently required mapping relationship, and the module number in the first request is modified to the module number in the currently required mapping relationship to obtain a second request; after recording the second request, the second request is transmitted to the target downstream port so that the target downstream port constructs a bidirectional conversion relationship between the downstream bus number in the currently required mapping relationship and the downstream bus number in the default mapping relationship, and based on the bidirectional conversion relationship and the downstream bus number in the default mapping relationship, the second request is transmitted to the functional module corresponding to the module number in the currently required mapping relationship.
[0065] Combination Figure 2 As shown, Application 1 in the host initiates access to Function 1 through root 1, and the information carried in the access request itself is still access to Function 0. Because Function 1 is recognized as Function 0 by root 1, Function 0 that root 1 thinks is actually Function 1 on the terminal device.
[0066] The access request enters the coupling control unit through BUS1. Tracker1 of the coupling control unit records the request and modifies the Function number in the access request tlp from 0 to 1 according to the mapping relationship of the initialization record. Then, the modified access request is forwarded to the downstream port, so that the downstream port modifies the BUS number from 3 to 2 according to the mapping relationship of the initialization record. Then, the access request is forwarded to the terminal device.
[0067] The terminal device performs the operation on Function1 according to the mapping of the Function number. After the execution is completed, the response is returned to the downstream port through BUS2. The downstream port modifies the BUS number from 2 to 3 and forwards the response to the coupling control unit. The coupling control unit completes the resource release of the request by querying the request recorded in tracker1 and returns the response to root1 through BUS1.
[0068] Of course, Function0 of the terminal device can also actively initiate DMA to return data to the host memory, and its return path is BUS2-BUS3-tracker1-BUS0-root0. This process is completed according to the standard PCIe process. It can be seen that the bus number 2 to 3 and the function number 1 to 0 also need to be modified in this process.
[0069] It can be seen that by modifying the bus number and identifying the Function number, a PCIe terminal device can be accessed by multiple host applications at the same time.
[0070] If applications 0 and 1 in the host access the terminal device at the same time, they each occupy half of the bandwidth resources of the terminal device. If applications 0 and 1 in the host access the terminal device independently in different time periods, each access process occupies all the bandwidth resources of the terminal device.
[0071] If root0 and root1 are both PCIe3.0 standard, the terminal device can be a PCIe Gen4 device. The data bandwidth used in the access process of the above example is 16G, which matches the bandwidth of the host interface and will not cause congestion problems during data communication.
[0072] If both root0 and root1 are PCIe4.0 standard, the terminal device can be a PCIe Gen5 device. The data bandwidth used in the access process in the above example is 32G, which can support access to two 16GB root interfaces at the same time.
[0073] The embodiment of the present application provides a PCIe interconnection system, including: a host, a PCIe device, and any of the above PCIe interconnection devices. The connection relationship between the three can refer to the relevant introduction of the above embodiment. The number of PCIe interconnection devices in a system is not limited, the number of PCIe devices is not limited, and the number of hosts is not limited, which can be determined according to actual usage.
[0074] The PCIe interconnect device includes: a plurality of upstream ports, the upstream ports are used to connect to the PCIe ports of the host. At least one downstream port, the downstream port is used to connect to the PCIe device. A coupling control unit connected to the upstream port and the downstream port respectively, the coupling control unit is used to select at least two target upstream ports and one target downstream port, and establish a communication connection between each target upstream port and the target PCIe device connected to the target downstream port. In the communication connection, the target upstream port is mapped one-to-one with the functional module in the target PCIe device, and the bandwidth limit supported by the target PCIe device is not less than the sum of the bandwidth limits output by each target upstream port.
[0075] In a specific embodiment, the coupling control unit is specifically used to: establish a mapping relationship between the upstream bus number corresponding to the target upstream port, the module number of the functional module in the target PCIe device, and the downstream bus number corresponding to the module number; record each mapping relationship, and mark a default mapping relationship in each mapping relationship.
[0076] In a specific implementation, the coupling control unit is further configured to: share each mapping relationship and the default mapping relationship to the target downstream port.
[0077] In a specific embodiment, the coupling control unit is also used to: if a first request sent by the host is received through the target upstream port, then query the corresponding mapping relationship based on the upstream bus number corresponding to the target upstream port; if the queried mapping relationship is a default mapping relationship, then record the first request, and transmit the first request to the functional module corresponding to the module number in the default mapping relationship based on the default mapping relationship.
[0078] In a specific implementation, the coupling control unit is further configured to: if first response data of the first request is received, return the first response data to the host based on a default mapping relationship, and release resources occupied by the first request.
[0079] In a specific embodiment, the coupling control unit is also used to: if the queried mapping relationship is not a default mapping relationship, determine the queried mapping relationship as the currently required mapping relationship, and modify the module number in the first request to the module number in the currently required mapping relationship to obtain a second request; after recording the second request, transmit the second request to the target downstream port so that the target downstream port constructs a bidirectional conversion relationship between the downstream bus number in the currently required mapping relationship and the downstream bus number in the default mapping relationship, and transmits the second request to the functional module corresponding to the module number in the currently required mapping relationship based on the bidirectional conversion relationship and the downstream bus number in the default mapping relationship.
[0080] In a specific implementation, the number of target upstream ports in the communication connection is an even number, and the bandwidth limit supported by the target PCIe device is equal to the sum of the bandwidth limits output by each target upstream port.
[0081] In a specific implementation, the number of target upstream ports in the communication connection is 2.
[0082] See also Figure 4 This embodiment provides another PCIe interconnect device. Figure 4 As shown in the figure, the local upstream interfaces Upstream1 and Upstream2 of the PCIe interconnect device are connected to the host through the PCIe3.0 interface, and are specifically connected to the two root interfaces on the host. For the connection method, see Figure 2 .
[0083] The two upstream interfaces Upstream1 and Upstream2 are connected to the coupling control unit, and the coupling control unit is connected to a downstream port Downstream, and the downstream port Downstream is connected to a PCIe4.0 terminal device. Figure 2 and Figure 3 As shown, Upstream1 is connected to root0, and Upstream2 is connected to root1.
[0084] In this way, the bandwidth of the two upstream interfaces Upstream1 and Upstream2 is 16GB respectively, and the bandwidth of the downstream port Downstream is 32GB. The coupling control unit can combine the bandwidth output by the two upstream interfaces to access the PCIe4.0 terminal device. The bandwidth on the access path is fully matched, which can fully utilize the bandwidth of the PCIe4.0 terminal device and fully exert the performance of the PCIe4.0 terminal device. Figure 4 As shown, the PCIe4.0 terminal device can be a GPU, a storage device or a memory device, etc.
[0085] In this embodiment, the two root nodes root0 and root1 search for downstream devices on their own buses respectively during initialization.
[0086] Root0 searches for devices under BUS0 and finds the bridge device. It finds that the downstream bus number of the bridge device is 2. It then searches for devices under bus 2 and finds the terminal device. It reads the terminal device space and finds Function0 on the terminal device.
[0087] Root1 searches for devices under BUS1 and finds the bridge device. It finds that the downstream bus number of the bridge device is 3. It then searches for devices under bus 3 and finds the terminal device. It reads the terminal device space and finds Function1 on the terminal device.
[0088] The bridge is reused by root0 and root1. Different roots access the bridge and get different return information. Root0 and root1 think they are accessing two bridges, whose upstream and downstream bus numbers are 0 / 2 and 1 / 3 respectively. When two roots access the terminal device mounted on the downstream bus through the bridge they are connected to, the device space information read is a device with two functions, but the coupling control unit will modify this space information so that both roots think that the device they read has only one function.
[0089] The device Function bound to root0 under its own bus is Function0, and the device bound to root1 under its own bus is Function1. However, root1 will think that the Function bound to its downstream bus is also Function0, and the address space information mapped by Function1 is also considered to be the space address information mapped by Function0.
[0090] Root1 records its downstream bus numbers as 1 and 3. In fact, since the terminal device can only bind to one bus number 2, bus number 3 actually only exists in root1's traversal record space. These address mapping information and bus number mapping information will be recorded in tracker0 and tracker1, and will also be recorded on the downstream port, so that the root can modify the bus number when exchanging information with the device function.
[0091] The specific access process of the PCIe interconnect device provided in this embodiment can be combined with Figure 2 , 3As well as the above related introduction, I will not repeat them here. This PCIe interconnect device can be compatible with more different versions of PCIe devices, which greatly expands the applicable scenarios of the server and improves its performance. At the same time, multiple root interfaces share a PCIe device. Without upgrading the server PCIe interface, it can fully utilize the bandwidth of the host PCIe low-version interface to access devices with high-version PCIe, effectively improving the life cycle of the server. In addition, it makes full use of the bandwidth resources of high-version PCIe devices to improve bandwidth utilization and business operation efficiency.
[0092] The "first", "second", "third", "fourth", etc. (if any) referred to in this application are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods or devices.
[0093] It should be noted that the descriptions involving "first", "second", etc. in this application are only for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In addition, the technical solutions between the various embodiments can be combined with each other, but they must be based on the ability of ordinary technicians in this field to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such combination of technical solutions does not exist and is not within the scope of protection required by this application.
[0094] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.
[0095] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of readable storage medium known in the art.
[0096] Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for those skilled in the art, according to the idea of the present application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A PCIe interconnect device, characterized in that: include: A plurality of upstream ports, wherein the upstream ports are used to connect to a PCIe port of a host; At least one downstream port, the downstream port being used to connect a PCIe device; a coupling control unit connected to the upstream port and the downstream port respectively, the coupling control unit being used to select at least two target upstream ports and one target downstream port, and to establish a communication connection between each of the target upstream ports and a target PCIe device connected to the target downstream port; In the communication connection, the target upstream port is mapped one-to-one with the functional module in the target PCIe device, and the bandwidth limit supported by the target PCIe device is not less than the sum of the bandwidth limits output by each of the target upstream ports; Wherein, the coupling control unit is specifically used for: Establishing a mapping relationship between an upstream bus number corresponding to the target upstream port, a module number of a functional module in the target PCIe device, and a downstream bus number corresponding to the module number; Record each mapping relationship and mark a default mapping relationship in each mapping relationship; Among them, a target downstream port in a communication connection is connected to a target PCIe device through a bus, and the bus is programmed with multiple numbers to reuse the bus; different mapping relationships in a communication connection record different upstream bus numbers, different downstream bus numbers, and different module numbers, so that each host PCIe port logically has a corresponding access path; Wherein, the coupling control unit is also used for: If a first request sent by the host is received through the target upstream port, querying a corresponding mapping relationship based on the upstream bus number corresponding to the target upstream port; If the queried mapping relationship is the default mapping relationship, recording the first request, and transmitting the first request to the function module corresponding to the module number in the default mapping relationship based on the default mapping relationship; Wherein, the coupling control unit is also used for: If the queried mapping relationship is not the default mapping relationship, the queried mapping relationship is determined as the currently required mapping relationship, and the module number in the first request is modified to the module number in the currently required mapping relationship to obtain a second request; After recording the second request, the second request is transmitted to the target downstream port so that the target downstream port constructs a bidirectional conversion relationship between the downstream bus number in the currently required mapping relationship and the downstream bus number in the default mapping relationship, and based on the bidirectional conversion relationship and the downstream bus number in the default mapping relationship, the second request is transmitted to the functional module corresponding to the module number in the currently required mapping relationship.
2. The PCIe interconnect device according to claim 1, characterized in that: The coupling control unit is also used for: Each mapping relationship and the default mapping relationship are shared to the target downstream port.
3. The PCIe interconnect device according to claim 1, characterized in that: The coupling control unit is also used for: If first response data of the first request is received, the first response data is returned to the host based on the default mapping relationship, and the resources occupied by the first request are released.
4. The PCIe interconnect device according to any one of claims 1 to 3, characterized in that: The number of the target upstream ports in the communication connection is an even number, and the bandwidth limit supported by the target PCIe device is equal to the sum of the bandwidth limits output by each of the target upstream ports.
5. The PCIe interconnect device according to claim 4, characterized in that: The number of the target upstream ports in the communication connection is 2.
6. A PCIe interconnection system, characterized in that: include: A host, a PCIe device, and a PCIe interconnect device as claimed in any one of claims 1 to 5.
Citation Information
Patent Citations
Adaptation device, system and method for enabling single I / O device to be shared by multiple root nodes
CN105320628A
Dynamic connection of PCIE devices and functions to an array of hosts
CN107148623A
Bandwidth integration network apparatus, mother board and network card
TW201705726A
Dynamic interface port assignment for communication transaction
US10248607B1
Sharing single root IO virtualization peripheral component interconnect express devices
US20150149661A1
