Data processing method and device and related equipment
By defining multiple application domains in a system-level chip, using memory sharing and Mailbox mechanisms to realize the replication of data frames and the elimination of redundant data frames, the complexity of existing FRER solutions in hardware design and network configuration is solved, and the efficiency and reliability of data transmission are improved.
Patent Information
- Application Number
- CN202411774294.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-04
- Publication Date
- 2025-05-06
AI Technical Summary
The existing FRER solutions have complexity and high costs in terms of hardware design, network redundant path configuration and hardware performance requirements, making it difficult to achieve efficient and reliable data transmission.
By defining multiple application domains in a system-level chip, using memory sharing and Mailbox mechanisms between the first application domain and the multiple second application domains, the replication of data frames and the elimination of redundant data frames are realized, and data processing efficiency and network communication reliability are improved.
This method simplifies hardware design, reduces network configuration complexity, improves data transmission efficiency and reliability, and reduces the processing load of redundant data frames.
Smart Images

Figure CN119945987A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of chip technology, and in particular to a data processing method, device and related equipment. Background Art
[0002] In vehicle systems, especially in intelligent driving and intelligent transportation systems, the reliability of real-time data transmission is directly related to traffic safety and the personal safety of vehicle owners or passengers; IEEE802.1 CB protocol technology improves the reliability of data transmission through redundant link transmission to ensure the normal operation of vehicle systems. In industrial environments, the timeliness and reliability of communication are crucial; IEEE 802.1CB transmits data through redundant paths to ensure that data arrives in time even in the event of a network failure.
[0003] IEEE802.1 CB protocol, also known as Frame Replication and Elimination for Reliability (FRER), is part of Time-Sensitive Networking (TSN). Its main goal is to improve the reliability of network communications by replicating and eliminating redundant frames.
[0004] At present, the implementation of the FRER solution has problems such as complex hardware design, complex network redundant path configuration, and high hardware performance requirements. Summary of the invention
[0005] The present disclosure provides a data processing method, apparatus and related equipment to at least solve the above technical problems existing in the prior art.
[0006] In a first aspect, an embodiment of the present disclosure provides a data processing method, the method being applied to a system-on-chip, the system-on-chip comprising a first application domain and at least two second application domains; the method comprising:
[0007] If the first application domain determines a first data frame to be copied, each of the at least two second application domains respectively obtains a copy data frame of the first data frame and sends each of the copy data frames; and / or,
[0008] If a second application domain among the at least two second application domains receives a second data frame whose redundancy is to be eliminated, the first application domain determines a redundant data frame corresponding to the second data frame, and deletes the redundant data frame.
[0009] In a second aspect, an embodiment of the present disclosure provides a data processing device, the device comprising a system-level chip, the system-level chip comprising a first application domain and at least two second application domains; the device comprising: a first processing module of the first application domain, a second processing module of each of the second application domains;
[0010] The second processing module is configured to obtain a duplicate data frame of the first data frame and send each of the duplicate data frames if the first application domain determines the first data frame to be duplicated; and / or
[0011] The first processing module is configured to determine a redundant data frame corresponding to the second data frame and delete the redundant data frame if a second application domain among the at least two second application domains receives a second data frame to be de-redundant.
[0012] In a third aspect, an embodiment of the present disclosure provides a component on a traffic device, wherein the component includes a system-level chip, and the system-level chip can implement the above-described method.
[0013] In a fourth aspect, an embodiment of the present disclosure provides a transportation device, wherein the transportation device includes a system-level chip, and the system-level chip can implement the above-described method.
[0014] In a fifth aspect, an embodiment of the present disclosure provides an electronic device, the electronic device comprising:
[0015] at least one processor; and
[0016] a memory communicatively connected to the at least one processor; wherein,
[0017] The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform any of the above methods.
[0018] In a sixth aspect, an embodiment of the present disclosure provides a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable a computer to execute the method described above.
[0019] The data processing method, device and related equipment provided by the embodiments of the present disclosure are applied to a system-on-chip, and the system-on-chip includes a first application domain and at least two second application domains; the method includes: if the first application domain determines a first data frame to be copied, each of the at least two second application domains respectively obtains a copy data frame of the first data frame and sends each of the copied data frames; and / or, if a second application domain of the at least two second application domains receives a second data frame to be de-redundant, the first application domain determines a redundant data frame corresponding to the second data frame and deletes the redundant data frame. In this way, the first application domain and multiple second application domains are used to implement data frame duplication and / or elimination of redundant data frames, thereby improving the efficiency of data processing and further improving the reliability of network communication.
[0020] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 A schematic diagram of the implementation principle of the data processing method based on FRER is shown;
[0022] Figure 2 The following is a schematic diagram showing the implementation process of the data processing method provided by the embodiment of the present disclosure. Figure 1 ;
[0023] Figure 3 The following is a schematic diagram showing the implementation process of the data processing method provided by the embodiment of the present disclosure. Figure 2 ;
[0024] Figure 4 A schematic diagram showing the functional division of a system-on-chip provided by an embodiment of the present disclosure is shown;
[0025] Figure 5 A schematic diagram showing a format of a FRER processing frame type provided by an embodiment of the present disclosure is shown;
[0026] Figure 6 A schematic diagram of the structure of a data processing device provided by an embodiment of the present disclosure is shown;
[0027] Figure 7 A schematic structural diagram of an electronic device provided by an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0028] In order to make the purpose, features, and advantages of the present disclosure more obvious and easy to understand, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present disclosure.
[0029] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it can be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0030] In the following description, the terms "first\second" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present disclosure described herein can be implemented in an order other than that illustrated or described herein.
[0031] Unless otherwise defined, all technical and scientific terms used in this disclosure have the same meaning as those commonly understood by those skilled in the art to which this disclosure belongs. The terms used in this disclosure are only for the purpose of describing the embodiments of this disclosure and are not intended to limit this disclosure.
[0032] It should be understood that in the various embodiments of the present disclosure, the size of the serial number of each implementation process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present disclosure.
[0033] Before further describing the embodiments of the present disclosure in detail, the nouns and terms involved in the embodiments of the present disclosure are described. The nouns and terms involved in the embodiments of the present disclosure are subject to the following interpretations.
[0034] The IEEE802.1CB protocol mainly defines FRER (frame replication and elimination for reliability) to improve service reliability.
[0035] Figure 1 FIG. 4 shows a schematic diagram of the implementation principle of the data processing method based on FRER; Figure 1 As shown, when the sender (i.e., Talker) sends data, it uses its FRER functional component to copy the data frame, obtain multiple copies and encapsulate the data frame, adding redundant tags and sequence numbers ( Figure 1Seq-Split in the figure indicates the sequence number sent by the sender), which is sent to the switch and transmitted redundantly along different paths. Figure 1 In the example, four switches (SwitchB, SwitchC, SwitchD, and SwitchE) form two redundant paths. The sender transmits a copy of the data packet to the receiver (i.e., the Listener) through the two redundant paths through network port 1 (eth-1) and network port 2 (eth-2).
[0036] When the receiving end receives data, the FRER functional component at the receiving end calculates the redundant tag and sequence number ( Figure 1 Seq-Rec in it represents the sequence number received by the receiving end), eliminating redundant data frame copies and leaving only one data packet copy.
[0037] The FRER mechanism ensures that even if network equipment and links fail, at least one correct data frame can reach the receiving end, reducing the packet loss rate and ensuring network reliability.
[0038] Currently, the hardware implementation method of FRER is complex and requires the addition of additional hardware modules to network devices to support functions such as frame identification, replication, elimination, and sequence number management. The design and manufacture of these modules increase hardware costs. On the other hand, FRER requires redundant paths in the network topology to ensure that data packets can be transmitted through different paths, which means more network devices and more complex network configurations are required. On the other hand, in order to achieve low latency and high reliability, FRER hardware needs to have high-performance processor capabilities that can quickly process large numbers of data packets and perform real-time frame replication and elimination.
[0039] In summary, the current implementation of the FRER solution has problems such as complex hardware design, complex network redundant path configuration, and high hardware performance requirements.
[0040] Based on this, an embodiment of the present disclosure provides a data processing method. Figure 2 The following is a schematic diagram showing the implementation process of the data processing method provided by the embodiment of the present disclosure. Figure 1 ;like Figure 2 As shown, the method is applied to a system on chip (SoC), the system on chip includes a first application domain and at least two second application domains; the method includes:
[0041] Step 201: If the first application domain determines a first data frame to be copied, each of the at least two second application domains obtains a copy data frame of the first data frame and sends each of the copy data frames; and / or,
[0042] Step 202: If a second application domain among the at least two second application domains receives a second data frame whose redundancy is to be eliminated, the first application domain determines a redundant data frame corresponding to the second data frame, and deletes the redundant data frame.
[0043] In some embodiments, the system-level chip can be a packaged semiconductor device, which may include a wafer (Die), or multiple identical or different wafers, and may also include a chip designed and manufactured using chiplet technology.
[0044] The method provided by the embodiment of the present disclosure can be specifically applied to a multi-core heterogeneous chip system-on-chip. A multi-core heterogeneous chip can also be called a heterogeneous multi-core chip, which contains multiple computing cores inside, and the computing cores contain at least two architectures. The multi-core heterogeneous chip can be configured as multiple domains isolated from each other, each domain is a hardware set containing at least one computing core and other hardware resources. The computing cores are divided into large cores and small cores. The hardware set where the large core is located is suitable for running a high-performance operating system, and the hardware set where the small core is located is suitable for running a low-performance, fast and more secure operating system. Information is transmitted between different hardware sets through inter-core communication channels.
[0045] A hardware collection can be understood as a set of hardware collections consisting of hardware resources such as the central processing unit or central processing unit cluster, interrupt controller, clock controller, and memory space in a multi-core heterogeneous chip. Each hardware collection can be configured to independently support the operation of the operating system.
[0046] In the present disclosure, the multi-core heterogeneous chip system-level chip is referred to as a multi-core heterogeneous chip. It should be understood that the multi-core heterogeneous chip described in the present disclosure specifically refers to a multi-core heterogeneous chip system-level chip or a heterogeneous multi-core chip system-level chip, including the characteristics of the multi-core heterogeneous chip and system-level chip described above.
[0047] In some embodiments, an application domain may refer to a division of different functional areas or computing units within a chip, which helps to achieve more efficient task processing and collaboration. Each application domain typically contains a set of cores with specific functions that can work together as needed.
[0048] For application domains in multi-core heterogeneous chip system-level chips, different parts of the chip are divided into multiple application domains, each of which focuses on performing a specific type of task. Different cores (such as high-performance cores, low-power cores, AI acceleration units, GPUs, etc.) can dynamically switch to different application domains according to the characteristics of the task, thereby improving overall efficiency.
[0049] Application domains can include:
[0050] Compute Domain: This domain contains high-performance cores that handle computationally intensive tasks, which may be processor cores (CPUs) or dedicated accelerators (such as GPUs, AI processing units, etc.). This application domain is responsible for performing complex computing tasks, such as image processing, deep learning reasoning, and big data processing.
[0051] The control domain mainly contains low-power cores (usually simpler CPU cores). This application domain is used to process system control tasks, simple logical operations, background tasks, etc. These tasks have low performance requirements but strict requirements on power consumption.
[0052] Storage Domain: This domain is responsible for storing and managing data. It usually includes hardware units dedicated to accessing data, such as a memory management unit (MMU) or a dedicated storage accelerator. This domain can work in coordination with other domains to ensure efficient flow of data required for computing tasks.
[0053] The I / O Domain is dedicated to handling communications with external devices, including network data transmission, data collection from external sensors, etc. The task of this domain is usually to manage and schedule external interfaces, such as interacting with other devices through protocols such as USB, Wi-Fi, and Bluetooth.
[0054] The Acceleration Domain contains specific acceleration hardware units, such as a graphics processing unit (GPU), a digital signal processor (DSP), or a dedicated artificial intelligence accelerator (such as an NPU). These hardware units are specifically designed to accelerate specific applications, such as image processing, video decoding, machine learning reasoning, etc.
[0055] Security Domain is used to handle security-related tasks, such as encryption, decryption, authentication, data protection, etc. These tasks are critical to the security of the system, so they are run in an independent domain to avoid conflicts with other domains.
[0056] For example, the first application domain can be any type of control domain, responsible for background tasks and system management; the second application domain can be any type of application domain, and the shared memory corresponding to each second application domain can belong to the storage domain. For another example, the first application domain and the second application domain can belong to the same type of application domain, and each of them can implement the corresponding operations in the embodiments of the present disclosure, and the types of the first application domain and the second application domain are not limited.
[0057] In some embodiments, the first application domain and the second application domain may respectively include or be connected to a FRER functional component, a processing module or a processor, and implement the respective corresponding operations in the embodiments of the present disclosure through the FRER functional component, the processing module or the processor.
[0058] In some embodiments, the system-on-chip further includes: a shared memory corresponding to each of the at least two second application domains; the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain;
[0059] The method further comprises:
[0060] The first application domain sends a first data frame to the shared memory corresponding to each of the second application domains respectively;
[0061] The first application domain sends a first message to each of the at least two second application domains respectively, where the first message is used to indicate a sequence number of a first data frame to be copied.
[0062] Among them, the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain. For example, assuming that there are second application domain 1, second application domain 2, second application domain 3, ..., second application domain n, correspondingly, there are at least shared memory 1, shared memory 2, shared memory 3, ..., shared memory n; among them, shared memory 1 is shared by the first application domain and the second application domain 1, shared memory 2 is shared by the first application domain and the second application domain 2, and so on, shared memory n is shared by the first application domain and the second application domain n.
[0063] It should be noted that there may be other shared memories shared by the two second application domains, thereby achieving data sharing between the two shared application domains.
[0064] The shared memory can be set in the memory inside the SoC, such as SRAM (Static Random-Access Memory), which has the characteristics of fast reading but relatively small memory; the shared memory can also be set in the memory outside the SoC, that is, it does not belong to the inside of the SoC, and can be an external extended memory, such as DDR (Double Data Rate Synchronous Dynamic Random Access Memory), which has the characteristics of relatively slow reading speed but relatively larger memory. The design of the shared memory is not limited here. Of course, the shared memory corresponding to part of the second application domain can also be set inside the SoC, and the shared memory corresponding to part of the second application domain can be set outside the SoC.
[0065] Among them, the first data frame can be a data stream that the user layer needs to send to the receiving end. For example, if the SoC is applied to vehicle-mounted equipment, its user layer includes applications on the SoC system, such as intelligent driving algorithm programs and programs on the vehicle computer (such as maps and chat tools). These applications have interaction requirements when realizing their functions, which will generate data streams that the user layer needs to send to the receiving end.
[0066] After receiving these data streams, the first application domain implements frame replication and sends data frames in conjunction with the second application domain, that is, implements the FRER function of the sending end.
[0067] Specifically, if the method is applied to a transmitting end, the first application domain and at least two second application domains are used to implement frame replication.
[0068] The FRER functional component of the first application domain determines whether the data frame needs to be processed by the FRER software component function, that is, whether frame replication is required, based on the MAC (Media Access Control Address) address, VLAN ID (identifier of virtual local area network), Priority and / or IP (Internet Protocol) address of the data frame of the user layer; if it is determined that the data frame needs frame replication, the first application domain sends the data frame as a copy to the shared memory area corresponding to each second application domain through the memory sharing area unique to the multi-core heterogeneous chip system-level chip and the instant message interaction transmission method based on the Mailbox mechanism (interaction between domains); in this way, the operation of multiple memory data copies is reduced and the efficiency of data frame replication is improved. Each second application domain manages the corresponding network port, and the corresponding network port is connected to an external switch, gateway, etc. through a network cable.
[0069] The first application domain may also send a first message to each second application domain to indicate the sequence number of the first data frame to be copied. After receiving the first message, each second application domain may read the data frame with the corresponding sequence number from its corresponding shared memory to obtain a data frame copy.
[0070] Correspondingly, the data frame copies are encapsulated with an R-tag (redundancy tag) and a unique sequence number. Each second application domain runs a FRER functional component to process the data frame copies in the shared memory with the first application domain, including: identifying the data frames in the shared memory according to the sequence number indicated by the first application domain, determining and obtaining the data frame copies corresponding to the sequence number; each second application domain sends the data frame copies through the network port. Among them, the redundancy tag plays a decisive role in identifying and eliminating duplicate frames at the receiving end.
[0071] In some embodiments, the method further comprises:
[0072] The first application domain receives a data frame from the user layer and determines whether frame replication is required. If frame replication is required, it is determined as the first data frame to be replicated.
[0073] Here, whether frame replication is required may be determined according to the MAC address, VLAN ID, Priority and / or IP address of the data frame.
[0074] Specifically, the MAC address, VLAN ID, Priority and / or IP address of the data frame are identified, and the MAC address, VLAN ID, Priority and / or IP address are matched with preset conditions to determine whether frame replication is required. For example, the conditions may include but are not limited to:
[0075] The MAC address of the data frame is the target MAC address; here, the target MAC address may be a preset specific MAC address, and the number of the target MAC addresses may be one or more;
[0076] The VLAN ID of the data frame belongs to a specific VLAN;
[0077] The priority of the data frame meets a certain condition, for example, high-priority traffic needs to be replicated to multiple ports to ensure high availability;
[0078] The IP address is a specific IP address, for example, an address used for load balancing, network monitoring, etc.
[0079] Of course, the above conditions can be set based on actual conditions, and can also be combined with other information to determine whether frame replication is required. The method for determining whether frame replication is required is not limited here. It should be understood that the setting of the above conditions does not affect the data processing method implemented in the embodiment of the present disclosure.
[0080] In some embodiments, each of the at least two second application domains respectively obtains a duplicate data frame of the first data frame, including:
[0081] In response to the first message sent by the first application domain, each of the second application domains obtains the first data frame from the shared memory corresponding to the second application domain as a copy data frame of the first data frame.
[0082] Specifically, if the method is applied to the sending end, after each second application domain receives the first message, in response to the first message, the second application domain can read the corresponding first data frame from its corresponding shared memory according to the sequence number indicated by the first message, as a copy data frame of the first data frame, that is, a copy of the first data frame.
[0083] For example, assuming that there are second application domain 1, second application domain 2, and second application domain 3, correspondingly, there are at least shared memory 1, shared memory 2, and shared memory 3;
[0084] The first application domain sends the data frame 1 that needs to be copied to shared memory 1, shared memory 2, and shared memory 3 respectively, and the first application domain sends the first message to the second application domain 1, the second application domain 2, and the second application domain 3 respectively, which is used to indicate the sequence number of the data frame 1 to be copied; the second application domain 1, the second application domain 2, and the second application domain 3 read the data frame 1 from their corresponding shared memory 1, shared memory 2, and shared memory 3 respectively, that is, obtain the copied data frame 1, the copied data frame 2, and the copied data frame 3 (that is, the data frame copy) of the data frame 1, and then the copied data frame 1, the copied data frame 2, and the copied data frame 3 obtained can be sent respectively.
[0085] In this way, each second application domain can quickly and efficiently obtain a data frame copy, implement frame replication, improve data frame replication efficiency, and further improve data processing and data transmission efficiency.
[0086] In some embodiments, the system-on-chip further includes: a network port corresponding to each of the at least two second application domains;
[0087] The sending of each of the duplicate data frames comprises:
[0088] Each of the second application domains sends the duplicate data frame through the network port corresponding to the second application domain.
[0089] Specifically, if the method is applied to the sending end, after each second application domain obtains a duplicate data frame of the first data frame, it uses the corresponding managed network port to send the duplicate data frame, thereby achieving redundant transmission.
[0090] For example, assuming that there are second application domain 1, second application domain 2, and second application domain 3, correspondingly, there are at least shared memory 1, shared memory 2, shared memory 3, and network port 1, network port 2, and network port 3;
[0091] The above operation assumes that the second application domain 1, the second application domain 2, and the second application domain 3 respectively obtain the copy data frame 1, the copy data frame 2, and the copy data frame 3 (that is, the data frame copy) of the data frame 1, and then the obtained copy data frame 1, the copy data frame 2, and the copy data frame 3 can be sent respectively, for example, the second application domain 1 sends the copy data frame 1 through the network port 1, the second application domain 2 sends the copy data frame 2 through the network port 2, and the second application domain 3 sends the copy data frame 3 through the network port 3.
[0092] In some embodiments, the system-on-chip further includes: a network port and a shared memory corresponding to each of the at least two second application domains; the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain;
[0093] The method further comprises:
[0094] The second application domain sends a second message to the first application domain, where the second message is used to indicate a sequence number of a second data frame;
[0095] The second application domain sends a second data frame to the shared memory corresponding to the second application domain.
[0096] Specifically, the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain. For example, there are second application domain 1, second application domain 2, second application domain 3, ..., second application domain n, and accordingly, there are at least shared memory 1, shared memory 2, shared memory 3, ..., shared memory n; wherein shared memory 1 is shared by the first application domain and the second application domain 1, shared memory 2 is shared by the first application domain and the second application domain 2, and so on, shared memory n is shared by the first application domain and the second application domain n.
[0097] The network ports corresponding to each second application domain may include: network port 1 corresponding to second application domain 1, network port 2 corresponding to second application domain 2, network port 3 corresponding to second application domain 3, ..., network port n corresponding to second application domain n.
[0098] If the method is applied to the receiving end, after the second application domain receives the second data frame, it sends a second message to the first application domain to indicate the sequence number of the second data frame; and the second application domain sends the second data frame to the shared memory corresponding to the second application domain, so that the first application domain can obtain the second data frame from the shared memory.
[0099] In some embodiments, the first application domain determines a redundant data frame corresponding to the second data frame, including:
[0100] In response to the second message sent by the second application domain, the first application domain obtains a second data frame from a shared memory corresponding to at least one second application domain within a preset time period, and determines a redundant data frame according to a sequence number of the second data frame.
[0101] Here, considering that there are at least two second application domains, there is a situation where a second application domain receives the second data frame first, or two or more second application domains receive the second data frame at the same time, etc. Therefore, a method for determining redundant data frames is provided. Specifically, if a second application domain receives the second data frame, the second application domain sends a second message to the first application domain, and after the first application domain receives the second message, it obtains the second data frame from the shared memory corresponding to the second application domain, and the sequence number of the second data frame is used as the basis, and the data frame with the same sequence number is subsequently determined to be the redundant data frame.
[0102] Here, the preset time period is designed to take into account that if other redundant data frames are still not received after a period of time, it is generally due to network failure and other problems that lead to transmission failure or data frame loss, and they will not be received subsequently. Therefore, the preset time period is designed to judge the redundant data frames of the second data frame only in the preset time period after the first second data frame is received, so as to improve the processing efficiency of the application domain and avoid wasting processing resources due to being in the detection stage for a long time.
[0103] In some embodiments, the deleting the redundant data frame comprises:
[0104] If the first application domain obtains multiple second data frames with the same sequence number, the first obtained second data frame is used, and other redundant data frames with the same sequence number are deleted.
[0105] Here, a method for eliminating redundant data frames is provided. Specifically, if a second application domain receives a second data frame, the second application domain sends a second message to the first application domain. After receiving the second message, the first application domain obtains the second data frame from the shared memory corresponding to the second application domain within a preset time period, and can determine the redundant data frame according to the sequence number of the second data frame;
[0106] Moreover, within a preset time period, if other second application domains also receive a second data frame (which can be understood here as a data frame with the same sequence number as the second data frame) and send a second message to the first application domain, the first application domain will give priority to the second data frame received first and perform corresponding processing to ensure the timeliness of business processing. The second data frames received subsequently are considered to be redundant data frames and are deleted.
[0107] If the preset time period is exceeded, it is considered that other possible redundant data frames may fail to be transmitted due to network failure and will not be received.
[0108] For example, assuming that there are second application domain 1, second application domain 2, and second application domain 3, correspondingly, there are at least shared memory 1, shared memory 2, shared memory 3, and network port 1, network port 2, and network port 3;
[0109] The second application domain 1, the second application domain 2, and the second application domain 3 receive data frames 1, 2, and 3 with the same sequence numbers respectively. They may be received one after the other or one after the other. The following uses this sequential receipt as an example for explanation.
[0110] After the second application domain 1 receives the data frame 1 through the network port 1, it sends the second message 1 to the first application domain to indicate the sequence number of the data frame 1, and sends the data frame 1 to the shared memory 1 corresponding to the second application domain; after the first application domain receives the second message 1, it reads the data frame 1 from the shared memory 1 and performs subsequent business processing. The specific business processing is determined according to the actual situation and is not limited here.
[0111] After receiving the data frame 2 through the network port 2, the second application domain 2 sends a second message 2 to the first application domain to indicate the sequence number of the data frame 2, and sends the data frame 1 to the shared memory 2 corresponding to the second application domain; the sequence number of the data frame 1 is the same as the sequence number of the data frame 2. After receiving the second message 2, the first application domain determines that the data frame 2 is a redundant data frame, and deletes the data frame 2 in the shared memory 2;
[0112] By analogy, after the second application domain 3 receives the data frame 3 through the network port 3, it sends the second message 3 to the first application domain, which is used to indicate the sequence number of the data frame 3, and sends the data frame 3 to the shared memory 3 corresponding to the second application domain; the sequence number of the data frame 1 is the same as the sequence number of the data frame 3. After receiving the second message 3, the first application domain determines that the data frame 3 is a redundant data frame, and deletes the data frame 3 in the shared memory 3.
[0113] In this way, frame elimination of redundant data frames is achieved.
[0114] In some embodiments, the first application domain and the second application domain communicate based on a Mailbox mechanism;
[0115] The first application domain and the shared memory communicate based on a Mailbox mechanism;
[0116] The second application domain and the shared memory communicate based on the Mailbox mechanism.
[0117] Mailbox is a mechanism or data structure used for communication between different processor cores. It can be used to pass messages and trigger events between different processors, cores or hardware modules.
[0118] Mailbox can be viewed as a shared, bidirectional communication interface that contains one or more registers for storing messages or control information. The sender can write messages into the registers of the Mailbox, and the receiver can read these messages and process them accordingly. That is, the sender can control the receiver or instruct the receiver to perform corresponding operations by writing messages or control information into the registers of the Mailbox.
[0119] In semiconductor chips, Mailbox is usually used for communication between processors, such as multi-core processors, system-level chips, or multiple independent functional modules. Through the Mailbox mechanism, different processing units can work together, share data, synchronize operations, and trigger events, thereby achieving more efficient system collaboration and resource sharing.
[0120] It should be noted that the implementation of Mailbox may vary depending on the chip architecture, communication protocol or design requirements, but in general, it exists to achieve reliable and efficient communication and data exchange between processing units.
[0121] The Mailbox mechanism is not only suitable for transmitting instructions, but also for sharing data and sharing memory. The Mailbox mechanism can greatly improve security and speed.
[0122] Figure 3 The following is a schematic diagram showing the implementation process of the data processing method provided by the embodiment of the present disclosure. Figure 2 ;like Figure 3 As shown, the data processing method is applied to a multi-core heterogeneous chip system-on-chip (SoC), and the multi-core heterogeneous chip system-on-chip includes: application domain 1, application domain 2, and application domain 3; application domain 1, application domain 2, and application domain 3 respectively have their corresponding FRER functional components, and the method includes:
[0123] Step 301: When acting as a sending end (ie, a Talker end), frame replication is performed on data frames to be replicated, and the replicated data frames are transmitted.
[0124] and / or,
[0125] Step 302: When serving as a receiving end (ie, Listener end), data frames are received and redundant data frames are eliminated.
[0126] The following combination Figure 4 Step 301 and step 302 are described in detail.
[0127] Specifically, step 301 includes:
[0128] Step 3011, application domain 1 receives the data frame to be sent by the user layer, and the FRER functional component of application domain 1 determines whether the data frame needs to be copied based on the MAC address, VLAN ID, Priority and / or IP address of the data frame; if frame copying is required, go to step 3012, if frame copying is not required, it is directly sent through the network port corresponding to application domain 1; or, if application domain 1 has no corresponding network port, it can also be directly sent through network port 1 corresponding to application domain 2 or network port 2 corresponding to application domain 3; or, if application domain 1 has no corresponding network port, application domain 1 sends the data frame to application domain 2 or application domain 3, and application domain 2 or application domain 3 sends it. Here, application domain 1 can send the data frame to application domain 2 or application domain 3 in the same way as shared memory and Mailbox mechanism, that is, you can refer to the operation of step 3012, the difference is that it is only sent to one of application domain 2 and application domain 3.
[0129] Step 3012: Application domain 1 uses the shared memory area unique to multi-core heterogeneity and the transmission method based on the Mailbox mechanism instant messaging interaction to send the data frame as a copy to the shared memory corresponding to application domain 2 and application domain 3 respectively. Figure 4 As shown, application domain 1 / 2 shares memory, and application domain 1 / 3 shares memory, thus reducing multiple memory data copies.
[0130] Step 3013: Application domain 1 sends a first message to application domain 2 and application domain 3 respectively. In response to the first message, application domain 2 and application domain 3 respectively run their FRER functional components to process the data frame copies of their corresponding shared memory areas.
[0131] Here, application domain 2 and application domain 3 respectively manage the network control (ethernet controller) port, and the network port is connected to the external switch, gateway, etc. through a network cable.
[0132] The first message is used to indicate the sequence number of the data frame to be copied. Application domain 2 and application domain 3 obtain data frame copies from the corresponding shared memory (application domain 1 / 2 shared memory, and application domain 1 / 3 shared memory) according to the sequence number of the data frame to be copied indicated by the first message.
[0133] Application domain 2 and application domain 3 can respectively send the data frame copies they obtain through the network port, such as Figure 4 As shown in the figure, the network port corresponding to application domain 2 is eth-1, and the network port corresponding to application domain 3 is eth-2.
[0134] Specifically, each data frame is encapsulated with an R-tag (redundancy tag) and a unique sequence number (refer to Figure 5), application domain 2 and application domain 3 can respectively identify the data frame and determine the redundant mark and sequence number. The above marks are used to identify and eliminate duplicate frames at the receiving end.
[0135] Figure 5 The figure is a format diagram of a FRER processing frame type, where Ethertype is a field in the Ethernet frame header used to indicate the data type of the upper layer protocol. It is a 16-bit field and is usually used to identify the protocol type, such as IPv4, IPv6 or ARP and other Ethernet types.
[0136] Sequence number represents the sequence number required by FRER to process data frames. The sequence number is a number used to uniquely identify data frames. It is usually an increasing number to ensure that each data frame has a unique identifier. The sender will embed a sequence number in each data frame so that the receiver can process the data. In the FRER protocol, SequenceNumber plays a key role, including but not limited to: the receiver can determine the order of data frames based on the sequence number and reassemble the data; the receiver can detect duplicate frames through the sequence number. If a frame with the same sequence number is received, the receiver can discard it to avoid repeated processing; if a data frame does not arrive in order, the receiver can determine the lost frame based on the sequence number and request retransmission.
[0137] R-TAG format is a field in the FRER protocol used to identify and determine data segments. The specific format and content of this field can be customized as needed to adapt to different networks or application scenarios.
[0138] like Figure 5 As shown, the R-TAG format may specifically include the following reserved fields: Sub-type, used to identify the specific type or subcategory of the data frame, such as a data frame or a control frame; Protocol version, used to identify the version of the FRER protocol to ensure protocol compatibility; Flags, including multiple control flags, used to indicate the characteristics of the frame or special processing requirements, such as whether confirmation is required, whether it is a retransmission frame, etc.
[0139] Flags may include control information related to data transmission, such as the source and destination of a data frame, or reliability requirements of a frame; for example, the flags may include information such as a MAC address, a VLAN ID, a Priority, and / or an IP address.
[0140] Through R-TAG, the receiver can better identify and process specific fragments to ensure the correct assembly and order of data. For example, the receiver can determine whether the frame is a lost data fragment or a duplicate fragment through R-TAG, and make corresponding processing.
[0141] In addition, it should be noted that in the FRER protocol, each octet of a frame can carry different control information, addresses, flags or other protocol fields. By using these octet indexes, the sender and receiver can ensure that the data frame is correctly parsed and processed.
[0142] Specifically, step 302 includes: application domain 2 and application domain 3 of management network ports eth-1 and eth-2 can respectively receive data frames through corresponding network ports; after receiving the data frames, the FRER functional components of application domain 2 and application domain 3 will identify the data frames, check the serial numbers, send the received data frames to the corresponding shared memory and send a second message to application domain 1, the second message is used to indicate the serial numbers of the data frames that need to be eliminated; application domain 1 identifies the data frames with duplicate serial numbers and discards them, that is, application domain 2 or application domain 3 only retains one copy of the data frame, and application domain 1 transmits it to the user layer of application domain 1 in real time through memory sharing, thereby ensuring the consistency and integrity of the data.
[0143] Here, application domain 2 and application domain 3 may receive data frames in an interrupt mode, that is, other SoCs or devices send data through the physical network port. For example, when eth2 receives a data frame, the FRER functional component of application domain 2 determines whether the data frame is a data frame copied by the FRER frame according to the R-TAG of the data frame.
[0144] If it is a data frame copied by the FRER frame, it is marked as requiring frame elimination. Application domain 2 gives the data frame to application domain 1 through shared memory and informs the sequence number at the same time. After receiving it, application domain 1 asks application domain 3 whether it has received the data frame with this sequence number within a certain period of time. If application domain 3 does not receive the data frame with this sequence number until the timeout, it is considered that application domain 3 is disconnected from the network. If application domain 3 also receives the data frame with the same sequence number as application domain 2, the data frame received later will be deleted, that is, the frame elimination of the redundant data frame will be completed. Of course, if application domain 3 receives the data frame copied by the FRER frame, and application domain 1 has not asked, application domain 3 can also actively inform application domain 1, and application domain 1 will perform frame elimination related operations.
[0145] If it is not a data frame copied by the FRER frame, application domain 2 can directly send it to application domain 1, and application domain 1 will perform subsequent corresponding business processing. Here, application domain 2 can give the data frame to application domain 1 through shared memory and inform the sequence number at the same time. After receiving the data frame, application domain 1 will perform subsequent corresponding business processing.
[0146] It should be noted that if the network port has the function of determining whether the data frame is a data frame copied from the FRER frame based on the R-TAG of the data frame, then when it determines that the received data frame is not a data frame copied from the FRER frame, the network port can directly send the data frame to application domain 1, and application domain 1 will perform subsequent corresponding business processing.
[0147] In the disclosed embodiment, application domain 1 is used as the network application layer data endpoint, and other application domains 2 and 3 are used as redundant paths for FRER processing. In the disclosed embodiment, the implementation of FRER utilizes the high performance requirements of SoC, so that application domain 1 releases a large amount of FRER processing processes and resources, and achieves low latency and high reliability of redundant links.
[0148] It should be noted that Figure 4 In the example, application domain 2 and application domain 3 are equivalent to Figure 2 The second application domain in the method shown can have more second application domains in actual application, such as application domain n, and the shared memory area is increased accordingly, such as the memory shared by application domain 1 and application domain n. In addition, application domain n can also control an Ethernet port, that is, the number of ports corresponds to the number of second application domains.
[0149] Figure 6 A schematic diagram of the structure of data processing provided by an embodiment of the present disclosure is shown; Figure 6 As shown, the device includes a system-level chip applied to the system-level chip, the system-level chip includes a first application domain and at least two second application domains; the device includes: a first processing module for the first application domain, and a second processing module for each of the second application domains;
[0150] The second processing module is configured to obtain a duplicate data frame of the first data frame and send each of the duplicate data frames if the first application domain determines the first data frame to be duplicated; and / or
[0151] The first processing module is configured to determine a redundant data frame corresponding to the second data frame and delete the redundant data frame if a second application domain among the at least two second application domains receives a second data frame to be de-redundant.
[0152] In some embodiments, the system-on-chip further includes: a shared memory corresponding to each of the at least two second application domains; the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain;
[0153] The first processing module is further used to send the first data frame to the shared memory corresponding to each second application domain respectively;
[0154] A first message is sent to each of the at least two second application domains respectively, where the first message is used to indicate a sequence number of a first data frame to be copied.
[0155] In some embodiments, the second processing module of each of the at least two second application domains is used to obtain the first data frame from the shared memory corresponding to the second application domain in response to the first message sent by the first application domain as a copy data frame of the first data frame.
[0156] In some embodiments, the system-on-chip further includes: a network port corresponding to each of the at least two second application domains;
[0157] The second processing module of each second application domain is used to send the copied data frame through the network port corresponding to the second application domain.
[0158] In some embodiments, the system-on-chip further includes: a network port and a shared memory corresponding to each of the at least two second application domains; the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain;
[0159] The second processing module is further used for:
[0160] Sending a second message to the first application domain, where the second message is used to indicate a sequence number of a second data frame;
[0161] Send a second data frame to the shared memory corresponding to the second application domain.
[0162] In some embodiments, the first processing module is used to obtain a second data frame from a shared memory corresponding to at least one second application domain within a preset time period in response to a second message sent by the second application domain, and determine a redundant data frame according to a sequence number of the second data frame.
[0163] In some embodiments, the first processing module is used to use the first acquired second data frame and delete other redundant data frames with the same sequence number if the first application domain acquires multiple second data frames with the same sequence number.
[0164] In some embodiments, the first application domain and the second application domain communicate based on a Mailbox mechanism;
[0165] The first application domain and the shared memory communicate based on a Mailbox mechanism;
[0166] The second application domain and the shared memory communicate based on the Mailbox mechanism.
[0167] It should be noted that the second application domain is at least two. Figure 6 An example of a second application domain is given in the embodiment, rather than limiting the number of second application domains. It can be understood that when the data processing device provided in the above embodiment implements the corresponding data processing method, the above processing can be assigned to different program modules as needed to complete all or part of the processing described above. In addition, the device provided in the above embodiment and the embodiment of the corresponding method belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.
[0168] The embodiment of the present disclosure also provides a component on a traffic device, wherein the component includes a chip, and the chip can execute the above-mentioned data processing method.
[0169] In some embodiments, the components may be circuit board-level components, automotive electrical system-level components, or automotive assembly components. As an example, the components may be the engine, chassis, body, and electrical and electronic equipment of the vehicle. The electrical and electronic equipment of the vehicle may include headlights for lighting, management equipment for controlling the engine, and central control equipment for receiving broadcasts, navigation, listening to music, and entertainment.
[0170] The embodiment of the present disclosure also provides a transportation device, the transportation device includes a chip, and the chip can execute the above data processing method. The chip can be a multi-core heterogeneous chip, and the transportation device includes but is not limited to a balance car, a car, a bus, a train, etc.
[0171] An embodiment of the present disclosure provides a computer-readable storage medium storing executable instructions, wherein the executable instructions are stored. When the executable instructions are executed by a processor, the processor will be triggered to execute the data processing method provided by the embodiment of the present disclosure.
[0172] In some embodiments, the computer-readable storage medium may be a ferroelectric random access memory (FRAM), a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), a flash memory, a magnetic surface memory, an optical disk, or a CD-ROM; it may also be various devices including one or any combination of the above memories.
[0173] In some embodiments, executable instructions may be in the form of a program, software, software module, script or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, model, subroutine or other unit suitable for use in a computing environment.
[0174] By way of example, executable instructions may be deployed to be executed on one computing device, or on multiple computing devices located at one site, or on multiple computing devices distributed across multiple sites and interconnected by a communication network.
[0175] An embodiment of the present disclosure provides a computer program product, which includes a computer program / instructions. When the computer program / instructions are executed by a processor, the data processing method described in the present disclosure is implemented.
[0176] Figure 7 A schematic diagram of the structure of an electronic device according to an embodiment of the present disclosure is shown. Figure 7 As shown, the electronic device 70 includes: a processor 701 and a memory 702 for storing a computer program that can be run on the processor; when the processor 701 is used to run the computer program, it executes the data processing method provided by the embodiment of the present disclosure.
[0177] In actual application, the electronic device 70 may further include: at least one network interface 703. The various components in the electronic device 70 are coupled together via a bus system 704. It is understood that the bus system 704 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 704 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, Figure 7 In the figure, various buses are marked as bus system 704. There may be at least one processor 701. The network interface 703 is used for wired or wireless communication between the electronic device 70 and other devices.
[0178] The memory 702 in the embodiment of the present disclosure is used to store various types of data to support the operation of the electronic device 70 .
[0179] The method disclosed in the above-mentioned embodiment of the present disclosure can be applied to the processor 701, or implemented by the processor 701. The processor 701 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above-mentioned method can be completed by the hardware integrated logic circuit in the processor 701 or the instruction in the form of software. The above-mentioned processor 701 can be a general-purpose processor, a digital signal processor (DSP, DiGital Signal Processor), or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. The processor 701 can implement or execute the disclosed methods, steps and logic block diagrams in the embodiment of the present disclosure. The general-purpose processor can be a microprocessor or any conventional processor, etc. The steps of the method disclosed in the embodiment of the present disclosure can be directly embodied as a hardware decoding processor to execute, or the hardware and software modules in the decoding processor can be combined to execute. The software module can be located in a storage medium, which is located in the memory 702. The processor 701 reads the information in the memory 702 and completes the steps of the above-mentioned method in combination with its hardware.
[0180] In some embodiments, the electronic device 70 can be implemented by one or more application specific integrated circuits (ASIC), DSP, programmable logic device (PLD), complex programmable logic device (CPLD), field programmable gate array (FPGA), general processor, controller, microcontroller (MCU), microprocessor, or other electronic components to execute the aforementioned method.
[0181] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0182] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of the present disclosure, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0183] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0184] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of the present disclosure, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0185] The above is only a specific embodiment of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any person skilled in the art who is familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present disclosure, which should be included in the protection scope of the present disclosure. Therefore, the protection scope of the present disclosure should be based on the protection scope of the claims.
Claims
1. A data processing method, characterized in that: The method is applied to a system-on-chip (SoC), wherein the system-on-chip includes a first application domain and at least two second application domains; the method includes: If the first application domain determines a first data frame to be copied, each of the at least two second application domains respectively obtains a copy data frame of the first data frame and sends each of the copy data frames; and / or, If a second application domain among the at least two second application domains receives a second data frame whose redundancy is to be eliminated, the first application domain determines a redundant data frame corresponding to the second data frame, and deletes the redundant data frame.
2. The method according to claim 1, characterized in that The system-level chip further includes: a shared memory corresponding to each of the at least two second application domains; the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain; The method further comprises: The first application domain sends a first data frame to the shared memory corresponding to each of the second application domains respectively; The first application domain sends a first message to each of the at least two second application domains respectively, where the first message is used to indicate a sequence number of a first data frame to be copied.
3. The method according to claim 1 or 2, characterized in that: Each of the at least two second application domains respectively obtains a duplicate data frame of the first data frame, including: In response to the first message sent by the first application domain, each of the second application domains obtains the first data frame from the shared memory corresponding to the second application domain as a copy data frame of the first data frame.
4. The method according to claim 1, characterized in that The system-level chip also includes: a network port corresponding to each of the at least two second application domains; The sending of each of the duplicate data frames comprises: Each of the second application domains sends the duplicate data frame through the network port corresponding to the second application domain.
5. The method according to claim 1, characterized in that The system-level chip further includes: a network port and a shared memory corresponding to each of the at least two second application domains; the shared memory corresponding to each of the second application domains is shared by the second application domain and the first application domain; The method further comprises: The second application domain sends a second message to the first application domain, where the second message is used to indicate a sequence number of a second data frame; The second application domain sends a second data frame to the shared memory corresponding to the second application domain.
6. The method according to claim 1 or 5, characterized in that: The first application domain determines a redundant data frame corresponding to the second data frame, including: In response to the second message sent by the second application domain, the first application domain obtains a second data frame from a shared memory corresponding to at least one second application domain within a preset time period, and determines a redundant data frame according to a sequence number of the second data frame.
7. The method according to claim 1, characterized in that The deleting the redundant data frame comprises: If the first application domain obtains multiple second data frames with the same sequence number, the first obtained second data frame is used, and other redundant data frames with the same sequence number are deleted.
8. The method according to claim 1, 2 or 5, characterized in that: The first application domain and the second application domain communicate with each other based on a Mailbox mechanism; The first application domain and the shared memory communicate based on a Mailbox mechanism; The second application domain and the shared memory communicate based on the Mailbox mechanism.
9. A data processing device, characterized in that: The device includes a system-on-chip (SoC) application, wherein the system-on-chip includes a first application domain and at least two second application domains; the device includes: a first processing module for the first application domain, and a second processing module for each of the second application domains; The second processing module is configured to obtain a duplicate data frame of the first data frame and send each of the duplicate data frames if the first application domain determines the first data frame to be duplicated; and / or The first processing module is configured to determine a redundant data frame corresponding to the second data frame and delete the redundant data frame if a second application domain among the at least two second application domains receives a second data frame to be de-redundant.
10. A component of a traffic device, characterized in that: The component comprises a system-level chip, and the system-level chip can implement the method according to any one of claims 1 to 8.
11. A traffic device, characterized in that: The traffic equipment comprises a system-level chip, and the system-level chip can implement the method according to any one of claims 1 to 8.
12. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 8.
13. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to make a computer execute the method according to any one of claims 1 to 8.