Method for exchanging interface information relating to PCI-Express interface
By automatically configuring the PCI-Express interface, the communication configuration between data processing units is simplified, the complexity problem caused by manual configuration file exchange in the prior art is solved, and the development efficiency is improved.
Patent Information
- Application Number
- CN202510157675.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2024-02-13
- Filing Date
- 2025-02-13
- Publication Date
- 2025-08-15
AI Technical Summary
When developing complex systems, when communicating between data processing units through PCI-Express, the prior art requires manual matching and exchange of large amounts of configuration files, resulting in complex and time-consuming development process.
By obtaining interface definitions, creating its serialized form, and automatically configuring the second communication partner to achieve direct memory access and reduce manual configuration requirements.
The communication configuration process between data processing units is simplified, development efficiency is improved, and manual configuration is reduced.
Smart Images

Figure CN120492382A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a method for exchanging interface information related to a PCI-Express interface. In addition, the present invention also relates to a system for data processing. Background Art
[0002] PCIe, also known as PCI-Express (Peripheral Component Interconnect Express), is a point-to-point bus system that enables communication between various data processing units in a hardware system, such as between external devices and the main processor. PCI-Express enables very high data transfer speeds.
[0003] Data processing units that communicate with one another via the PCI Express bus are also referred to herein as communication partners.
[0004] An important feature of PCI-Express is that it enables direct access to the (internal) memory of a communication partner with which it communicates via PCI-Express. In particular, the processor (CPU) of the communication partner with which it communicates does not participate in the communication. The communication partner (sending data) writes the data directly into the memory of the other communication partner (receiving data), without the processor of the other communication partner being involved. This enables high communication speeds, in particular because the communication speed is not limited by the performance of the processors of the communication partner receiving the data and the communication partner sending the data. In particular, the communication partner sending the data does not need to transfer the data first through a communication stack, nor does it need to split, package, and send the data for this purpose. This usually requires processor resources, which can be saved when using PCI-Express to communicate between communication partners.
[0005] In order to enable such communication, the memory management of each communication partner must be known to each other. A communication partner must know exactly which areas of the memory of the other communication partner it should and is allowed to read / write.
[0006] This requirement for PCI Express is a significant challenge, particularly when developing complex systems comprising hardware and software with a large number of participating data processing units that communicate via PCI Express, and when complex dependencies exist between the individual data processing units.
[0007] For example, such systems are used for highly automated or autonomous driving operations of motor vehicles. For example, such systems process sensor data acquired by sensors in the motor vehicle to derive information for the highly automated or autonomous driving operations of the motor vehicle. Such systems typically include a large number of data processing units that perform interrelated data processing tasks, necessitating efficient communication between the various data processing units. In such systems, communication between the data processing units is typically performed via PCI Express.
[0008] Other systems, in which the use of PCI Express for communication between data processing units presents significant challenges, especially during development, are measurement technology systems that record data in order to subsequently use it for experiments or as training data for machine learning.
[0009] Typically, for communication between data processing units via PCI Express, the following configuration is required, with the help of which the memory areas and / or memory structures of the communication partners are communicated to each other in advance. In the driver (Treiber) of the corresponding communication partner, the various memory areas / memory structures (local and remote) are configured. Here, the term "local" refers to the corresponding resources (e.g., memory) of the corresponding communication partner itself. The term "remote" refers to the corresponding resources (e.g., memory) of another (distant) communication partner. Thus, the first communication partner knows which memory locations in the second communication partner are allowed to be accessed (read and write), so that the memory locations can correctly interpret the data. Access to the data in the memory of the remote communication partner is performed by the hardware of the local communication partner according to the configuration as predefined by the driver.
[0010] When developing such a system, the development work for each data processing unit usually also needs to change the interfaces to other data processing units, and in particular also needs to be matched to the memory layout and memory distribution. This matching is usually carried out by providing matched configuration files, in which these interfaces are described. During the development of a complex system with many data processing units, these matched configuration files usually have to be manually exchanged between the development teams of different data processing units. Next, these files are used to configure the various drivers of the communication partners. What is also usually required using PCI-Express as the communication interface between the data processing units is that a small matching of a data processing unit also needs to be exchanged between the various data processing units or between the development teams developing the various data processing units. This makes the process of developing such a system extremely complicated and time-consuming. Summary of the Invention
[0011] Based on this, a novel method is now proposed for adapting a PCI Express interface for communication between different data processing units or communication partners, which method significantly reduces the described complexity during the development process.
[0012] A method for exchanging interface information between different communication partners for communication between the communication partners via PCI Express is proposed, comprising the following steps:
[0013] a) determining an interface definition that describes a memory area and an internal memory layout of the first communication partner, to which the second communication partner is to access in order to read and / or write data;
[0014] b) creating a serialized form of the interface definition obtained in step a);
[0015] c) providing the serialized form of the interface definition created in step b) to the second communication partner; and
[0016] d) Automatically configuring the second communication partner using the provided interface definition for communication with the communication partner.
[0017] A method for communicating between a first communication partner and a second communication partner is described herein. This method can be applied to both communication partners. Similarly, both communication partners can read from or write to corresponding memory areas. In a preferred embodiment, the two communication partners are data processing units that work together in a (larger) data processing system. In a (larger) data processing system, such data processing units can also work together and communicate in both directions, so that one data processing unit sometimes acts as the first communication partner and sometimes as the second communication partner. The respective second communication partner actively accesses (reads and / or writes) the memory of the respective first communication partner.
[0018] PCI Express provides for direct access to the memory of the communication partner. This applies to both read and write access. The processor (or CPU / DMA) of the second communication partner directly accesses the memory of the first communication partner. For the memory areas of the first communication partner provided for this purpose, the second communication partner has addresses mapped to the memory of the first communication partner in its local address space.
[0019] When the second communication partner writes / reads data to / from these addresses in its local address space, these data are automatically written to / read from the memory of the first communication partner.
[0020] The automatic transfer of data to / from the memory of the first communication partner is carried out via PCI Express. The processor of the first communication partner does not participate in the transfer. The processor of the second communication partner automatically triggers the data transfer by accessing the local address set in its address space.
[0021] PCI Express preferably maps the first three layers of the ISO / OSI reference model: the physical layer, the data link layer, and the so-called network layer. Above these three layers, custom programming is usually required to configure the PCI Express interface. When configuring the PCI Express interface, the local driver must individually configure the association between addresses in the local address space of the second communication partner and corresponding addresses in the memory of the first communication partner.
[0022] It is now proposed to at least temporarily automate the configuration of a PCI Express interface. To this end, a description of the interface is provided in an interface definition, which describes the memory areas and the memory layout provided for data access of a first communication partner. The interface definition is provided in serialized form (steps a) and b). Determining the interface definition according to step a) can, for example, include reading an object structure of the interface, which describes the memory areas and the memory layout provided for communication with a second communication partner. According to step b), the serialization can be performed, for example, using functions available in common programming languages for serializing objects.
[0023] Next, the interface definition can be provided in serialized form (step c). Then, according to step d), at least one communication partner is automatically configured using the interface definition.
[0024] Therefore, it is proposed to provide an interface description or interface definition in the form of a serialized information object. Thus, an attached PCI-Express device (second communication partner) can be dynamically connected to the interface of the first communication partner without knowing the exact PCIe protocol interface of the first communication partner.
[0025] The method described here proposes a novel approach for making known the memory layout of a first communication partner, which is provided for communication via PCI Express, to another (second) communication partner.
[0026] It is particularly preferred that the interface definition determined in step a) also contains protocol information.
[0027] In particular, the interface definition determined in step a) contains information about the registers and / or virtual registers to be described and their structure.
[0028] The protocol information or the protocol register structure contains, in particular, information such as protocol data relating to the communication via the PCI Express interface, which is to be stored and evaluated in order to ensure error-free communication via the PCI Express interface.
[0029] Providing the memory description in a serialized structure enables particularly efficient transmission of the memory description according to step c). In the serialized interface description, in addition to the memory layout, additional information can also be efficiently transmitted in the definition. This includes, in particular, protocol information.
[0030] The interface definition allows for automated and dynamic adaptation of the second communication partner.
[0031] Preferably, the provision of the interface definition according to step c) includes storing the interface definition in serialized form in a memory area of the first communication partner provided for this purpose, wherein the second communication partner calls up the interface definition from the memory area of the first communication partner.
[0032] In systems where individual data processing units are regularly modified, communication between them is often complex. "Hard" information linkage is often a problem. For example, the memory layout and usage of two data processing units that are to communicate with each other as communication partners must be known in advance.
[0033] To solve this problem, it is proposed to provide a memory definition and its use as a serialized object in the accessible memory of the first communication partner. The first communication partner then informs the second communication partner (other data processing unit) via this interface definition in what form the data in its memory should be accessed.
[0034] Preferably, the interface definition according to step a) is first created as an XML structure or a JSON structure, and then the serialization according to step b) is performed using a serialization function for XML or JSON.
[0035] XML and / or JSON are particularly suitable for describing complex structures. In addition to the memory layout, XML and / or JSON can be used to provide other information in the data structure, such as the protocol information already described above.
[0036] The second communication partner can preferably read the interface definition and, during "development" or at runtime, adapt its system to the memory layout used by the first communication partner.
[0037] The second communication partner preferably has a configurable communication stack for communicating with the first communication partner, wherein the configurable communication stack is configured in step d) using the transferred interface definition.
[0038] In this case, the configurable communication stack forms a configurable driver in the second communication partner, which is configured using the interface definition provided by the first communication partner in order to enable smooth communication between the communication partners and, in particular, to avoid manual exchange of interface definitions between the communication partners when changes occur in the communication-related memory structures of the communication partners.
[0039] The configurable communication stack or the configurable driver is preferably configured to configure itself using the interface definition provided in step c). Particularly preferably, the interface definition is first deserialized for this purpose. The configurable communication stack or the configurable driver is preferably then configured to adapt itself to the communication partner receiving the data based on the interface definition.
[0040] The method is particularly preferably used during the development of a data processing unit for highly automated driving for processing sensor data.
[0041] In the method, a data processing unit that in particular acts as a second communication partner is, for example, a sensor or a sensor system that provides sensor data to further data processing units that in the method in particular act as a first communication partner.
[0042] Especially during the development of such systems, developers frequently make changes to data processing units, which also affect the memory layout. Without the described method, drivers would typically need to be manually configured on all other data processing units communicating with one data processing unit. This is often a significant expense, significantly complicating the development of such systems. With the described method, much of this expense can be eliminated or replaced through automation.
[0043] Here, a system for data processing is also described, which comprises at least two data processing units, at least one data processing unit serving as a second communication partner and at least one further data processing unit serving as a first communication partner, the data processing units being configured to exchange interface information with one another according to the method of one of the aforementioned embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] The present invention and its technical background are described in more detail below with reference to the accompanying drawings. The drawings illustrate preferred embodiments, but the present invention is not limited to these embodiments. It should be noted that the drawings and, in particular, the dimensional ratios shown in the drawings are only schematic.
[0045] Figure 1 A system is shown comprising two data processing units which are arranged to exchange interface information with each other according to the method described herein; and
[0046] Figure 2 A flow chart of the method is shown. DETAILED DESCRIPTION
[0047] Figure 1 A system 1 is shown, comprising two data processing units 2, which can exchange interface information with each other according to the method described herein. One of the data processing units 2 is a second communication partner 3. The other of the data processing units 2 is a first communication partner 4. Both data processing units 2 preferably each have a processor 5 or CPU and a memory 6. Communication between the two data processing units 2 preferably takes place via a PCI Express interface.
[0048] Preferably, data processing unit 2, acting as first communication partner 4, provides interface definitions 7 in a memory area 8 provided for this purpose in its memory 6. Data processing unit 2, acting as second communication partner 3, preferably retrieves interface definitions 7 from this memory area 8. This is schematically illustrated here by interface transmission 10. Particularly preferably, processor 5 of data processing unit 2, acting as second communication partner 3, is configured to configure a configurable communication stack or configurable driver 9 using interface definitions 7. This configuration 13 is illustrated as an arrow. Configuration 13 is performed using interface definitions 7 so that a data transmission 11 is subsequently performed via PCI Express interface 12 such that data is correctly stored in the corresponding memory area 8 provided for this purpose in memory 6 of data processing unit 2, acting as first communication partner 4 (write access), or the desired data is correctly retrieved from the provided memory area 8 in memory 6 of the first communication partner 4 (read access). Thus, the arrows for data transmission 11 illustrate the read and write accesses performed using the communication stack or configurable driver 9 and its configuration according to interface definitions 7.
[0049] Figure 2 The flow chart of the method is schematically shown. Steps a), b), c) and d) can be seen, which are carried out according to the method in order to exchange interface information between communication partners communicating with each other via a PCI Express interface.
Claims
1. A method for exchanging interface information between different communication partners for communication between the communication partners (3, 4) via PCI-Express, the method comprising the following steps: a) determining an interface definition (7) which describes a memory area (8) and an internal memory layout of the first communication partner (4) to which the second communication partner (3) is to access in order to read and / or write data; b) creating a serialized form of the interface definition (7) obtained in step a); c) providing the serialized form of the interface definition (7) created in step b) to the second communication partner (3); and d) Automatically configuring the second communication partner (3) using the provided interface definition (7) for communication between the communication partners (3, 4).
2. The method according to claim 1, wherein The interface definition (7) determined in step a) also contains protocol information.
3. The method according to claim 1, wherein: The transmission of the interface definition (7) according to step c) comprises storing the interface definition (7) in serialized form in a memory area (8) provided for this purpose of the first communication partner (4), wherein the second communication partner (3) calls (10) the interface definition (7) from the memory area (8) of the first communication partner (4).
4. The method according to claim 1, wherein: Said interface definition (7) according to step a) is first created as an XML structure or a JSON structure and then the serialization according to step b) is performed using a serialization function for XML or JSON.
5. The method according to claim 1, wherein: The second communication partner (3) has a configurable communication stack (9) for communicating with the first communication partner (4), wherein the configurable communication stack (9) is configured in step d) using the provided interface definition (7).
6. The method according to any one of the preceding claims, wherein: The method is used during the development of a data processing unit (2) for processing sensor data for highly automated driving.
7. A system (1) for data processing, comprising at least two data processing units (2), wherein: At least one data processing unit (2) as a second communication partner (3) and at least one further data processing unit (2) as a first communication partner (4) are configured to exchange interface information with one another according to the method according to one of the preceding claims.