Scheduling method and communication apparatus
By configuring scheduling priority for the output stream, ensuring high priority transmission of audio and video service streams, the problem of large delay of audio and video service streams in the prior art is solved, and low-latency and efficient service stream transmission is achieved.
Patent Information
- Application Number
- PCT/CN2023/135742
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2023-11-30
- Publication Date
- 2025-06-05
AI Technical Summary
In the prior art, when scheduling with audio and video, service flows such as audio and video, which require delay guarantees, are easily affected by link management service flow and network management service flow, resulting in large transmission delays.
A scheduling method is proposed to ensure that the Transmission Layer Data Message (TLDP) of Audio and Video has the highest priority, independent of the impact of other output streams and management service streams. The method includes weighted polling scheduling and strict priority scheduling to ensure low latency transmission of audio and video traffic streams.
It effectively reduces the transmission delay of service streams such as audio and video that need delay guarantee, improves user experience, and avoids the delay impact on link management and network management service streams.
Smart Images

Figure CN2023135742_05062025_PF_FP_ABST
Abstract
Description
Scheduling method and communication device Technical Field
[0001] The present application relates to the field of media technology, and in particular to a scheduling method and a communication device. Background Art
[0002] When multiple service flows are transmitted through the same device port, the device needs to perform bandwidth scheduling management for each service flow. Bandwidth scheduling management can be understood as the priority management and bandwidth management of the messages of the service flows to be sent.
[0003] The various service flows can be broadly divided into three categories: link management service flows, network management service flows, and general service flows. During priority management, general service flows are prioritized lower than those of link management service flows and network management service flows. Therefore, when delay-required service flows, such as audio and video, are included in general service flows, they will be impacted by link management service flows and network management service flows when they participate in priority scheduling. This can lead to longer message transmission delays for these delay-required service flows.
[0004] Summary of the Invention
[0005] The embodiments of the present application provide a scheduling method and a communication device that can reduce the transmission delay of business flows such as audio and video that require delay guarantee requirements.
[0006] In a first aspect, a scheduling method is provided, the method comprising: configuring a scheduling priority for each of a plurality of output streams transmitted by a first output port, the plurality of output streams comprising at least one first output stream, the first output stream comprising a transport layer data packet TLDP for video and audio, the scheduling priority of the TLDP for video and audio being a first priority, the first priority being the highest priority among the scheduling priorities of the plurality of output streams and a second output stream, the second output stream comprising a transport layer management data packet TLMDP; scheduling the plurality of output streams and the second output stream according to the scheduling priority configured for each of the plurality of output streams.
[0007] This method can be applied to a communication device, which can be understood as an interface device. The first output port can be one of multiple physical ports of the communication device. The communication device can configure a priority for each message of an output flow transmitted to each of the multiple output ports of the communication device, including the first output port. In some scenarios, the first output port can not only send messages but also receive messages.
[0008] Thus, compared to the existing method of transmitting all common service flows including audio and video service flows after the network management service flow, which results in a large transmission delay of the audio and video service flows, the present application, when scheduling the messages of multiple output flows, has a higher priority for the TLDP of audio and video among the multiple output flows than the priority of the messages of other output flows, and also higher than the priority of TLMDP. Thus, when scheduling the output flows, the scheduling delay of the TLDP of audio and video is not affected by the delay of TLMDP. TLMDP can be understood as a message of the management service flow, which is equivalent to not being affected by the delay of the network management service flow. The TLDP of audio and video is also not affected by the output flows of other priorities except the first priority among the messages of the multiple output flows, and the transmission delay of the TLDP of audio and video is relatively low.
[0009] In one possible embodiment, the method further includes: performing weighted round-robin scheduling on output streams of the same priority among the multiple output streams; and scheduling the multiple output streams and the second output stream according to the scheduling priority configured for each of the multiple output streams includes: performing strict priority scheduling on the multiple output streams and the second output stream according to the output of the weighted round-robin scheduling of the output streams of the same priority among the multiple output streams. In this way, after weighted round-robin scheduling and strict priority scheduling, the transmission delay of the TLDP of the video and audio is not affected by the delay of TLMDP or the delay of messages of other output streams among the multiple output streams except the first output stream, thereby reducing the transmission delay of the TLDP of the video and audio.
[0010] In one possible embodiment, the scheduling priority of the TLMDP is the second priority, and the scheduling priority of output flows other than the second output flow is a priority other than the second priority. In other words, only the packets of the second output flow, namely the TLMDP, have the second priority. Thus, when transmitting the second output flow, the transmission of the TLMDP of the second output flow is not affected by other packets other than the TLMDP, resulting in a lower transmission delay for the TLMDP.
[0011] In one possible embodiment, among the scheduling priorities of the multiple output flows, priorities other than the first priority and the second priority are lower than the second priority. This means that the priority of the TLMDP is higher than the priorities of the other output flows except the first output flow. During transmission of the TLMDP, the TLMDP is not affected by the other output flows except the first output flow, and the transmission delay of the TLMDP is low.
[0012] In one possible embodiment, configuring a scheduling priority for messages in each of the multiple output flows transmitted by the first output port includes configuring outbound flow scheduling information for each output virtual channel of the first output port, the outbound flow scheduling information including priority information for the output virtual channel, the priority information being used to indicate the scheduling priority of the output flow corresponding to the output virtual channel. This is equivalent to ensuring that messages in the same output flow have the same output virtual channel. Thus, configuring outbound flow scheduling information for each output virtual channel is equivalent to configuring a priority for the messages in each output flow, allowing the communication device to schedule the output flows according to the priority of the messages in the output flows.
[0013] In one possible embodiment, different output virtual channels of the first output port correspond to different output flows. Thus, when scheduling multiple output flows, the communication device can determine the priorities of messages corresponding to the output flows according to the flow scheduling information configured for the output virtual channels, thereby scheduling the multiple output flows according to the priorities of the messages of different output flows.
[0014] In a possible embodiment, the TLMDP is transmitted on the first output virtual channel, or in other words, the TLMDP is fixedly transmitted on the first output virtual channel.
[0015] In a possible embodiment, the method further includes: performing strict priority scheduling on the transport layer common management message TLCMP, where TLCMP includes a transport layer credit recovery message TLCRP; wherein, when the scheduling priority of TLCRP is the third priority and the scheduling priority of messages other than TLCRP in TLCMP is the fourth priority, the third priority is higher than the first priority, the fourth priority is lower than the first priority, and the fourth priority is higher than the second priority.
[0016] Therefore, when strict priority scheduling is performed for packets from multiple output flows, secondary output flows, and link management service flows, the scheduling order, from highest to lowest priority, is as follows: TLCRP of third priority; packets outputted using WRR scheduling within the first priority level; packets of fourth priority (i.e., packets in TLCMP other than TLCRP); TLMDP of second priority; and packets of output flows with other priorities other than the first and second priorities. This is because TLCRP is used by the TLDP receiver to notify the TLDP sender of the number of credits it has reclaimed. Credits are used to track the RBuff buffer space on the receiving end and determine whether the receiver has enough space to buffer the TLDP (data service flow) to ensure that the RBuff on the link receiving end does not overflow. Therefore, TLCRP, which requires a shorter transmission delay and is a delay-sensitive link management message, can be configured as the third priority, higher than the first priority level of the audio and video TLDP. In this way, when TLCMP participates in strict priority scheduling, the transmission delay of TLCRP in TLCMP is shorter and is not affected by the delay of TLDP of video and audio, messages other than TLCRP in TLCMP, TLMDP, and messages other than TLDP of video and audio in multiple output streams.
[0017] In one possible embodiment, messages other than TLCRP in TLCMP include at least one of the following: a transport layer credit allocation message (TLCAP), a transport layer credit allocation acknowledgment message (TLCAP_ACK), a transport layer credit consumption message (TLCCP), and a transport layer flow control exception notification message (TLFCENP). That is, compared to the transmission delay required by TLCRP, the transmission delay of messages other than TLCRP in TLCMP can be relatively long, and they can be considered delay-insensitive link management messages. The transmission delay of TLDP for audio and video is also unaffected by the transmission delay of messages other than TLCRP in TLCMP, and therefore the transmission delay of TLDP for audio and video is relatively low.
[0018] In one possible embodiment, the outbound flow scheduling information also includes weight information, which indicates the scheduling weight of the output flows corresponding to the output virtual channel when weighted round-robin scheduling is performed at the same priority level. In other words, when output flows of the same message type or service type are assigned the same priority level, the output flows of the same message type can be scheduled based on the weight information. This ensures that the benefits of higher-weighted messages are maximized.
[0019] In one possible embodiment, performing weighted round-robin scheduling on output flows of the same priority among multiple output flows includes performing weighted round-robin scheduling on the output flows of the same priority on a message-by-message basis based on weight information of the output flows corresponding to the output virtual channels of the same priority among the multiple output flows. In other words, when scheduling each output flow, multiple consecutive messages may be scheduled on a message-by-message basis based on the weight information.
[0020] In one possible embodiment, the number of packets scheduled during weighted round-robin scheduling of a third output flow among multiple output flows is proportional to the weight of the third output flow, where the third output flow is any output flow among the multiple output flows. This allows for a higher number of packets to be scheduled for output flows with the same priority level, thereby ensuring the benefits of the higher-weighted packets.
[0021] In a possible embodiment, the total number of priorities configured for the messages of the multiple output flows and the second output flow is 8. Of course, the present application does not limit the total number of priorities to 8, and it can also be more than 8 or less than 8.
[0022] In a second aspect, a communication device is provided, including: a configuration module for configuring a scheduling priority for each of a plurality of output streams transmitted by a first output port, the plurality of output streams including at least one first output stream, the first output stream including a transport layer data message TLDP for video and audio, the priority of the TLDP for video and audio being a first priority, the first priority being the highest priority among the priorities of the messages of the plurality of output streams and the second output stream, the second output stream including a transport layer management data message TLMDP; a scheduling module for scheduling the plurality of output streams and the second output stream according to the scheduling priority configured for each of the plurality of output streams.
[0023] In a possible embodiment, the scheduling module is also used to: perform weighted round-robin scheduling on output streams of the same priority among multiple output streams; the scheduling module is used to perform strict priority scheduling on multiple output streams and the second output stream based on the scheduling priorities of the multiple output streams and the second output stream, and the output of the weighted round-robin scheduling of output streams of the same priority among the multiple output streams.
[0024] The beneficial effects of the second aspect can be found in the description of the first aspect.
[0025] In a possible embodiment, the scheduling priority of the TLMDP is the second priority, and the scheduling priorities of output flows other than the second output flow are priorities other than the second priority.
[0026] In a possible embodiment, among the scheduling priorities of the multiple output flows, priorities other than the first priority and the second priority are lower than the second priority.
[0027] In a possible embodiment, the configuration module is used to: configure outbound flow scheduling information for each output virtual channel of the first output port, the outbound flow scheduling information includes priority information of the output virtual channel, and the priority information is used to indicate the scheduling priority of the output flow corresponding to the output virtual channel.
[0028] In a possible embodiment, different output virtual channels of the first output port correspond to different output flows.
[0029] In a possible embodiment, the TLMDP is transmitted on the first output virtual channel.
[0030] In a possible embodiment, the scheduling module is also used to: perform strict priority scheduling on the transport layer common management message TLCMP, TLCMP includes the transport layer credit recovery message TLCRP; wherein, when the scheduling priority of TLCRP is the third priority and the scheduling priority of messages other than TLCRP in TLCMP is the fourth priority, the third priority is higher than the first priority, the fourth priority is lower than the first priority, and the fourth priority is higher than the second priority.
[0031] In a possible embodiment, the messages other than TLCRP in TLCMP include at least one of a transport layer credit allocation message TLCAP, a transport layer credit allocation response message TLCAP_ACK, a transport layer credit consumption message TLCCP, and a transport layer flow control exception notification message TLFCENP.
[0032] In a possible embodiment, the outbound flow scheduling information further includes weight information, where the weight information is used to indicate a scheduling weight when weighted round-robin scheduling is performed on output flows corresponding to the output virtual channels at the same priority level.
[0033] In a possible embodiment, the scheduling module is further configured to perform weighted round-robin scheduling on the output flows of the same priority in units of packets according to weight information of the output flows corresponding to the output virtual channels of the same priority among the multiple output flows.
[0034] In a possible embodiment, when weighted round-robin scheduling is performed on a third output flow among the multiple output flows, the number of packets is proportional to the weight of the third output flow, and the third output flow is any output flow among the multiple output flows.
[0035] In a possible embodiment, the total number of priorities configured for the messages of the multiple output flows and the second output flow is 8.
[0036] According to a third aspect, a communication device is provided, comprising a module for executing the method according to the first aspect and any possible embodiment of the first aspect.
[0037] In a fourth aspect, a communication device is provided, comprising a processor and a memory, wherein the processor and the memory are coupled, and the processor is used to run a computer program or instruction stored in the memory so that the communication device executes the method described in the first aspect and any possible embodiment of the first aspect.
[0038] In a fifth aspect, a communication system is provided, comprising a first communication device and a second communication device, wherein the first communication device executes the method in the first aspect and any possible embodiment of the first aspect, and a communication connection is established between the first communication device and the second communication device.
[0039] In a sixth aspect, a computer-readable storage medium is provided, in which computer instructions are stored. When the computer instructions are executed on a communication device, the communication device executes a method as in the first aspect and any possible embodiment of the first aspect.
[0040] In a seventh aspect, a computer program product is provided, comprising computer instructions, which, when executed on a communication device, cause the communication device to execute the method of the first aspect and any possible embodiment of the first aspect.
[0041] In an eighth aspect, a chip is provided, which stores computer-executable instructions. When the computer-executable instructions are executed, the method of the first aspect and any possible design embodiment of the first aspect is executed. BRIEF DESCRIPTION OF THE DRAWINGS
[0042] FIG1 is a schematic diagram of the architecture of a communication system for direct connection between devices provided in an embodiment of the present application;
[0043] FIG2 is a schematic diagram of basic components of an electronic device 20 provided in an embodiment of the present application;
[0044] FIG3 is a schematic diagram of an inter-interface transmission provided in an embodiment of the present application;
[0045] FIG4 is a schematic diagram of a protocol stack structure for data transmission between devices via a link according to an embodiment of the present application;
[0046] FIG5 is a flow chart of a scheduling method provided in an embodiment of the present application;
[0047] FIG6 is a schematic diagram of a transport layer message forwarding model of a unified multimedia interconnection router provided in an embodiment of the present application;
[0048] FIG7 is a schematic diagram of a virtual channel provided in an embodiment of the present application;
[0049] FIG8 is a flow chart of a scheduling method provided in an embodiment of the present application;
[0050] FIG9 is a schematic diagram of a framework of a link transmission adapter of a unified multimedia interconnection physical port provided in an embodiment of the present application;
[0051] FIG10 is a schematic diagram of a flow chart of a scheduling method provided in an embodiment of the present application;
[0052] FIG11 is a schematic diagram of a bandwidth manager performing secondary scheduling according to an embodiment of the present application;
[0053] [Corrected 02.01.2024 according to Rule 91] FIG12 is a schematic diagram of a video and audio transmission scenario provided by an embodiment of the present application;
[0054] [Corrected 02.01.2024 according to Rule 91] FIG13 is a schematic diagram of a bandwidth manager performing secondary scheduling according to an embodiment of the present application;
[0055] [Corrected 02.01.2024 according to Rule 91] FIG14 is a schematic diagram of the structure of a communication device provided in an embodiment of the present application; [0055.1][Corrected 02.01.2024 according to Rule 91] Figure 15 is a structural diagram of a communication device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0056] The technical solutions in the embodiments of the present application will be described below in conjunction with the accompanying drawings in the embodiments of the present application. In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in this article is merely a description of the association relationship of associated objects, indicating that three relationships can exist, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "multiple" means two or more than two.
[0057] In the following, the terms "first" and "second" are used for descriptive purposes only and should not be understood to indicate or imply relative importance or implicitly specify the number of the technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this embodiment, unless otherwise specified, "plurality" means two or more.
[0058] The embodiments of the present application can be used in scenarios where signals are transmitted between devices. Devices can be connected directly to each other, or connections between multiple devices can be completed through routing devices. Signals can be transmitted (sent and received) between devices in a wired manner, or in a wireless manner. Signals can be transmitted directly between devices, or between devices through an interface device, and the signal can be transmitted to the processing unit inside the device through a bus within the device.
[0059] For example, FIG1(a) shows a schematic diagram of the architecture of a communication system 10a in which devices are directly connected. Devices 101 and 102, and interface 1011 in device 101 and interface 1021 in device 102, are connected via a cable to enable signal transmission between devices 101 and 102, such as audio and video data transmission and short-distance transmission of charging signals. For example, as shown in FIG1(a), device 101 is a set-top box and device 102 is a television. Audio and video data are transmitted between the interfaces of the set-top box and the television via a cable. Alternatively, device 101 is a display and device 102 is a game controller. Control information is transmitted between the interfaces of the display and the game controller via a cable.
[0060] Figure 1 (b) shows a schematic diagram of the architecture of a communication system 10b in which devices are connected via a routing device. Devices 103 to 105 are all connected to a routing device 106 via cables, and the interfaces between devices can transmit signals through the routing device, such as the transmission of audio and video data and short-distance transmission of charging signals. In this scenario, the interface of each device is connected to the interface of the routing device, and the signals transmitted between the interfaces of the devices must be transmitted through the interface of the routing device. For example, device 103 is a display, device 104 is a set-top box, and device 105 is an audio player. The interface of the set-top box 104 transmits audio and video data to the interface of the routing device 106, and the interface of the routing device 106 transmits audio and video data to the interface of the display 103. Alternatively, the interface of the display 103 transmits audio data to the interface of the audio player 105 via the interface of the routing device 106.
[0061] In the two communication systems described above, the devices interconnected by the interfaces can be various electronic devices, such as personal computers, laptops, mobile phones, digital cameras, digital televisions, audio equipment, DVD players, set-top boxes, game consoles, printers, mice, keyboards, and household appliances. The transmitted signals can include audio signals, video signals, Internet data, IoT data, and charging signals.
[0062] To meet various signal transmission requirements, the industry has defined various interface specifications for inter-device signal transmission, such as the Universal Serial Bus (USB), High Definition Multimedia Interface (HDMI), DisplayPort (DP), Unified Multimedia Interconnection (UMMI), and Peripheral Component Interconnect Express (PCI-Express). Accordingly, interfaces may include HDMI, miniHDMI, micro HDMI, Type-A, Type-B, Micro-B, and Type-C.
[0063] For example, in the above-mentioned short-distance transmission scenario interconnected by cables, the interface connection between the set-top box / speaker and the TV, or the interface connection between the game console and the TV, is connected through a USB cable, and the interface standard followed is the USB interface specification, or the connection method is connected through an HDMI cable, and the interface standard followed is the HDMI interface specification, or the connection method is connected through a DP cable, and the interface standard followed is the DisplayPort interface specification.
[0064] The embodiment of the present application also provides another interface standard that can replace the above-mentioned interface standards (such as USB interface or HDMI interface): unified multimedia interconnecter (UMI) interface. The unified multimedia interconnect interface can not only adapt and transmit data, but also realize the charging function. Of course, the unified multimedia interconnect interface can also be other interface names. When the unified multimedia interconnect interface is replaced with other interface names, the other interface can be used to realize the functions of the unified multimedia interconnect interface in this application.
[0065] In this application, the unified multimedia interconnection interface also supports direct connection between devices, or multi-device networking connection (for example, devices are connected through routing devices, or devices are connected through docking stations). The device can be any electronic device or component. When the device is an electronic device, the electronic device is, for example, a personal computer, a display, an audio and video device, a digital device, a printer, a router, a game console, and a vehicle-mounted device, and the electronic device includes a unified multimedia interconnection interface. When the device is a component, the component can be understood as any interface device (interface device / interface device), and the interface device is the unified multimedia interconnection interface.
[0066] In this application, devices can transmit (send and receive) signals via wired or wireless means. Devices can transmit signals directly to each other, or they can transmit signals between devices through an interface device (such as an interface device of a router) and then transmit them to the processing unit within each device via a bus.
[0067] When the devices are electronic devices, they can be interconnected through their unified multimedia interconnection interfaces, similar to the scenario shown in (a) of Figure 1. For example, the unified multimedia interconnection interfaces of a set-top box and a television can be interconnected via cables for signal transmission.
[0068] When the device is an interface device, it can be a chip, i.e., the chips are interconnected, and the chip can be an interface chip on an electronic device / cable / docking station / adapter / router. The docking station can be connected to a Gigabit Ethernet port, a video graphics array (VGA) port, an HDMI port, a TF card (trans-flash card), an SD card (secure digital memory card), a charging port, and a USB port, among others.
[0069] In this application, when the device is a chip, the chip may include an interface module. This means that this application can be applied to the interface module that interconnects two chips. This interface module can be understood as an IP integrated within the chip. Alternatively, the interface module can be sold separately as an independent IP.
[0070] For example, when the chip is a system on chip (SoC), a central processing unit (CPU), or a graphics processing unit (GPU), the present application can be applied to the interface modules of chips such as SoC, CPU, and GPU. When the chip is a small chip such as a die, the interface module can be understood as the transmitting circuit and / or receiving circuit in the die. The chip can also be an input / output (I / O) die that only includes interface functions.
[0071] In this application, when the device is an electronic device, FIG2 shows a schematic diagram of the basic components of an electronic device 20. The electronic device 20 includes an interface chip 200 (Uniform Multimedia Interconnect Interface). The interface chip 200 includes one or more adapters 201, one or more management adapters (or management and control adapters) 202, and one or more ports 203. Alternatively, when the electronic device 20 is a routing device, the interface chip 200 only includes one or more ports 203. Each of the one or more adapters 201 can be coupled to an external component of the interface chip 200. The one or more management adapters 202 can be coupled to a component external to the interface chip 200 for management and control. The port 203 can be coupled to a connector 204 of the electronic device 20, which is used to couple to external devices of the electronic device 20. One or more adapters 201 can be a transmit / receive adapter. For example, when the adapter 201 is used to adapt audio and video formats, the adapter 201 can be an audio and video transmit / receive adapter. When the adapter 201 is used to adapt a third-party protocol, the adapter 201 can be a third-party protocol adapter.
[0072] For example, when port 203 is a downlink port, the transmission adapter can be used to adapt the service information to be sent into service information that can be transmitted on port 203 of the interface chip, and then send the service information out through port 203. When port 203 is an uplink port, the reception adapter 201 can be used to adapt the service information received from port 203 into service information to be processed internally by the electronic device 20. The management and control adapter 202 can be used to adapt control information.
[0073] The basic components of different electronic devices 20 can be combined to form a variety of different device types. For example, the electronic device 20 may be a source device comprising at least one downstream port and at least one audio and video transmitter adapter, or a source device comprising at least one upstream port and an audio and video receiver adapter, or a docking station device comprising at least one upstream port, at least one audio and video receiver adapter, and at least one traditional audio and video interface, or a routing device comprising at least one downstream port and at least one upstream port without an audio and video transmitter adapter or an audio and video receiver adapter, or a composite device having both an upstream port and a downstream port.
[0074] Figure 3 shows a schematic diagram of inter-interface transmission provided by an embodiment of the present application. In a unified multimedia interconnection system, the uplink and downlink ports between devices include a main link (ML) and a sideband link (SL). Furthermore, a power bus link (PL) and a cable information link (CL) may also be included. The cable information link can be used to transmit cable information, such as cable model and cable capability information.
[0075] The primary link is used for high-speed data transmission, such as audio and video signals, while the auxiliary link is mainly used for device management and control, such as device discovery, capability query, device configuration, and device control. It can also be used for low-speed data transmission and control message transmission. For example, in this application, the audio and video traffic flow is transmitted on the primary link of one port, and the network management traffic flow is transmitted on the auxiliary link of another port.
[0076] In some scenarios, the primary link consists of one or more lanes, each unidirectional, and the auxiliary link consists of two unidirectional lanes in different directions. Alternatively, some lanes in the primary link are unidirectional, others are bidirectional, and the auxiliary link is bidirectional. A primary link can include multiple lanes, for example, 2, 5, or 9. The greater the number of lanes, the faster the data transmission speed. That is, a downlink port can be used for both sending and receiving, and an uplink port can be used for both sending and receiving.
[0077] In addition, both the uplink port and the downlink port may include multiple pins, such as a pin connected to a ground line, a pin connected to a power line, a pin connected to a main link channel, and a pin connected to an auxiliary link channel.
[0078] FIG4 is a schematic diagram of a protocol stack 40 structure for data transmission between devices via a link, including an adapter layer, a transport layer, and a physical layer. The physical layer includes a logical layer and an electrical layer.
[0079] Among them, the adaptation layer is responsible for the connection between the interface chip (switch) and the external components. The functions that the adaptation layer can perform include data transmission adaptation, data reception adaptation, third-party protocol adaptation (protocol tunnel adaptation) and management adaptation (management control adaptation). Data transmission adaptation is to perform transmission adaptation on the source data received from the application of the device and then send it to the transport layer. Data reception adaptation is to perform reception adaptation on the data received from the transport layer and then send it to the application for data processing. Third-party protocol adaptation can be used to receive data from the transport layer, perform protocol adaptation on it, and then obtain third-party protocol data, and transmit it to the application for processing, or receive third-party protocol data from the application, perform adaptation on it, and then send it to the transport layer. Management adaptation is to adapt the control information received from the transport layer, perform management control according to the adapted control information, or adapt the control information generated from the management control process and then send it to the transport layer.
[0080] The transport layer is responsible for processing and forwarding service information or control information. For example, it can process and forward service flows such as video, audio, and third-party protocol tunnels, as well as management and control information, and perform bandwidth management for all service flows. For example, the transport layer can transmit multiple output streams in this application, including the first output stream of TLDP for video and audio and the network management service flow.
[0081] The logic layer is responsible for line coding and decoding, scrambling and descrambling, forward error correction (FEC) coding and decoding, and link training.
[0082] The electrical layer is responsible for signal equalization, spread spectrum, and clock recovery. The logical layer and the electrical layer can also be collectively referred to as the physical layer.
[0083] Based on the above introduction, in some scenarios, when links between devices transmit service flows, these service flows can be divided into three categories: link management service flows, network management service flows, and normal service flows. Link management service flows, for example, may include flows for link anomaly notifications and buffer allocation. Network management service flows, for example, include flows for control information generated by management control processes. Normal service flows, for example, include audio and video service flows and USB service flows.
[0084] Currently, when delay-guaranteed service flows, such as audio and video, participate in scheduling, they are affected by link management and network management service flows. Specifically, the scheduling priority of link management and network management service flows is higher than that of service flows such as video that require delay guarantees. This can result in packets from service flows such as audio and video not being output immediately. The delays in outputting service flows requiring delay guarantees include delays caused by the following service flows: lower-priority ordinary service flows that arrive earlier than the current audio and video service flow requiring delay guarantees, network management service flows, other audio and video service flows, and link management service flows. Consequently, the packet transmission delays of service flows requiring delay guarantees, such as audio and video, are significant.
[0085] Therefore, an embodiment of the present application proposes a scheduling method, in which a scheduling priority can be configured for each of the multiple business flows transmitted by the first port, the multiple business flows include at least one business flow that requires delay guarantee, the priority of the business flow that requires delay guarantee is the first priority, and the first priority is the highest priority among the priorities of the messages of the multiple business flows and the network management business flow. The business flow that requires delay guarantee is, for example, an audio and video business flow. Then, the multiple business flows and the network management business flow can be scheduled according to the scheduling priority configured for each of the multiple business flows. In this way, for business flows that require delay guarantee, such as audio and video, their output delay will not be affected by the network management business flow and other business flows with a lower priority than the business flows that require delay guarantee. The delayed output delay of the business flows that require delay guarantee is shorter, and the user experience is higher.
[0086] To facilitate understanding, some message types involved in this application are first introduced here.
[0087] In the unified multimedia interconnection, transport layer messages include transport layer data packets (TLDP) and transport layer management packets (TLMP).
[0088] Examples of TLDP include the audio and video TLDP, USB3 TLDP, and PCIe TLDP. TLDP also includes the transport layer management data packet (TLMDP) in this application. TLMDP can be used to manage and configure transmitted service data flows, such as priority configuration.
[0089] TLMP is used to manage both ends of a link and is generated and terminated at the transport layer at both ends of the link. TLMP includes the transport layer common link management packet (TLCMP) for both primary and secondary links. TLCMP includes at least one of the following: transport layer credit recycled packet (TLCRP), transport layer credit allocated packet (TLCAP), acknowledgement for transport layer credit allocated packet (TLCAP_ACK), transport layer credit consumed packet (TLCCP), or transport layer flow control error notification packet (TLFCENP).
[0090] The TLDP receiving end notifies the TLDP sending end at the other end of the link of the allocated credit through TLCAP.
[0091] TLCAP_ACK is used to respond to TLCAP.
[0092] TLCCP is used by the TLDP sender to notify the TLDP receiver of the number of consumed credits.
[0093] TLCRP is used by the TLDP receiver to notify the TLDP transmitter of the number of recovered credits.
[0094] TLFCENP is used by the TLDP transmitter to notify the TLDP receiver of abnormal flow control status.
[0095] Credits are used to track the buffer space of the receiving end. For example, 1 credit represents 32 bytes. The number of credits occupied by a message is (number of message bytes / 32), rounded up.
[0096] Based on the above overview, the embodiments of the present application are introduced below.
[0097] FIG5 is a flow chart showing a scheduling method provided in an embodiment of the present application, which includes the following process.
[0098] 501. The communication device configures a scheduling priority for each of the multiple business flows transmitted by the first port. The multiple business flows include at least one business flow that requires delay guarantee. The scheduling priority of the business flow that requires delay guarantee is the first priority. The first priority is the highest priority among the scheduling priorities of the multiple business flows and the network management business flow.
[0099] In some embodiments, the communication device is an electronic device or an interface device (or port device) or an interface chip in the above-mentioned application scenario. When the communication device is an electronic device, the electronic device may be, for example, a source device, a sink device, a routing device, an expansion dock, or a composite device. When the transmitting side is an interface device, the interface device may be, for example, an interface chip. The interface chip may be, for example, an interface chip of a source device, a sink device, a routing device, an expansion dock, or a composite device.
[0100] The source device, sink device and composite device are, for example, electronic devices such as personal computers, monitors, audio and video equipment, digital devices, printers, routers, game consoles and in-vehicle devices.
[0101] In some embodiments, the communication device is a transmitting side, and the first port is a downlink port, an output port, or a transmitting port. Of course, the first port can also receive messages from the receiving end when sending a service flow.
[0102] In some embodiments, some of the multiple service flows may be transmitted over the primary link of the first port, while others may be transmitted over the auxiliary link of the first port. For example, the service flows requiring latency protection are audio and video service flows. The audio and video service flows may be transmitted over the primary link of the first port, while the network management service flows may be transmitted over the auxiliary link of the first port.
[0103] In some embodiments, the above-mentioned multiple service flows can be understood as service flows of transport layer data packets, and the packets in service flows such as audio and video that require delay guarantee can be understood as transport layer data packets TLDP.
[0104] In some embodiments, the service flows other than the service flows requiring delay guarantee in the multiple service flows are, for example, PCIe service flows or USB3 service flows. That is, PCIe service flows or USB3 service flows can also be understood as service flows of transport layer data packets.
[0105] In some embodiments, the network management service flow transmits, for example, management control information of video and audio service flows, bandwidth management of video and audio service flows, etc. The message of the network management service flow is, for example, TLMDP.
[0106] In some embodiments, the scheduling method may occur at the transport layer of the communication device. That is, when the first port receives a service flow from a data transmission adapter at the adaptation layer at the transport layer, the transport layer may configure a scheduling priority for each service flow and assign the scheduling priority of the service flow requiring delay guarantee to the highest priority among the scheduling priorities of the messages of the multiple service flows and the network management service flow.
[0107] In some embodiments, the communication device configures the scheduling priority for each of the multiple service flows transmitted by the first port by using a management data message, such as TLMDP.
[0108] In some embodiments, the scheduling priority of the network management service flow is the second priority, and the scheduling priority of service flows other than the network management service flow is a priority other than the second priority. This means that the priority of messages from service flows other than the network management service flow cannot be configured to the second priority. In this way, the transmission delay of the network management service flow can be guaranteed to be low while the transmission delay of the service flows requiring delay guarantee is also low.
[0109] In some embodiments, among the scheduling priorities of multiple service flows, all priorities other than the first and second priorities are lower than the second priority. Thus, when the first priority is the highest priority, the transmission of the second priority service flow is not affected by other service flows among the multiple service flows except for the service flow requiring delay guarantee, thereby ensuring that the transmission delay of the network management service flow is also low.
[0110] In some embodiments, configuring a scheduling priority for each of the multiple business flows transmitted by the first port includes: configuring outbound flow scheduling information for each virtual channel in the multiple business flows transmitted by the first port, the outbound flow scheduling information including priority information of the virtual channel, and the priority information is used to indicate the scheduling priority of the business flow corresponding to the scheduling virtual channel.
[0111] It can be understood here that each port of the communication device includes multiple virtual channels, each virtual channel can transmit a service flow, and different virtual channels of each port transmit messages of different service flows.
[0112] 502. The communication device schedules the multiple service flows and the network management service flow according to the scheduling priority configured for each service flow in the multiple service flows.
[0113] In this way, when the first priority of the message of the business flow that needs delay protection is the highest priority among the scheduling priorities of multiple business flows and network management business flows, it is equivalent to that the first priority of the business flow that needs delay protection is higher than the scheduling priority of the network management business flow, and the first priority of the message of the business flow that needs delay protection is higher than the scheduling priority of other business flows in the multiple business flows except the business flow that needs delay protection. If scheduling is performed according to the scheduling priorities of multiple business flows and the scheduling priority of the network management business flow, the business flow that needs delay protection can be scheduled in priority over the network management business flow, and can be scheduled in priority over the business flows in the multiple business flows except the business flow that needs delay protection and the network management business flow. Compared with the existing method in which the network management business flow is scheduled in priority over the business flow that needs delay protection, the present application can make the transmission delay of the business flow that needs delay protection lower when the transport layer transmits multiple business flows.
[0114] In some embodiments, before step 502, the method may further include: the communication device performing weighted round robin (WRR) scheduling on service flows of the same priority among the multiple service flows.
[0115] In some embodiments, service flows of the same priority are service flows of the same service type (or the same message type), that is, service flows of the same service type have the same priority.
[0116] Exemplarily, the service types include video and audio, PCIe, and USB3.
[0117] In some embodiments, the outbound flow scheduling information configured for each virtual channel further includes weight information, where the weight information is used to indicate the scheduling weight of the service flow corresponding to the virtual channel when performing WRR at the same priority level.
[0118] In some embodiments, performing weighted round-robin scheduling on output flows of the same priority among multiple service flows includes: performing WRR scheduling on the service flows of the same priority on a packet basis based on weight information of the service flows corresponding to the virtual channels of the same priority among the multiple service flows. That is, WRR scheduling is performed on a packet basis.
[0119] Exemplarily, there are multiple audio and video service flows, and the messages of these multiple audio and video service flows have the same priority. These multiple audio and video service flows can be WRR-scheduled, that is, WRR-scheduled according to the weight corresponding to each audio and video service flow. For example, when multiple audio and video service flows are sent from the first port of a communication device to different receiving ends through a routing device, the first receiving end is set to play high-definition audio and video, and the first receiving end receives the first audio and video service flow among the multiple audio and video service flows, and the second receiving end is set to play standard-definition audio and video, and the second receiving end receives the second audio and video service flow among the multiple audio and video service flows, the weight of the first audio and video service flow is greater than the weight of the second audio and video service flow.
[0120] In some embodiments, the weight assigned to a high-definition video service flow is greater than the weight assigned to a standard-definition video service flow. Because the high-definition video service flow is assigned a higher weight, the high-definition video service flow may transmit a greater number of packets / data over a period of time, or have higher transmission efficiency. Conversely, because the standard-definition video service flow is assigned a lower weight, the standard-definition video service flow may transmit a smaller number of packets / data over the same period of time, or have lower transmission efficiency compared to the high-definition video service flow.
[0121] In some embodiments, the number of packets scheduled when WRR is applied to a third service flow among multiple service flows is proportional to the weight of the third service flow. The third service flow is any output flow among the multiple service flows. That is, for service flows of the same priority, a higher weight value results in a greater number of packets being scheduled for that service flow at a time, while a lower weight value results in a smaller number of packets being scheduled for that service flow at a time. This improves the transmission efficiency of high-weight service flows.
[0122] In some embodiments, the network management service flow is transmitted on the first virtual channel. This can be understood as the network management service flow being fixedly transmitted on a virtual channel and having an exclusive second priority. The network management service flow does not participate in WRR scheduling.
[0123] Based on the result of WRR scheduling of service flows with the same priority among multiple service flows, the scheduling of multiple service flows and network management service flows according to the scheduling priority configured for each service flow among the multiple service flows in the above step 502 may include: the communication device performs strict priority (SP) scheduling on multiple service flows and network management service flows according to the scheduling priorities of the multiple service flows and network management service flows, and the output of weighted round-robin scheduling of service flows with the same priority among multiple service flows.
[0124] SP scheduling, also known as absolute priority scheduling, prioritizes packets in higher-priority queues. When a higher-priority queue is empty, packets in a lower-priority queue are sent.
[0125] In some embodiments, the output of weighted round-robin scheduling of business flows with the same priority among multiple business flows can be understood as the result of weighted round-robin scheduling of multiple business flows with the same priority according to the weight of each business flow, that is, the message order of multiple business flows is scheduled according to the weighted round-robin scheduling and sorted into a message queue output.
[0126] In some embodiments, the total number of priorities configured for messages of multiple service flows and network management service flows is 8. This is equivalent to classifying the service types of service flows into 8 types, including multiple service flows of the aforementioned audio and video service types, PCIe, and USB3. Of course, this application does not limit the total number of priorities configured for service flows to 8; other numbers are also possible.
[0127] In this way, when the first priority of the service flow that needs delay protection is the highest priority among the scheduling priorities of multiple output flows and the second output flow, it is equivalent to that the first priority of the service flow that needs delay protection is higher than the second priority of the network management service flow, and the first priority of the service flow that needs delay protection is higher than the scheduling priority of other service flows in the multiple service flows except the service flow that needs delay protection. If the service flows with the same priority are output by weighted polling scheduling according to the priority of the messages of multiple service flows and the network management service flow is SP scheduled, the service flow that needs delay protection can be scheduled in priority over the network management service flow, and can be scheduled in priority over the service flows in the multiple service flows except the service flows that need delay protection and the network management service flow. Compared with the existing method in which the network management service flow is scheduled in priority over the service flow that needs delay protection, the present application can make the transmission delay of the service flow that needs delay protection lower when the transport layer transmits multiple service flows.
[0128] In some embodiments, in step 503, the method further includes: performing SP scheduling on the messages of the link management service flow, where the messages in the link management service flow may be collectively referred to as TLCMP. The present application may perform fine-grained division of the link management service flow to participate in SP scheduling.
[0129] In some embodiments, the link management service flow includes a delay-sensitive link management service flow and a delay-insensitive link management service flow.
[0130] In some embodiments, the message of the delay-sensitive link management service flow includes TLCRP in TLCMP.
[0131] The message of the delay-insensitive link management service flow includes at least one of TLCAP, TLCAP_ACK, TLCCP and TLFCENP in TLCMP.
[0132] In some embodiments, when the scheduling priority of the delay-sensitive link management service flow is the third priority and the scheduling priority of the delay-insensitive link management service flow is the fourth priority, the third priority is higher than the first priority, the fourth priority is lower than the first priority, and the fourth priority is higher than the second priority.
[0133] Thus, when performing SP scheduling, the order of scheduling from high priority to low priority is:
[0134] Delay-sensitive link management service packets (third priority);
[0135] Messages of business flows that require delay protection (first priority);
[0136] Messages of delay-insensitive link management service flows (fourth priority);
[0137] Network management service flow messages (second priority);
[0138] Messages of non-delay-guaranteed service flows, excluding service flows requiring delay guarantee, among multiple service flows, or other non-isochronous service flows.
[0139] In this way, compared with the problem of scheduling business flows such as audio and video that require delay protection after link management business flows and network management business flows, which leads to a large transmission delay for business flows such as audio and video that require delay protection, in this application, the link management business flows can be divided into fine-grained categories, and the link management business flows can be assigned different priorities to participate in SP scheduling based on whether they are delay-sensitive. Moreover, business flows such as audio and video that require delay protection are assigned a higher priority than link management business flows that are not delay-sensitive, and business flows such as audio and video that require delay protection are assigned a higher priority than network management business flows. In this way, when business flows such as audio and video that require delay protection participate in SP scheduling, the delay that prevents business flows such as audio and video from being output includes the delay caused by the following business flows: low-priority business flows that arrive earlier than the current audio and video business flows, delay-sensitive link management business flows, and business flows from other audio and video. That is, when business flows that require delay guarantee, such as audio and video, participate in scheduling, they will not be affected by the delay-insensitive link management business flows, network management business flows, and other non-delay-guaranteed business flows. The message transmission delay of business flows that require delay guarantee, such as audio and video, is relatively small.
[0140] In this application, delay-sensitive business flows can be understood as business flows that require shorter delays, or business flows with shorter transmission times, and delay-insensitive business flows can be understood as business flows that require relatively longer delays, or business flows with relatively longer transmission times.
[0141] In some embodiments, for example, a service flow may be determined to be a delay-sensitive service flow or a delay-insensitive service flow based on its type. Alternatively, a service flow may be determined to be a delay-sensitive service flow or a delay-insensitive service flow based on its delay parameters, delay indication information, or delay value.
[0142] In order to facilitate understanding of the following embodiments of this application, some terms involved in the embodiments of this application are first introduced.
[0143] 1) Forwarding model.
[0144] Taking the unified multimedia interconnect router as an example, FIG6 shows a schematic diagram of a transport layer message forwarding model for the unified multimedia interconnect router. All adapters on the unified multimedia interconnect router together form a virtual port, designated as Port 0. For example, FIG6 shows adapters 4, 5, ..., and n with identifiers (IDs) of AdapterID=4, AdapterID=5, ..., and AdapterID=n, where n is an integer. Each adapter in Port 0 is a virtual channel (Shuttle) on Port 0, and AdapterID is the same as ShuttleID, i.e., the ID values in AdapterID and ShuttleID are the same. Each virtual channel corresponds to a receive buffer (RBuff) and a transmit buffer (TBuff). The receive buffer is the buffer responsible for receiving, and the transmit buffer is the buffer responsible for sending.
[0145] The unified multimedia interconnect router also includes virtual ports, i.e., physical ports other than port 0, such as port 1 (Port 1) and port 2 (Port 2) shown in Figure 6. Each physical port also includes multiple virtual channels. For example, port 1 and port 2 include virtual channels 4, 5, ..., and n, with IDs ShuttleID = 4, ShuttleID = 5, ..., and ShuttleID = n, respectively. Each virtual channel in a physical port also corresponds to a receive buffer and a transmit buffer.
[0146] Messages from a virtual channel on port 0 can be forwarded to port 0 (adapters forward messages to each other) and any other physical port. Messages from a physical port can only be forwarded to ports other than the physical port itself, meaning that non-port 0 can only be forwarded to other ports. For example, messages in the receive buffer of adapter 4 on port 0 can be forwarded to the transmit buffer of adapter 5 on port 0, and messages in the receive buffer of adapter 5 on port 0 can be forwarded to the transmit buffer of adapter 4 on port 0. Messages in the receive buffer of adapter 4 on port 0 can be forwarded to the transmit buffer of virtual channel 5 on port 1, and messages in the receive buffer of virtual channel 5 on port 1 can be forwarded to the transmit buffer of adapter 4 on port 0. However, messages in the receive buffer of the virtual channel on port 1 can only be forwarded to the transmit buffer of virtual channels on ports other than port 1, and messages in the receive buffer of the virtual channel on port 2 can only be forwarded to the transmit buffer of virtual channels on ports other than port 2.
[0147] The physical ports other than port 0 mentioned above can be understood as the uplink ports or downlink ports mentioned above.
[0148] 2)ShuttleID numbering rules.
[0149] A bidirectional virtual channel, consisting of all packets carrying the same service on a link (physical link) between two ports, is called a shuttle. On the same physical link (e.g., a primary link or a secondary link), packets act like shuttle buses, transporting packets of different flows between two adjacent ports. Shuttle buses carrying packets of different flows are identified by a shuttle ID. Figure 7 shows a schematic diagram of a virtual channel. For example, a physical link is established between device A and device B. Two service flows are transmitted between device A's main downstream port (MDP) and device B's main upstream port (MUP). In Figure 7, the shuttle bus with the virtual channel ID virtual channel 7 (Shuttle ID = 7) carries packets of flow 1 (service flow 1), while the shuttle bus with the virtual channel ID virtual channel 5 (Shuttle ID = 5) carries packets of flow 2 (service flow 2). The link between the MDP and MUP transmits forward and reverse packets of flow 1, and forward and reverse packets of flow 2. The forward message and reverse message of the same flow can be understood as messages transmitted on two lanes of the same link. The forward message transmitted on one lane is the sent message, and the reverse message transmitted on one lane is the received message.
[0150] In other words, different flows on the same physical link are identified by ShuttleIDs, which can be assigned by the management adapter of the adaptation layer. The output ShuttleID of an output port becomes the input ShuttleID of the downstream input port.
[0151] Management data packets are fixedly identified by the virtual channel ID ShuttleID 0. A management adapter can be assigned a non-zero ShuttleID according to the following rules.
[0152] ShuttleID 1 to ShuttleID 3 are reserved and not assigned by the management adapter;
[0153] Different input ShuttleIDs of the same input port correspond to different input flows, that is, different input virtual channels of the same input port correspond to different input flows, where the input port can be understood as the uplink port in this application, and the service flow received by the input port can be called an input flow;
[0154] Different output ShuttleIDs of the same output port correspond to different output flows, where the output port can be understood as the downlink port in this application, and the service flow can be called an output flow when it is sent at the output port;
[0155] The output ShuttleIDs of different output ports are independent of each other and can use the same ShuttleID number;
[0156] When the management adapter configures the input ShuttleID of the input port to be forwarded to multiple different output ports simultaneously, it indicates that multicast replication is performed on the input Shuttle;
[0157] The same flow uses the same ShuttleID in both directions of the same physical link;
[0158] The ShuttleID of the same flow can be different on different physical links;
[0159] The allocated output ShuttleID cannot exceed the maximum ShuttleID supported by the output port;
[0160] The output ShuttleID of an output port cannot exceed the maximum ShuttleID supported by the downstream input port.
[0161] 3) Routing information
[0162] The management adapter provides routing information for each input shuttle (except shuttle ID 0) for each input port (the shuttle for the input stream). Each input port contains routing information that determines the forwarding port (FwPort) and forwarding shuttle ID for each input shuttle for that input port. Each input shuttle corresponds to one or more valid forwarding entries. Each forwarding entry corresponds to a unicast shuttle. When there are multiple valid forwarding entries, the input stream is multicast replicated, and each replicated stream is a separate unicast shuttle.
[0163] Each shuttle supports up to 16 valid forwarding entries (corresponding to forwarding on Ports 0 to 15). Multiple entries with FwPort 0 as the port number can appear in the valid forwarding entries, but each entry other than Port 0 can appear only once. The input shuttle of Port 0 can forward to Ports 0 to 15. The input shuttles of Ports 1 to 15 can only forward to Port 0 and other ports in the range of Ports 1 to 15. In other words, each input shuttle of Ports 1 to 15 cannot forward to the current port. For example, the input shuttle of Port 1 can only forward to the virtual channel of at least one of Ports 0 and Ports 2 to 15, but cannot forward to the virtual channel of Port 1.
[0164] Based on the above-mentioned terminology introduction involved in some embodiments of the present application, as shown in FIG8 , there is a flow chart of a scheduling method provided in an embodiment of the present application, which includes the following process.
[0165] 801. The communication device configures a scheduling priority for each of the multiple output streams transmitted by the first output port, the multiple output streams include at least one first output stream, the first output stream includes TLDP for video and audio, the priority of TLDP for video and audio is the first priority, the first priority is the highest priority among the scheduling priorities of the multiple output streams and the second output stream, and the second output stream includes TLMDP.
[0166] For the implementation of the communication device in the embodiment shown in FIG8 , reference may be made to the description in step 501 .
[0167] In some embodiments, the first output port may be one of multiple physical ports of the communication device, where the multiple physical ports are, for example, Port 1 or Port 2 described above, excluding Port 0. The first output port can be understood as a downlink port in this application. Of course, the first output port can not only send messages, but also receive messages. This application introduces the message scheduling process before the communication device sends a message to the receiving end. Therefore, this application refers to physical ports as output ports.
[0168] In some embodiments, the communication device may configure a priority for a message of each output flow transmitted to each output port (each physical port) of a plurality of output ports in the communication device, where the plurality of output ports include the first output port.
[0169] In some embodiments, the scheduling priority configured by the communication device for each of the multiple output flows transmitted by the first output port may be configured through a management data message, or configured through TLMDP.
[0170] In some embodiments, the multiple output streams can be understood as multiple data service streams to be sent by the communication device. The multiple output streams include a first output stream that is a data service stream for common audio and video services, and the message type in the first output stream is TLDP for audio and video services. The second output stream is a management data service stream. The management data service stream can be understood as a network management service stream in this application, and the message type in the second output stream is TLMDP.
[0171] That is to say, when the first priority of the message type TLDP for transmitting audio and video is the highest priority among the scheduling priorities of multiple output streams and the second output stream, the first priority of the TLDP for audio and video is higher than the scheduling priority of the message type TLMDP, and is higher than the scheduling priority of the output streams other than the first output stream of the TLDP for audio and video among the multiple output streams.
[0172] In some embodiments, the scheduling priority of the TLMDP is the second priority, and the scheduling priority of output flows other than the second output flow is a priority other than the second priority. In other words, packets of output flows other than the second output flow cannot be configured as the second priority.
[0173] In some embodiments, the scheduling priorities of the plurality of output streams other than the first priority and the second priority are lower than the second priority. Thus, the second priority of the TLMDP is lower than the first priority of the TLDP for video and audio, and is higher than the scheduling priorities of the other output streams other than the first output stream among the plurality of output streams.
[0174] In some embodiments, configuring a scheduling priority for each of a plurality of output streams transmitted by a first output port includes configuring outflow scheduling information for each output virtual channel of the first output port, the outflow scheduling information including priority information of the output virtual channel, the priority information being used to indicate the scheduling priority of the output stream corresponding to the output virtual channel.
[0175] Alternatively, the communication device may configure outbound flow scheduling information for each output shuttle of the first output port. The outbound flow scheduling information includes priority information for the output shuttle, which indicates the priority of the output flow corresponding to the output shuttle when scheduling. Each output shuttle is identified by a shuttle ID, and each output shuttle corresponds to one output flow.
[0176] In some embodiments, different output virtual channels of the first output port correspond to different output flows. In other words, different output Shuttles of the first output port correspond to different output flows, or in other words, messages with different ShuttleIDs of the first output port correspond to different output flows, and messages of the same output flow have the same ShuttleID.
[0177] 802. The communication device schedules the multiple output flows and the second output flow according to the scheduling priority configured for each of the multiple output flows.
[0178] In this way, when scheduling messages of multiple output streams, the scheduling delay of TLDP for video and audio is not affected by TLMDP, nor is it affected by messages of other priorities in multiple output streams except the first priority. The transmission delay of TLDP for video and audio is low.
[0179] In some embodiments, before step 802, the method further includes: the communication device performing WRR scheduling on output flows of the same priority among the multiple output flows.
[0180] The communication device in step 802 schedules the multiple output streams and the second output stream according to the scheduling priority configured for each of the multiple output streams, which may include: the communication device performs strict priority scheduling on the multiple output streams and the second output stream according to the scheduling priorities of the multiple output streams and the second output stream, and the output of the weighted polling scheduling of the output streams with the same priority among the multiple output streams.
[0181] WRR scheduling can be understood as the first-level scheduling of multiple output flows by a communication device. The first-level scheduling can also be understood as intra-priority scheduling.
[0182] In some embodiments, the output of weighted round-robin scheduling of output streams of the same priority among multiple output streams can be understood as the result of weighted round-robin scheduling of multiple output streams of the same priority according to the weight of each output stream, that is, the message order of multiple business streams is scheduled according to the weighted round-robin scheduling and sorted into a queue output.
[0183] In some embodiments, the outbound flow scheduling information further includes weight information, where the weight information is used to indicate a scheduling weight when the output flows corresponding to the output virtual channels are WRR scheduled at the same priority level.
[0184] In other words, each output flow (each output shuttle / each output virtual channel) is configured not only with a priority but also with a corresponding weight. This is to take into account that when two or more output flows transmit the same message type, the messages of the two or more output flows have the same priority. When scheduling two or more output flows of the same priority, WRR scheduling can be performed according to the scheduling weight corresponding to each output flow of the same priority.
[0185] In some embodiments, performing weighted round-robin scheduling on output flows of the same priority among multiple output flows includes: performing WRR scheduling on output flows of the same priority in units of messages based on weight information of output flows corresponding to output virtual channels of the same priority among multiple output flows.
[0186] Exemplarily, there are multiple first output streams to be sent by the first output port. The multiple first output streams can be forwarded to multiple receiving ends through a routing device connected to the communication device, and each receiving end receives one first output stream. The communication device acts as a transmitter, and when scheduling multiple first output streams, WRR scheduling is performed according to the scheduling weight corresponding to each first output stream. For example, the multiple first output streams are two first output streams: first output stream 1 and first output stream 2. First output stream 1 includes a TLDP of video and audio with ShuttleID=4, or in other words, the ShuttleID=4 of each video and audio TLDP in first output stream 1, and first output stream 2 includes a TLDP of video and audio with ShuttleID=5, or in other words, the ShuttleID=5 of each video and audio TLDP in first output stream 2. Since the first output stream 1 and the first output stream 2 have the same message type, both are TLDPs for video and audio, weight information needs to be configured for the first output stream 1 and the first output stream 2 respectively. For example, the scheduling weight of the first output stream 1 is 3, and the scheduling weight of the first output stream 2 is 2. When WRR scheduling is performed on the first output stream 1 and the first output stream 2, three TLDPs for video and audio can be scheduled from the message queue of the first output stream 1 (one TLDP for video and audio is scheduled each time, and three TLDPs for video and audio are scheduled continuously), and then two TLDPs for video and audio are scheduled from the message queue of the first output stream 2 (one TLDP for video and audio is scheduled each time, and two TLDPs for video and audio are scheduled continuously), and then three TLDPs for video and audio are scheduled from the message queue of the first output stream 1, and then two TLDPs for video and audio are scheduled from the message queue of the first output stream 2, and polling scheduling is performed in a cycle.
[0187] In some embodiments, the number of packets when WRR scheduling is performed on a third output flow among the multiple output flows is proportional to the weight of the third output flow, and the third output flow is any output flow among the multiple output flows.
[0188] That is, the larger the weight value is, the more packets are continuously scheduled for the third output flow each time.
[0189] For example, since the weight of first output stream 1 is greater than the weight of second output stream 2 when WRR scheduling is performed on first output stream 1 and second output stream 2, first output stream 1 can be output to receiver 1 playing high-definition video via a routing device, and first output stream 2 can be output to receiver 2 playing standard-definition video via a routing device. In other words, when WRR scheduling is performed on first output stream 1 and second output stream 2 based on their weights at the same priority level, it is possible to output both high-definition and standard-definition video streams on the same port.
[0190] Of course, the multiple output streams may also include two or more output streams of other types of messages. For example, the multiple output streams may include two output streams of PCIe message type but with different ShuttleIDs. These two output streams are cached in different queues / TBuffs and have the same message priority. The multiple output streams may also include two output streams of USB3 message type but with different ShuttleIDs. These two output streams are also cached in different queues and have the same message priority.
[0191] Based on step 803, the communication device in step 802 schedules the multiple output streams and the second output stream according to the scheduling priority configured for each output stream in the multiple output streams, which may include: the communication device performs SP scheduling on the multiple output streams and the second output stream according to the scheduling priorities of the multiple output streams and the second output stream, and the output of the weighted polling scheduling of the output streams with the same priority in the multiple output streams.
[0192] SP scheduling can be understood as the second-level scheduling of multiple output flows by a communication device. Second-level scheduling can also be understood as inter-priority scheduling. Step 803 is equivalent to performing SP scheduling on the messages scheduled for output within the multiple priorities and the messages of the second output flow according to the priorities of the messages in the multiple output flows.
[0193] Thus, when performing SP, the scheduling order from high priority to low priority is:
[0194] Packets that are output through WRR scheduling within the first priority level, namely, TLDP for video and audio, or multiple first output streams;
[0195] The second priority TLMDP, or the second output stream;
[0196] Packets of output flows with other priorities except the first priority and the second priority among the scheduling priorities of multiple output flows.
[0197] In this way, when scheduling messages of multiple output streams, the scheduling delay of TLDP for video and audio is not affected by TLMDP, nor is it affected by messages of other priorities in multiple output streams except the first priority. The transmission delay of TLDP for video and audio is low.
[0198] This application does not limit the TLDP of video and audio to be configured as the first priority. Other types of messages requiring delay protection can also be configured as the first priority to reduce the transmission delay of business flows of multiple messages requiring delay protection.
[0199] In some embodiments, the present application can divide the link management service flow of the communication device into fine-grained divisions and then participate in SP scheduling. For example, the link management service flow includes TLCMP.
[0200] In some embodiments, the method further includes: performing SP scheduling on TLCMP, where the TLCMP includes TLCRP. Wherein, when the scheduling priority of TLCRP is the third priority and the scheduling priority of messages other than TLCRP in TLCMP is the fourth priority, the third priority is higher than the first priority, the fourth priority is lower than the first priority, and the fourth priority is higher than the second priority.
[0201] In some embodiments, messages other than TLCRP in TLCMP include at least one of TLCAP, TLCAP_ACK, TLCCP, and TLFCENP.
[0202] That is to say, the present application can pre-configure fixed priorities for the various types of messages in TLCMP in the communication device, and when performing SP scheduling, perform SP scheduling on the various types of messages in TLCMP according to the priorities of the message types in TLCMP.
[0203] In this way, when SP scheduling is performed on the packets of multiple output flows, the second output flow, and the link management service flow, the scheduling order from highest priority to lowest priority is as follows:
[0204] TLCRP of third priority;
[0205] Packets that are output through WRR scheduling within the first priority level;
[0206] The fourth priority message is the message in TLCMP except TLCRP;
[0207] TLMDP of second priority;
[0208] Packets of output flows with priorities other than the first and second priorities.
[0209] This is because TLCRP is used by the TLDP receiver to notify the TLDP sender of the number of credits it has recovered. Credits are used to track the receiver's RBuff buffer space and determine whether the receiver has enough space to buffer the TLDP (data traffic flow) to ensure that the RBuff on the link receiver does not overflow. TLCRP transmission delay is required to be short, so TLCRP is a delay-sensitive link management message and can be configured with a third priority, higher than the first priority of TLDP for audio and video. TLCMP messages other than TLCRP, such as TLCAP for credit allocation, TLCAP_ACK for credit allocation acknowledgments, TLCCP for credit consumption, and TLFCENP for flow control exceptions, can be considered delay-insensitive link management messages. These messages have longer transmission delay requirements than delay-sensitive link management messages and can be configured with a fourth priority, lower than the first priority but higher than the second priority.
[0210] As a result, for the audio / video TLDP at priority 1, when the audio / video TLDP participates in scheduling output, delays that prevent the output of the first output stream of the audio / video TLDP currently waiting to be output include: lower-priority output streams that arrive earlier than the audio / video service stream, delay-sensitive link management service flows (TLCRP), and other audio / video service flows. The scheduling delay of the first output stream is not affected by delay-insensitive link management service flows other than TLCRP in the TLCMP, such as TLCAP, TLCAP_ACK, TLCCP, and TLFCENP; it is not affected by the second output stream of the TLMDP; and it is not affected by messages of other priorities other than the first and second priorities in the scheduling priorities of multiple output streams. Therefore, the transmission delay of the audio / video TLDP is relatively low.
[0211] The scheduling method in this application is introduced below based on a partial framework of the transport layer of the unified multimedia interconnection physical port.
[0212] To facilitate understanding of the scheduling method described below, we first introduce the partial framework of the transport layer of the unified multimedia interconnect physical port (excluding Port 0). Each unified multimedia interconnect physical port includes one link transmit adapter and one link receive adapter. Here, we introduce the framework of the link transmit adapter related to this application.
[0213] Figure 9 shows a schematic diagram of the framework of a link transmission adapter 90 for a unified multimedia interconnect physical port. Link transmission adapter 90 can be understood as a transport layer module. Referring to Figure 9 , the link transmission adapter includes a transmission buffer (TBuff), a bandwidth management module, a transmission flow control management module, a primary and secondary link distribution module, a primary link transmission management module, and an auxiliary link transmission management module.
[0214] The TBuff can be understood as the sending buffers of multiple virtual channels, and the sending buffer of each virtual channel occupies a part of the sending buffer of the TBuff.
[0215] Alternatively, the link transmission adapter includes multiple TBuffs, one TBuff for each virtual channel. When scheduling the messages of the output flow corresponding to each virtual channel, they are scheduled from the TBuff corresponding to the virtual channel. For example, if the unified multimedia interconnection physical port is a port in a routing device, the messages in the TBuff corresponding to each virtual channel can be forwarded from the virtual port Port0 of the routing device according to the routing information, or can be forwarded from other physical ports of the routing device according to the routing information. Each TBuff in the link transmission adapter 90 is used to cache the messages of an output flow / output virtual channel / output ShuttleID, which is equivalent to each TBuff being used to cache the messages of a business flow, and the TBuffs corresponding to different output ShuttleIDs are used to cache the messages of different business flows.
[0216] The sending flow control management module / unit can be understood as being used to complete flow control management in the sending direction.
[0217] The bandwidth management module (bandwidth management unit / bandwidth manager) can be used to prioritize and manage the bandwidth of all outgoing messages. Message priority management can be understood as including configuring message priorities and scheduling messages based on their priorities. Message bandwidth management can be understood as configuring message scheduling weights and scheduling messages based on those weights. The unified multimedia interconnection network can employ a distributed bandwidth management mechanism, meaning that each device in the unified multimedia interconnection network can manage the bandwidth of its own port. Each sending port (output port) of a unified multimedia interconnection physical link includes a bandwidth manager.
[0218] In some embodiments, the link sending adapter performs bandwidth management on the TLDP in the TBuff and the TLCMP output by the sending flow control management module / unit, and then sends it to the main link or the auxiliary link through the main-auxiliary link distribution operation (performed by the main-auxiliary link distribution module), performs main link sending management (performed by the main link sending management module) and auxiliary link sending management (performed by the auxiliary link sending management module) respectively, and then sends it to the logical layer.
[0219] In some embodiments, the bandwidth manager in this application includes an intra-priority scheduler and an inter-priority scheduler. The intra-priority scheduler is used to schedule all shuttles of the same priority level, that is, to schedule packets of output flows of the same priority level. The inter-priority scheduler is used to receive the output of each intra-priority scheduler and perform SP scheduling with the TLCMP generated by the transport layer. Messages with higher priorities are scheduled first, and messages with lower priorities are scheduled later.
[0220] That is to say, the bandwidth manager includes two levels of scheduling: first-level scheduling and second-level scheduling. The first-level scheduling is completed by the intra-priority scheduler, and the second-level scheduling is completed by the inter-priority scheduler.
[0221] Based on the above introduction to the link sending adapter 90 of the physical port, FIG10 is a flow chart of a scheduling method provided in an embodiment of the present application, which includes the following process.
[0222] 1001. A management adapter provides outbound flow scheduling information for each output virtual channel (Shuttle) of each output port. The outbound flow scheduling information includes priority information of each output virtual channel. The priority information is used to indicate the scheduling priority of the output flow corresponding to the output virtual channel.
[0223] As mentioned above, the management adapter is a module in the adaptation layer. When each output port of a communication device establishes a primary link and a secondary link with the input port of the receiving end, before the output stream is transmitted on the link, the management adapter of the adaptation layer can send the bandwidth manager of each output port the outbound flow scheduling information corresponding to each output shuttle of the output port. In other words, for each output port, the management adapter can provide each shuttle (output shuttle) with the outbound flow scheduling information based on the shuttle. In other words, it can provide each output stream with the outbound flow scheduling information based on the shuttle.
[0224] Each output port can be understood as a physical port of the communication device (excluding Port0).
[0225] In some embodiments, the management adapter sends a management data message (e.g., TLMDP) for each output port, where the management data message includes outbound flow scheduling information. For example, the management adapter may send multiple management data messages for each output port, one management data message for each output virtual channel, or a single management data message sent by the management adapter may include outbound flow scheduling information for multiple output virtual channels, although this application is not limited thereto.
[0226] Illustratively, the outbound flow scheduling information provided by the management adapter for each output Shuttle of each output port may be as shown in Table 1.
[0227] Table 1 Outflow scheduling information
[0228] In some embodiments, TLDP for video and audio is fixed at priority 0. TLMDP is fixed at priority 1, and other shuttles cannot be configured with priority 1. This means that only output shuttles with TLMDP packets are at priority 1, and output flows with TLMDP packets do not participate in WRR scheduling.
[0229] In some embodiments, the scheduling priority of the TLMDP may not be configured through outbound flow scheduling information. For example, when the ShuttleID of the TLMDP is fixed, the inter-priority scheduler may directly determine that the priority of the TLMDP is 1 based on the field indicating the message type or the ShuttleID in the TLMDP.
[0230] Therefore, Table 1 here is equivalent to showing that when an output port has multiple output flows to be scheduled, the configurable priority of the messages of the multiple output flows is one of priority 0, priority 2 to priority 7. This is equivalent to saying that when TLMDP is included, there can be 8 message types, each of which is assigned a priority. The bit width indicating the priority is 3, which can be understood as indicating the priority with 3 bits. For example, the bit value "000" indicates priority 0, the bit value "010" indicates priority 2, the bit value "011" indicates priority 3, the bit value "100" indicates priority 4, the bit value "101" indicates priority 5, the bit value "110" indicates priority 6, and the bit value "111" indicates priority 7. The priority of TLMDP can be pre-configured in the bandwidth manager by the management adapter using the bit value "001" to indicate that the priority of TLMDP is priority 1.
[0231] Of course, this application does not limit the number of priorities to 8, it can also be greater than 8 or less than 8.
[0232] When the bit width of the weight is 8, it can be understood that the weight is indicated by 8 bits. For example, the bit value "00000000" indicates a WRR scheduling weight of 0, where 0 represents no scheduling. This situation can occur, for example, when there is only one output flow of the corresponding output shuttle's message type, and there are no two output flows with the same message type. Different weights correspond to different numbers of messages that can be continuously scheduled. The larger the weight of the output shuttle, the more messages can be continuously scheduled each time the output shuttle participates in WRR scheduling.
[0233] Among them, the management adapter provides outflow scheduling information for each output Shuttle of each output port, which can be understood as the management adapter configuring the outflow scheduling information for each output flow (each ShuttleID) of each output port. When there are multiple output flows of the same type of message to be scheduled, each output flow is configured with the same scheduling priority and different weights. Of course, there may also be a situation where when there are multiple output flows of the same type of message to be scheduled, each output flow is configured with the same scheduling priority and the same weight. It should be understood that the scheduling priority of the output flow is determined by the message type in the output flow, which is equivalent to different message types corresponding to different scheduling priorities.
[0234] This application does not limit the priority level of audio and video TLDP to only 0; other types of message TLDPs may also be assigned priority 0. In other words, the same scheduling priority level may correspond to multiple message types. For example, audio and video TLDPs can be understood as messages for service flows requiring delay guarantees. In addition to audio and video TLDPs, other types of TLDPs may also be included in service flows requiring delay guarantees. The scheduling priority of both audio and video TLDPs and other types of TLDPs is priority 0.
[0235] 1002. The intra-priority scheduler completes the scheduling of all virtual channels belonging to the same priority level.
[0236] For example, FIG11 shows a schematic diagram of a bandwidth manager performing secondary scheduling. The priority of all messages of the output stream / output Shuttle of service a is priority 0, and the scheduling priority of all messages of the output stream / output Shuttle of service b is also priority 0. The scheduling priority of TLMDP is priority 1. The messages of service a are cached in the TBuff corresponding to the ShuttleID of service a, and the messages of service b are cached in the TBuff corresponding to the ShuttleID of service b. The scheduling priority of all messages of the output stream / output Shuttle of service i is priority 2, and the scheduling priority of all messages of the output stream / output Shuttle of service j is also priority 2. The messages of service i are cached in the TBuff corresponding to the ShuttleID of service i, and the messages of service j are cached in the TBuff corresponding to the ShuttleID of service j. The scheduling priority of all messages of the output stream / output Shuttle of service m is priority 7, and the scheduling priority of all messages of the output stream / output Shuttle of service n is also priority 7. The message of service m is cached in the TBuff corresponding to the ShuttleID of service m, and the message of service n is cached in the TBuff corresponding to the ShuttleID of service n. The implementation of other priorities 3 to 4 not shown is similar to that of priorities 0, 1, and 7.
[0237] The TLMDP message can be transmitted on the first virtual channel. The first virtual channel can be a fixed ShuttleID 0. The scheduling priority of the TLMDP message with ShuttleID 0 is priority 1. The TLMDP message with ShuttleID 0 can be cached in the TBuff corresponding to ShuttleID 0. TLMDP can be understood as a management data message or a network management message in this application.
[0238] In some embodiments, the intra-priority scheduler may schedule according to the following rules:
[0239] The TLDP for video and audio is fixed at priority 0;
[0240] TLMDP is always at priority 1; other shuttles cannot be configured with priority 1.
[0241] Except for priority 1, all shuttles within the same priority level are scheduled using WRR.
[0242] WRR scheduling is based on packets.
[0243] The number of packets scheduled by each shuttle is proportional to the configured weight.
[0244] After the management adapter configures a new WRR weight, the scheduler schedules according to the new weight value.
[0245] For example, taking priority 0 as an example, the packets of services a and b are both TLDPs for video and audio. The output shuttle corresponding to service a has ShuttleID=4, meaning that the ShuttleID carried by each TLDP for video and audio in service a's output stream / service flow is 4. The output shuttle corresponding to service b has ShuttleID=5, meaning that the ShuttleID carried by each TLDP for video and audio in service b's output stream / service flow is 5. The scheduling priority of the TLDP for video and audio with ShuttleID=4 and the scheduling priority of the TLDP for video and audio with ShuttleID=5 are both at priority 0. When scheduling priority 0 packets, the intra-priority scheduler may perform WRR scheduling based on the weights corresponding to the output shuttles with ShuttleID=4 and ShuttleID=5. For example, the weight corresponding to the output shuttle with ShuttleID=4 is 3, and the weight corresponding to the output shuttle with ShuttleID=5 is 2. The intra-priority scheduler can first schedule three packets of service a from the TBuff with ShuttleID=4, then schedule two packets of service b from the TBuff with ShuttleID=5, then schedule three packets of service a from the TBuff with ShuttleID=4, and then schedule two packets of service b from the TBuff with ShuttleID=5, performing round-robin scheduling. Of course, the packet scheduling method for other priority services 2 to 7 can refer to the example for priority 0 here.
[0246] In some scenarios, the weight corresponding to the output Shuttle with ShuttleID=4 and the weight corresponding to the output Shuttle with ShuttleID=5 may also be the same.
[0247] If the weight corresponding to the output Shuttle of ShuttleID=4 is different from the weight corresponding to the output Shuttle of ShuttleID=5, here is an example of a possible scenario. FIG12 is a schematic diagram of an audio and video transmission scenario. In FIG12, the method flow shown in FIG10 is executed by a set-top box 120, for example. The output port 121 of the set-top box 120 is connected to the input port 123 of the routing device 122, and the output port 124 and port 125 of the routing device 122 are respectively connected to a display. Among them, the port 124 of the routing device 122 is connected to the port 127 of the display 126, and the port 125 of the routing device 122 is connected to the port 129 of the display 128. The display 126 is set to high-definition mode, and the display 128 is set to standard definition mode. Port 121 of set-top box 120 transmits service flow a to port 127 of display 126 via port 124 of routing device 122. Port 121 of set-top box 120 transmits service flow b to port 129 of display 128 via port 125 of routing device 122. When port 121 of set-top box 120 outputs service flow a and service flow b, the Shuttle ID carried in the TLDP of each video and audio message in service flow a is 4, and the Shuttle ID carried in the TLDP of each video and audio message in service flow b is 5. The intra-priority scheduler can perform round-robin scheduling according to the above example of the polling process for services a and b.
[0248] Accordingly, when the management adapter of the set-top box 120 determines the mode switch of the display 126 or the display 128, the management adapter of the set-top box 120 can send the adjusted weight to the port 121 to adjust the weight corresponding to the ShuttleID of the service a or the service b, and the priority scheduler can schedule the messages of the service a and the service b according to the adjusted weight.
[0249] From a macro perspective, configuring the weights for different service flows can also be understood as configuring the bandwidth ratios for different service flows. The management adapter determines the bandwidth ratios for different service flows output from the same port based on the different service requirements of that port. In some embodiments, the weight ratios for different service flows of the same priority level are the bandwidth ratios for those service flows. The greater the weight of a service flow, the greater the bandwidth ratio for that service flow. Conversely, the smaller the weight of a service flow, the smaller the bandwidth ratio for that service flow.
[0250] 1003. The inter-priority scheduler receives the output of each intra-priority scheduler and performs SP scheduling with the TLCMP generated by the transport layer. The higher priority is scheduled first and the lower priority is scheduled later.
[0251] In some embodiments, the output of a priority scheduler can be understood as multiple output flows within the same priority level are polled and scheduled according to the weights corresponding to the output flows, and the messages of multiple output flows within the same priority level are sorted into a queue output. This queue can be understood as the output of a priority scheduler.
[0252] In some embodiments, when output flows of priorities other than priority 1 are scheduled according to weight, for the TLMDP with ShuttleID=0, the inter-priority scheduler may schedule the TLMDP from the TLMDP queue in the TBuff corresponding to ShuttleID=0 according to the first-in-first-out principle.
[0253] In some embodiments, the TLCMP generated by the transport layer is a message generated by the aforementioned sending flow control management module and belongs to a link management service flow.
[0254] In some embodiments, the TLCMP generated by the transport layer includes TLCRP and at least one of TLCAP, TLCAP_ACK, TLCCP, or TLFCENP other than TLCRP.
[0255] In some embodiments, when the priority scheduler schedules messages, the priorities from high to low may be:
[0256] TLCRP;
[0257] Output of the intra-priority scheduler at priority level 0;
[0258] Other TLCMPs except TLCRP (TLCAP / TLCAP_ACK / TLCCP / TLFCENP);
[0259] TLMDP;
[0260] The output of the scheduler within the priority range of 2 to 7, with priority 2 to priority 7 gradually decreasing in priority.
[0261] This means that the present application further divides the TLCMP used for link management into finer granularity, where TLCRP has a higher priority than priority 0, and other TLCMPs (TLCAP / TLCAP_ACK / TLCCP / TLFCENP) except TLCRP have a lower priority than priority 0 and higher than TLMDP's priority 1. Other priority levels 2 to 7 are lower than priority 1.
[0262] In this way, while ensuring a low transmission delay of TLCRP for link management service flows, the transmission delay of TLDP for video and audio is also reduced.
[0263] Here, an example is used to compare the total delay of the TLDP of audio and video using the scheduling method of this application. The delay caused by blocking each audio and video service flow when all ordinary service flows (including audio and video service flows) are transmitted after the link management service flow and the network management service flow (Technique 1) is compared with the delay caused by blocking each audio and video service flow caused by the scheduling method of this application. Assume that there is a scenario where a port on the transmitting end needs to transmit X (for example, 120) pieces of flow control information, where the length of the low-priority service message (such as USB3 or PCIe message) that arrives earlier is 512 bytes, and there are two audio and video service flows. The delay comparison of each audio and video service flow is shown in Table 2.
[0264] Table 2
[0265] It can be seen that if the method of technology 1 is used, the delay of each audio and video business flow being blocked includes the delay of 512 bytes of low-priority messages that arrive earlier than the audio and video business flow, the delay of 512 bytes of the previous audio and video business flow, and the delay of TLCMP (484 bytes of delay of TLCRP, 484 bytes of delay of TLCCP, 484 bytes of delay of TLCAP, 24 bytes of delay of TLCAP_ACK, 24 bytes of delay of TLFECNP, and 512 bytes of delay of network management message), totaling 3036 bytes. If the scheduling method of the present application is used, the delay of each audio and video business flow being blocked can include the delay of 512 bytes of low-priority messages that arrive earlier than the audio and video business flow, the delay of 484 bytes of TLCRP, and 512 bytes of delay of the previous audio and video business flow, totaling 1508 bytes. This scheduling method of the present application can make the delay of audio and video business flow transmitted by a port lower.
[0266] Of course, the present application does not limit the priority of only TLDP for audio and video to priority 0. The priority of messages of other service flows that require delay protection may also be configured as priority 0. The present application does not limit the priority of only TLCRP to be higher than priority 0 when performing inter-priority scheduling. It can be extended so that the priority of messages of delay-sensitive link management service flows can be higher than priority 0. The present application does not limit the priority of only TLCAP / TLCAP_ACK / TLCCP / TLFCENP messages to be between priority 0 and priority 1 when performing inter-priority scheduling. It can be extended so that the priority of messages of delay-insensitive link management service flows can be lower than priority 0 and higher than priority 1. The present application does not limit the priority of only TLMDP to be priority 1. The priority of messages of other network management service flows may also be priority 1. In this way, in combination with the embodiment of Figure 5 and the embodiment of Figure 10, the bandwidth manager performing secondary scheduling shown in Figure 11 can also be extended to the schematic diagram of the bandwidth manager performing secondary scheduling as shown in Figure 13.
[0267] In combination with the embodiment given in FIG. 5 above, it is equivalent to the present application performing priority scheduling based on whether the service flow is delay-sensitive:
[0268] Link management traffic is prioritized based on whether it is delay-sensitive or not. Delay-sensitive common traffic is prioritized to priority 0, while network management messages are prioritized to priority 1.
[0269] This application includes two levels of scheduling: Level 1: Intra-priority scheduler, which includes multiple priority levels. Except for Priority 1, all other priorities perform WRR scheduling. Level 2: Inter-priority scheduler, which performs SP scheduling between services. The priority order is: delay-sensitive link management service flow > Priority 0 > delay-insensitive link management service flow > Priority 1 > Priority 2 > ... > Priority i. Services requiring latency guarantees, such as audio and video, are assigned Priority 0, network management services are assigned Priority 1, and other services not requiring latency guarantees are assigned lower priorities.
[0270] In other words, this application can place link management service flows at different priorities for scheduling based on whether they are delay-sensitive; place delay-guaranteed service flows such as audio and video at a higher priority than link management service flows that are not delay-sensitive; place delay-guaranteed service flows such as audio and video at a higher priority than network management service flows; allow different configurations to achieve different effects (allow different weight configurations to obtain different WRR scheduling outputs).
[0271] In some embodiments, the audio and video business flow (such as TLDP of audio and video) is transmitted unidirectionally at a port of a device, for example, the device sends audio and video business flow 1 (outgoing flow) at one port and receives audio and video business flow 2 (incoming flow) at another port.
[0272] In some embodiments, in a unified multimedia internet network, multiple virtual channels that transmit the same service between two adapters constitute a logical channel. When the management adapter wants to establish a logical channel between two adapters, it needs to establish all bidirectional shuttles between the two adapters (except shuttleID 0). When establishing a bidirectional shuttle, the management adapter not only provides routing information for each shuttle, but also provides inbound and outbound flow information for each shuttle. The inbound and outbound flow information may include the outbound flow scheduling information in this application. The difference is that when the inbound and outbound flow information includes the "priority" field in the outbound flow scheduling information, the priority can be used not only for the outbound flow scheduling of each shuttle, but also for the inbound flow scheduling of each shuttle. That is, the same port can not only send messages of the same service flow, but also receive messages of the same service flow. For example, the bidirectional transmission services of the same port are USB3 or PCIe, etc.
[0273] It is understood that in order to implement the functions in the above embodiments, the communication device includes hardware structures and / or software modules corresponding to the execution of each function. It should be readily apparent to those skilled in the art that, in combination with the units and method steps of each example described in the embodiments disclosed in this application, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in hardware or in a manner driven by computer software depends on the specific application scenario and design constraints of the technical solution.
[0274] Figures 14 and 15 are schematic diagrams of the structures of possible communication devices provided by the embodiments of the present application. The communication device can be understood as an interface device or electronic device in the present application. These communication devices can be used to implement the functions of the communication device in the above-mentioned method embodiments, and thus can also achieve the beneficial effects possessed by the above-mentioned method embodiments. In the embodiments of the present application, the communication device can be one of the devices 1011 or 1021 as shown in Figure 1, or one of the devices 103 to 106 as shown in Figure 1, or the device shown in Figure 2 above, or an interface module (such as a chip or chipset) applied to these devices. The relevant communication device is used to implement interface data transmission, for example, it can be used to implement the unified multimedia interconnection interface function described above.
[0275] As shown in Figure 14, the communication device 140 includes a configuration module 1410 and a scheduling module 1420. The communication device 140 is used to implement the functions of the sending side or the receiving side in the method embodiments shown in Figures 6, 8 and 11 above.
[0276] When the communication device 140 is used to implement the function of the communication device as a transmitter in the method embodiments shown in Figures 5, 8, and 10: the configuration module 1410 can be used to configure a scheduling priority for each of the multiple output streams transmitted by the first output port, the multiple output streams including at least one first output stream, the first output stream including a TLDP for video and audio, the scheduling priority of the TLDP for video and audio being a first priority, the first priority being the highest priority among the scheduling priorities of the multiple output streams and the second output stream, the second output stream including a TLMDP. The scheduling module 1420 is used to schedule the multiple output streams and the second output stream according to the scheduling priority configured for each of the multiple output streams.
[0277] For a more detailed description of the configuration module 1410 and the scheduling module 1420 , please refer to the relevant descriptions in the method embodiments shown in FIG. 5 , FIG. 8 and FIG. 10 .
[0278] In some embodiments, the scheduling module 1420 is further configured to perform weighted round-robin scheduling on output flows of the same priority among the multiple output flows. The scheduling module 1420 is configured to perform strict priority scheduling on the multiple output flows and the second output flow based on the scheduling priorities of the multiple output flows and the second output flow, and the output of the weighted round-robin scheduling on the output flows of the same priority among the multiple output flows.
[0279] In some embodiments, the scheduling priority of the TLMDP is the second priority, and the scheduling priority of output streams other than the second output stream of the unified multimedia interconnect is a priority other than the second priority of the unified multimedia interconnect.
[0280] In some embodiments, among the scheduling priorities of the plurality of output streams of the unified multimedia interconnect, priorities other than the unified multimedia interconnect first priority and the unified multimedia interconnect second priority are lower than the unified multimedia interconnect second priority.
[0281] In some embodiments, the configuration module 1410 is used to: configure outbound flow scheduling information for each output virtual channel of the first output port, the unified multimedia interconnection outbound flow scheduling information includes priority information of the output virtual channel, and the unified multimedia interconnection priority information is used to indicate the scheduling priority of the output flow corresponding to the output virtual channel.
[0282] In some embodiments, different output virtual channels of the first output port of the unified multimedia interconnect correspond to different output streams.
[0283] In some embodiments, the TLMDP is transmitted on a first output virtual channel.
[0284] In some embodiments, the scheduling module 1420 is also used to: perform strict priority scheduling on the transport layer shared management message TLCMP, and the unified multimedia interconnection TLCMP includes the transport layer credit recovery message TLCRP; wherein, when the scheduling priority of the unified multimedia interconnection TLCRP is the third priority, and the scheduling priority of messages other than the unified multimedia interconnection TLCRP in the unified multimedia interconnection TLCMP is the fourth priority, the unified multimedia interconnection third priority is higher than the unified multimedia interconnection first priority, the unified multimedia interconnection fourth priority is lower than the unified multimedia interconnection first priority, and the unified multimedia interconnection fourth priority is higher than the unified multimedia interconnection second priority.
[0285] In some embodiments, messages other than the unified multimedia interconnection TLCRP in TLCMP include at least one of a transport layer credit allocation message TLCAP, a transport layer credit allocation response message TLCAP_ACK, a transport layer credit consumption message TLCCP, and a transport layer flow control exception notification message TLFCENP.
[0286] In some embodiments, the outbound flow scheduling information further includes weight information, and the unified multimedia interconnection weight information is used to indicate the scheduling weight of the output flows corresponding to the output virtual channels when weighted round-robin scheduling is performed at the same priority level.
[0287] In some embodiments, the scheduling module 1420 is configured to perform weighted round-robin scheduling on output flows of the same priority in units of packets according to weight information of output flows corresponding to output virtual channels of the same priority in multiple output flows of the unified multimedia interconnection.
[0288] In some embodiments, the number of messages when weighted round-robin scheduling is performed on a third output stream among the multiple output streams of the unified multimedia interconnect is proportional to the weight of the third output stream of the unified multimedia interconnect, and the third output stream of the unified multimedia interconnect is any output stream among the multiple output streams of the unified multimedia interconnect.
[0289] In some embodiments, the total number of priorities configured for the messages of the multiple output flows of the unified multimedia interconnect and the second output flow of the unified multimedia interconnect is 8.
[0290] As shown in Figure 15, the communication device 150 includes a processor 1510 and an interface circuit 1520. The processor 1510 and the interface circuit 1520 are coupled to each other. It is understood that the interface circuit 1520 can be a transceiver or an input / output interface. Optionally, the communication device 150 may also include a memory 1530 for storing instructions executed by the processor 1510, or storing input data required by the processor 1510 to execute instructions, or storing data generated after the processor 1510 executes instructions.
[0291] When the communication device 150 is used to implement the methods shown in Figures 5, 8, and 10, the processor 1510 is used to implement the functions of the configuration module 1410, for example, it can be used to implement the related implementation processes of steps 501, 801, and 1001. The interface circuit 1520 is used to implement the functions of the scheduling module 1420, for example, it can be used to implement the related implementation processes of steps 502, 802, 1002, and 1003. The interface circuit 1520 can be an interface chip or a separate IP module integrated into the interface chip.
[0292] When the communication device 150 is an interface chip used at a transmitting end, the transmitting interface chip implements the functions of the communication device in the above-mentioned method embodiment. When the transmitting interface chip sends a message / data to the receiving end, it can be understood that the data is first generated by other modules (such as the source data component) at the transmitting end and then sent to the transmitting interface chip by these modules.
[0293] In the present application, when entity A sends information to entity B, it can be A sending it directly to B or A sending it indirectly to B through other entities. Similarly, when entity B receives information from entity A, it can be entity B receiving the information sent by entity A directly or entity B receiving the information sent by entity A indirectly through other entities. Entities A and B here can be the sending end or the receiving end, or they can be modules within the sending end or the receiving end. The sending and receiving of messages / data can be information interaction between the sending end and the receiving end, for example, information interaction between a source device and a sink device; the sending and receiving of messages / data can also be information interaction between different modules within a device, for example, information interaction between an interface chip at the sending end and an interface chip at the receiving end.
[0294] An embodiment of the present application also provides a communication system, which includes a first communication device and a second communication device. The first communication device can be used to implement the method flow shown in Figures 5, 8 and 10, and a communication connection is established between the first communication device and the second communication device.
[0295] It is understood that the processor in the embodiments of the present application may be a central processing unit (CPU), or may be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. The general-purpose processor may be a microprocessor or any conventional processor.
[0296] The method steps in the embodiments of the present application can be implemented in hardware or in software instructions that can be executed by a processor. The software instructions can be composed of corresponding software modules, and the software modules can be stored in random access memory, flash memory, read-only memory, programmable read-only memory, erasable programmable read-only memory, electrically erasable programmable read-only memory, registers, hard disk, mobile hard disk, CD-ROM or any other form of storage medium well known in the art. An exemplary storage medium is coupled to the processor so that the processor can read information from the storage medium and write information to the storage medium. The storage medium can also be an integral part of the processor. The processor and storage medium can be located in an ASIC. In addition, the ASIC can be located in a base station or a terminal. The processor and storage medium can also exist in a base station or a terminal as discrete components.
[0297] In the above embodiments, all or part of the embodiments may be implemented using software, hardware, firmware, or any combination thereof. When implemented using software, all or part of the embodiments may be implemented in the form of a computer program product. The computer program product includes one or more computer programs or instructions. When the computer program or instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present application are performed in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, a network device, a user device, or other programmable device. The computer program or instructions may be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another. For example, the computer program or instructions may be transferred from one website, computer, server, or data center to another website, computer, server, or data center via wired or wireless means. The computer-readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a server or data center that integrates one or more available media. The available medium may be a magnetic medium, such as a floppy disk, hard disk, or magnetic tape; an optical medium, such as a digital video disk; or a semiconductor medium, such as a solid-state drive. The computer-readable storage medium may be a volatile or nonvolatile storage medium, or may include both volatile and nonvolatile types of storage media.
[0298] In the various embodiments of the present application, unless otherwise specified or there is a logical conflict, the terms and / or descriptions between different embodiments are consistent and can be referenced by each other. The technical features in different embodiments can be combined to form new embodiments according to their inherent logical relationships.
[0299] In this application, "at least one" means one or more, and "more" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. In the text description of this application, the character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "Including at least one of A, B and C" can mean: including A; including B; including C; including A and B; including A and C; including B and C; including A, B and C.
[0300] It is understood that the various numbers used in the embodiments of this application are merely for ease of description and are not intended to limit the scope of the embodiments of this application. The order of the sequence numbers of the above-mentioned processes does not necessarily imply a specific order of execution; the order of execution of the processes should be determined by their functions and inherent logic.
Claims
1. A scheduling method, characterized in that, the method includes: configuring a scheduling priority for each of multiple output streams transmitted by a first output port, the multiple output streams including at least one first output stream, the first output stream including a transport layer data packet (TLDP) of audio and video, the scheduling priority of the TLDP of the audio and video being a first priority, the first priority being the highest priority among the scheduling priorities of the multiple output streams and a second output stream, the second output stream including a transport layer management data packet (TLMDP); scheduling the multiple output streams and the second output stream according to the scheduling priorities configured for each of the multiple output streams.
2. The method according to claim 1, characterized in that, the method further includes: performing weighted round-robin scheduling on the output streams with the same priority among the multiple output streams; the scheduling the multiple output streams and the second output stream according to the scheduling priorities configured for each of the multiple output streams includes: performing strict priority scheduling on the multiple output streams and the second output stream according to the scheduling priorities of the multiple output streams and the second output stream, and the output of the weighted round-robin scheduling of the output streams with the same priority among the multiple output streams.
3. The method according to claim 1 or 2, characterized in that, the scheduling priority of the TLMDP is a second priority, and the scheduling priorities of the output streams other than the second output stream are priorities other than the second priority.
4. The method according to claim 3, characterized in that, the priorities other than the first priority and the second priority among the scheduling priorities of the multiple output streams are lower than the second priority.
5. The method according to any one of claims 1-4, characterized in that, the configuring a scheduling priority for each of multiple output streams transmitted by a first output port includes: configuring out-flow scheduling information for each output virtual channel of the first output port, the out-flow scheduling information including priority information of the output virtual channel, the priority information being used to indicate the scheduling priority of the output stream corresponding to the output virtual channel.
6. The method according to claim 5, characterized in that, different output virtual channels of the first output port correspond to different output streams.
7. The method according to claim 5 or 6, characterized in that, the TLMDP is transmitted on a first output virtual channel.
8. The method according to any one of claims 3-7, characterized in that, the method further includes: performing strict priority scheduling on a transport layer common management packet (TLCMP), the TLCMP including a transport layer credit recovery packet (TLCRP); wherein, when the scheduling priority of the TLCRP is a third priority, and the scheduling priorities of the packets other than the TLCRP in the TLCMP are fourth priorities, the third priority is higher than the first priority, the fourth priority is lower than the first priority, and the fourth priority is higher than the second priority.
9. The method according to claim 8, wherein, the messages in the TLCMP other than the TLCRP include at least one of a transport layer credit allocation message TLCAP, a transport layer credit allocation acknowledgment message TLCAP_ACK, a transport layer credit consumption message TLCCP, and a transport layer flow control exception notification message TLFCENP.
10. The method according to any one of claims 5-9, wherein, the outgoing flow scheduling information further includes weight information, and the weight information is used to indicate the scheduling weight of the output flow corresponding to the output virtual channel when weighted round-robin scheduling is performed at the same priority.
11. The method according to claim 10, wherein, the weighted round-robin scheduling of the output flows with the same priority among the multiple output flows includes: performing weighted round-robin scheduling on the output flows with the same priority in units of messages according to the weight information of the output flows corresponding to the output virtual channels with the same priority among the multiple output flows.
12. The method according to claim 11, wherein, the number of messages during weighted round-robin scheduling of the third output flow among the multiple output flows is proportional to the weight of the third output flow, and the third output flow is any one of the multiple output flows.
13. The method according to any one of claims 1-12, wherein, the total number of priority levels configured for the messages of the multiple output flows and the second output flow is 8.
14. A communication device, wherein, comprises: a configuration module, configured to configure a scheduling priority for each of the multiple output flows transmitted by a first output port, the multiple output flows including at least one first output flow, the first output flow including a transport layer data packet TLDP of audio and video, the priority of the TLDP of the audio and video being a first priority, the first priority being the highest priority among the scheduling priorities of the multiple output flows and a second output flow, and the second output flow including a transport layer management data packet TLMDP; a scheduling module, configured to schedule the multiple output flows and the second output flow according to the scheduling priority configured for each of the multiple output flows.
15. A communication device, wherein, comprises a module for executing the method according to any one of claims 1 to 13.
16. A communication device, wherein, comprises a processor and a memory, the processor and the memory being coupled, and the processor is configured to run a computer program or instruction stored in the memory so that the communication device executes the method according to any one of claims 1-13.
17. A communication system, wherein, comprises a first communication device and a second communication device, a communication connection is established between the first communication device and the second communication device, and the first communication device is configured to execute the method according to any one of claims 1-13.
18. A computer-readable storage medium, wherein, The computer-readable storage medium stores computer instructions, which, when run on a communication device, cause the communication device to execute the method according to any one of claims 1-13.
19. A computer program product, characterized in that it includes computer instructions, which, when run on a communication device, cause the communication device to execute the method according to any one of claims 1-13.
20. A chip, characterized in that the chip stores computer execution instructions, and when the computer execution instructions are run, the method according to any one of claims 1-13 is executed.
Citation Information
Patent Citations
Dynamic bandwidth scheduling with transport network
CN107113251A
Service scheduling method suitable for wireless TDMA ad hoc network
CN109962760A
Service flow transmission method, device, equipment and storage medium
CN112822125A
Quality of service queue management in home mesh network
US20100232447A1