Control method and apparatus, chip, network device, and communication system
By using energy-saving policies and performance data in the control chip of data center network equipment to automatically adjust the status of ports or channels, the problem of complex energy consumption adjustment processes for network equipment is solved, achieving rapid and timely energy consumption reduction and management accuracy.
Patent Information
- Application Number
- PCT/CN2024/089182
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-06-20
- Filing Date
- 2024-04-22
- Publication Date
- 2024-10-31
AI Technical Summary
In the existing technology, the energy consumption adjustment process of data center network equipment is complicated and cannot be adjusted in time, resulting in increased energy consumption.
The control chip of the network device automatically adjusts the opening or closing of ports or channels based on energy-saving strategies and performance data, simplifying the control process and reducing energy consumption.
It achieves rapid and timely adjustment of network equipment energy consumption, reduces the overall energy consumption of data center network equipment, and improves the accuracy of energy consumption management.
Smart Images

Figure CN2024089182_31102024_PF_FP_ABST
Abstract
Description
Control method, device, chip, network equipment and communication system
[0001] This application claims priority to the Chinese patent application filed with the State Intellectual Property Office on April 25, 2023, with application number 202310475262.2 and application name “A control method”. This application also claims priority to the Chinese patent application filed with the State Intellectual Property Office on June 20, 2023, with application number 202310742710.0 and application name “Control method, device, chip, network equipment and communication system”. All of these contents are incorporated by reference into this application. Technical Field
[0002] The present application relates to the field of communications, and in particular to a control method, device, chip, network equipment and communication system. Background Art
[0003] As data centers grow in size, their energy consumption also increases. The network portion of data center energy consumption accounts for a particularly significant portion. Currently, network devices require additional management channels to send signaling messages over these channels. After mutual confirmation, the control center adjusts the channel status, altering the network device's energy consumption. This complicates the control process for network devices and hinders timely energy adjustments.
[0004] Summary of the Invention
[0005] The present application provides a control method, apparatus, chip, network equipment and communication system, thereby simplifying the control process of the port of the network equipment or the channel corresponding to the port, quickly and timely adjusting the network equipment, and reducing the energy consumption of the network equipment.
[0006] In a first aspect, a control method is provided, which is executed by a control chip of a network device. The method includes adjusting the opening or closing of a port of the network device or a channel corresponding to the port based on an energy-saving policy and performance data of the network device. The energy-saving policy indicates the conditions for opening or closing the port of the network device or the channel corresponding to the port. The performance data indicates the operating characteristics of the port of the network device during the current cycle.
[0007] Compared with the solution in which the network devices send signaling to confirm each other and then adjust the status of the channel indicated by the control center to change the energy consumption of the network devices, the solution provided by the present application does not require mutual negotiation between network devices, nor does it require control by the controller. The network devices only need to adjust the opening or closing of the ports of the network devices or the channels corresponding to the ports based on their own performance, thereby simplifying the control process of the ports of the network devices or the channels corresponding to the ports, quickly and timely adjusting the network devices, and reducing the energy consumption of the network devices.
[0008] The performance data includes at least one of port bandwidth occupancy and queue depth.
[0009] In one possible implementation, adjusting the state of a port or a corresponding channel of a port based on an energy-saving policy and performance data includes adjusting the state of at least one port of a network device or the state of a corresponding channel of the port based on the performance data when the performance data meets a shutdown condition indicated by the energy-saving policy. Thus, adjusting the state of at least one port of a network device or the state of a corresponding channel of the port based on the condition indicated by the energy-saving policy improves the accuracy of the adjustment.
[0010] In another possible implementation, adjusting the state of a channel corresponding to a port includes adjusting the state of a serial-to-parallel converter (SerDes) corresponding to the channel from an active state to a power-saving state. Thus, by adjusting the SerDes state to the power-saving state, the power consumption of the SerDes is reduced, thereby reducing the power consumption of the network device.
[0011] In another possible implementation, the port is used to send data, and adjusting the state of the channel corresponding to the port includes instructing the link layer to stop transmitting data and adjusting the state of the channel corresponding to the port. This ensures that data transmission on the link is complete and prevents data loss during the shutdown process.
[0012] In another possible implementation, the network device further includes a second chip, the port is used to send data, and adjusting the state of the channel corresponding to the port includes: instructing the second chip to stop sending the training code stream and adjusting the state of the channel corresponding to the port.
[0013] In another possible implementation, the port is used to receive data, and adjusting the state of the channel corresponding to the port includes: adjusting the state of the channel corresponding to the port when no training code stream is received.
[0014] Therefore, since the transmitting end does not send the training stream to the receiving end, the receiving end does not receive the training stream. When it is determined that the channel training fails, the state of the channel corresponding to the port is adjusted as soon as possible to reduce the energy consumption of the network device.
[0015] A port is used to send data, or when a network device acts as a transmitter, adjusting the state of the port or the channel corresponding to the port means adjusting the state of the port or the channel corresponding to the port used to send data. A port is used to receive data, or when a network device acts as a receiver, adjusting the state of the port or the channel corresponding to the port means adjusting the state of the port or the channel corresponding to the port used to receive data.
[0016] In another possible implementation, the port or the corresponding channel is in a closed state, and the method further includes: adjusting the port or the corresponding channel to be open when the performance data meets the opening condition indicated by the energy-saving policy. Thus, when data transmission is required, the port or the corresponding channel is opened to resume data transmission, thereby avoiding service impact caused by the closed port or the corresponding channel.
[0017] In another possible implementation, adjusting the port or the channel corresponding to the port to enable includes adjusting the state of a serial-to-parallel converter corresponding to the channel from a power-saving state to an active state. Thus, by adjusting the state of the serial-to-parallel converter to the active state, the serial-to-parallel converter is in an operating state and can transmit data through the channel corresponding to the port.
[0018] For example, when a training code stream is received, the state of the serial-to-parallel converter corresponding to the channel is adjusted from the energy-saving state to the active state.
[0019] In another possible implementation, obtaining an energy-saving policy for a network device includes obtaining the energy-saving policy for the network device based on characteristics of the network device, where the characteristics of the network device include at least one of the network device's location within the network, the network device's size, the network device's configuration, and performance data of the network device. Thus, the network device periodically obtains the energy-saving policy, improving the accuracy of the network device's control of ports and channels contained within the ports based on the energy-saving policy, thereby effectively reducing energy consumption of the network device.
[0020] In a second aspect, a control device is provided, comprising modules for executing the control method of the first aspect or any possible design of the first aspect. For example, the control device comprises a communication module and an energy consumption control module. The communication module is configured to obtain an energy-saving policy of a network device, wherein the energy-saving policy indicates conditions for opening or closing a port of the network device or a channel corresponding to the port; the energy consumption control module is configured to obtain performance data of the network device, wherein the performance data indicates operating characteristics of the port of the network device during the current cycle; and the energy consumption control module is configured to adjust the state of the port or the channel corresponding to the port according to the energy-saving policy and the performance data, wherein the state includes opening or closing.
[0021] In one possible implementation, the energy consumption control module adjusts the state of a port or a channel corresponding to a port according to an energy-saving strategy and performance data, and is specifically used to: when the performance data meets the shutdown condition indicated by the energy-saving strategy, adjust the state of at least one port in the network device or the state of the channel corresponding to the port according to the performance data.
[0022] In another possible implementation, the performance data includes at least one of interface bandwidth occupancy, queue depth, and packet delay.
[0023] In another possible implementation, when the energy consumption control module adjusts the state of the channel corresponding to the port, it is specifically configured to adjust the state of the serial-to-parallel converter corresponding to the channel from the active state to the energy-saving state.
[0024] In another possible implementation, the port is used to send data, and the energy consumption control module is used to instruct the second chip to stop sending the training code stream and adjust the state of the channel corresponding to the port.
[0025] In another possible implementation, the port is used to receive data, and the energy consumption control module is used to adjust the state of the channel corresponding to the port when no training code stream is received.
[0026] In another possible implementation, the port is used to send data, and when the energy consumption control module adjusts the state of the channel corresponding to the port, it is specifically used to: instruct the link layer to stop transmitting data and adjust the state of the channel corresponding to the port.
[0027] In another possible implementation, the state of the port or the channel corresponding to the port is closed, and the energy consumption control module is further configured to adjust the port or the channel corresponding to the port to open when the performance data meets the closing condition indicated by the energy-saving policy.
[0028] In another possible implementation, when the energy consumption control module adjusts the channel corresponding to the port to be turned on, it is specifically used to: adjust the state of the serial-to-parallel converter corresponding to the channel from the energy-saving state to the active state.
[0029] For example, when a training code stream is received, the state of the serial-to-parallel converter corresponding to the channel is adjusted from the energy-saving state to the active state.
[0030] In another possible implementation, when the communication module obtains the energy-saving strategy of the network device, it is used to: obtain the energy-saving strategy of the network device based on the characteristics of the network device, and the characteristics of the network device include at least one of the location of the network device in the network, the scale of the network device, the configuration of the network device and the performance data of the network device.
[0031] In a third aspect, a chip is provided, comprising: a processor and a power supply circuit; wherein the power supply circuit is used to power the processor; and the processor is used to execute the operating steps of the method described in the first aspect or any possible implementation of the first aspect.
[0032] In a fourth aspect, a network device is provided, which includes at least one processor and a memory, the memory being used to store a set of computer instructions; when the processor executes the set of computer instructions, the operating steps of the method in the first aspect or any possible implementation of the first aspect are performed.
[0033] In a fifth aspect, a communication system is provided, the communication system including a first network device and a second network device, the first network device and the second network device executing the operation steps of the method in the first aspect or any possible implementation manner of the first aspect.
[0034] In a sixth aspect, a computer-readable storage medium is provided, comprising: computer software instructions; when the computer software instructions are executed in a network device, the network device executes the operating steps of the method described in the first aspect or any possible implementation of the first aspect.
[0035] In a seventh aspect, a computer program product is provided. When the computer program product is run on a computer, it enables the computer to perform the operating steps of the method described in the first aspect or any possible implementation of the first aspect.
[0036] The technical effects brought about by any design method in the second to seventh aspects can be referred to the technical effects brought about by the first aspect or different design methods in the first aspect, and will not be repeated here.
[0037] Based on the implementation methods provided in the above aspects, this application can also be further combined to provide more implementation methods. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] FIG1 is a schematic diagram showing the relationship between a network device, a port, a channel, and a serial-to-parallel converter provided by the present application;
[0039] FIG2 is a schematic diagram of the architecture of a communication system provided by the present application;
[0040] FIG3 is a flow chart of a control method provided by the present application;
[0041] FIG4 is a schematic diagram of an energy-saving strategy configuration provided by this application;
[0042] FIG5 is a schematic diagram of a state transition of a serial-to-parallel converter provided by the present application;
[0043] FIG6 is a schematic diagram of a state transition of a channel provided by the present application;
[0044] FIG7 is a flow chart of an energy-saving mechanism for a channel provided by the present application;
[0045] FIG8 is a schematic diagram of a process for forcibly closing a channel provided by the present application;
[0046] FIG9 is a schematic diagram of a process of non-forced channel closing provided by the present application;
[0047] FIG10 is a schematic diagram of a process for opening a channel provided by the present application;
[0048] FIG11 is a schematic diagram of a control process provided by the present application;
[0049] FIG12 is a schematic diagram of a control process provided by the present application;
[0050] FIG13 is a flow chart of an energy-saving mechanism for a port provided by the present application;
[0051] FIG14 is a schematic structural diagram of a control device provided by the present application;
[0052] FIG15 is a schematic diagram of the structure of a network device provided in this application. DETAILED DESCRIPTION
[0053] To facilitate understanding, the main terms involved in this application are first explained.
[0054] A data center is a global collaborative network of specific devices that transmits, accelerates, displays, calculates, and stores data information on the Internet infrastructure.
[0055] Energy consumption refers to an evaluation indicator of the amount of energy consumed by a product when it is in use.
[0056] Port refers to the interface used to connect network devices (such as hubs, switches, and routers) in network technology.
[0057] A link is a physical line between two nodes, without any intervening switching nodes. A link can also be called a physical link or a communication link. A link can consist of multiple lanes. A lane can also be called a physical channel, a physical path, or a signal path. For example, a link can consist of 2, 4, 8, or 16 lanes.
[0058] A serializer-deserializer (SerDes) converts parallel signals into serial signals, or vice versa. A serializer-deserializer (SerDes) is also called a serializer / deserializer. Each channel corresponds to a SerDes.
[0059] For example, Figure 1 is a schematic diagram of the relationship between a network device, port, channel, and serial-to-parallel converter provided by the present application. As shown in Figure 1, network device A includes port A1. Network device B includes port B1. The link between port A1 and port B1 includes four channels, namely channel 1, channel 2, channel 3, and channel 4. When data is transmitted from port A1 to port B1 or from port B1 to port A1, it can be transmitted through the four channels. Among them, network device A also includes serial-to-parallel converter A2, serial-to-parallel converter A3, serial-to-parallel converter A4, and serial-to-parallel converter A5. Network device B also includes serial-to-parallel converter B2, serial-to-parallel converter B3, serial-to-parallel converter B4, and serial-to-parallel converter B5. Channel 1 corresponds to serial-to-parallel converter A2 and serial-to-parallel converter B2, channel 2 corresponds to serial-to-parallel converter A3 and serial-to-parallel converter B3, channel 3 corresponds to serial-to-parallel converter A4 and serial-to-parallel converter B4, and channel 4 corresponds to serial-to-parallel converter A5 and serial-to-parallel converter B5. For example, the serial-to-parallel converter A2 can convert a parallel signal into a serial signal, and transmit the serial signal to the port B1 through the channel 1. The serial-to-parallel converter B2 can convert the serial signal into a parallel signal.
[0060] To address the issue of timely adjusting the energy consumption of network devices, this application provides a control method for adjusting the opening or closing of a network device's ports or their corresponding channels based on the network device's energy-saving policy and performance data. The energy-saving policy indicates the conditions under which a network device's ports or their corresponding channels should be opened or closed. The performance data indicates the operating characteristics of the network device's ports during the current cycle.
[0061] Compared with the solution in which the network devices send signaling to confirm each other and then adjust the status of the channel indicated by the control center to change the energy consumption of the network devices, the solution provided by the present application does not require mutual negotiation between network devices, nor does it require control by the controller. The network devices only need to adjust the opening or closing of the ports of the network devices or the channels corresponding to the ports based on their own performance, thereby simplifying the control process of the ports of the network devices or the channels of the ports, quickly and timely adjusting the network devices, and reducing the energy consumption of the network devices.
[0062] The solution provided in this application can be applied to communication systems such as cluster networks, super-node interconnected networks, etc. For example, high performance computing (HPC) networks or high availability (HA) networks.
[0063] For example, as shown in FIG2 , a communication system 200 is an entity that provides high-performance computing. The communication system 200 includes multiple supernodes 210. The supernode 210 includes multiple nodes 211. The supernode 210 can be a cabinet server or a blade server. The node 211 can be a processor, a server, a desktop computer, a controller and memory of a storage array, etc. The processor can be a central processing unit (CPU), a graphics processing unit (GPU), a data processing unit (DPU), a neural processing unit (NPU), an embedded neural-network processing unit (NPU), or other XPU for data processing. For example, the supernode 210 can include computing nodes and storage nodes.
[0064] Multiple nodes 211 in the supernode 210 are connected based on a high-bandwidth, low-latency high-speed interconnection technology. For example, as shown in FIG2 , the nodes 211 are connected via a switch 212 based on the high-speed interconnection technology.
[0065] Optionally, multiple supernodes 210 are connected via a data center network 220. The data center network 220 includes multiple core switches 221 and multiple aggregation switches 222. The data center network 220 can form a scale domain. Multiple supernodes 210 can form a performance domain.
[0066] The data center network topology can include a core layer and an aggregation layer. The core layer, also known as the spine layer, is the high-speed switching backbone layer of the data center network, used to connect the data center to devices outside the data center (such as external carrier equipment). The core layer may include core switches and core routers with high bandwidth (such as bandwidth exceeding 1 Gigabit). The core layer has at least one of the following characteristics: reliability, efficiency, redundancy, fault tolerance, manageability, adaptability, and low latency. Data center network reliability can generally be achieved through redundant connections between multiple devices.
[0067] The aggregation layer acts as the "intermediary" between the access layer and the core layer, aggregating data output by the access layer to reduce the load on the core layer. The aggregation layer includes aggregation switches.
[0068] A network device is used to receive data sent by one device and forward the data to another device. It can be understood that a network device includes both receiving and transmitting functions. For example, the transmit and receive direction of the SerDes (serial data service) in the network device is configured as needed. If the SerDes (serial data service) transmits data in the transmit direction, the network device can send data through the corresponding channel of the SerDes; if the SerDes (serial data service) transmits data in the receive direction, the network device can receive data through the corresponding channel of the SerDes.
[0069] In some embodiments, network devices within a communication system are configured with an energy-saving agent that is configured to enable or disable ports or channels of the network devices based on the network device's energy-saving policy and performance data. Network devices include, but are not limited to, switches within supernodes, and core and aggregation switches within data center networks.
[0070] Figure 2 is merely a schematic diagram, and the embodiments of this application do not limit the number of devices included in the communication system. Furthermore, the connection method between switches and nodes shown in Figure 2 is merely a schematic illustration; in actual applications, switches and nodes may also be connected using other methods, which are not limited by this application.
[0071] Optionally, the communication system may further include other devices, such as a controller. The controller is used to manage network devices in the communication system to ensure that the network devices operate normally.
[0072] In this application, the controller can send energy-saving policies to network devices. For example, after sending an initial energy-saving policy to a network device, the controller adjusts the energy-saving policy based on performance data periodically reported by the network device and periodically sends the updated energy-saving policy to the network device. This improves the accuracy of the energy-saving policy.
[0073] Alternatively, the controller can be a standalone server, connected to network devices via dedicated control channels. Alternatively, the controller can be deployed as a module on network devices. After a network device is managed by the controller, the controller can initiate the energy-saving policy configuration delivery process, sending the energy-saving policy to the network device managed by the controller.
[0074] Next, the implementation of the control method provided in this application is described in detail with reference to the accompanying drawings.
[0075] Figure 3 is a flow chart of a control method provided by this application. This method can be executed by a first chip (e.g., a control chip) of a network device. The control chip runs an energy-saving agent to implement energy-saving operations on the network device. The network device can be a switch, core switch, aggregation switch, or other device in the communication system shown in Figure 2. Adjusting the status of the channel corresponding to a port is used as an example for explanation. As shown in Figure 3, the method includes the following steps.
[0076] Step 310: Obtain the energy-saving strategy of the network device.
[0077] Energy-saving policies indicate the conditions under which the channels corresponding to ports on a network device are enabled or disabled. Specifically, when the corresponding channel on a network device is disabled, data cannot be transmitted on the corresponding channel, reducing the device's energy consumption. Conversely, when the corresponding channel on a network device is enabled, data transmission on the corresponding channel resumes.
[0078] In some embodiments, a pre-configured energy-saving policy is stored in a memory of the network device, and the network device can obtain the pre-configured energy-saving policy from the memory.
[0079] In other embodiments, the network device receives the energy-saving policy from the controller. If the controller is a standalone server, the energy-saving policy is received via a link between the network device and the controller. If the controller is deployed within the network device, the controller can be a general-purpose chip with control functions, such as a CPU.
[0080] For example, as shown in FIG4 , the network device sends configuration information to the controller (step 410). The configuration information includes the number of ports included in the network device, the number of channels corresponding to the ports, the address, and the device identifier. The device identifier includes at least one of the device model, the device manufacturer, and the device name.
[0081] The controller generates an energy-saving policy for the network device based on the configuration information and sends the energy-saving policy to the network device (step 420). For example, the controller determines the characteristics of the network device based on the configuration information to generate the energy-saving policy. The characteristics of the network device include the location of the network device in the network, the scale of the network device (such as the number of ports and channels), the configuration of the network device (such as the direction of the channel, the configuration of the port, the routing configuration, the quality of service), and the importance of the network device in the network. For example, if the network device is a device used to form the core layer, the controller generates the energy-saving policy while ensuring the reliability and low latency of the network device, avoiding the reliability and low latency of the network device being affected by reducing the energy consumption of the network device, and achieving a balance between the energy consumption, reliability and low latency of the network device.
[0082] In some embodiments, the energy-saving policy generated by the controller for the network device based on the configuration information may be an initial energy-saving policy. To improve the accuracy of the network device in adjusting the state of the channel corresponding to the port based on the energy-saving policy and effectively reduce the energy consumption of the network device, the network device may also periodically obtain the energy-saving policy. For example, the network device reports the performance data of the network device to the controller (step 430). The controller updates the initial energy-saving policy based on the performance data of the network device and generates an updated energy-saving policy. The controller sends the updated energy-saving policy to the network device (step 440).
[0083] Optionally, the energy-saving strategy includes at least one of an energy-saving enable flag, a port flag, a port priority, a priority of a channel corresponding to the port, a detection frequency, and a threshold. The energy-saving enable flag is used to indicate whether energy saving is enabled. For example, a power-saving enable flag of 1 indicates that energy saving is enabled; a power-saving enable flag of 0 indicates that energy saving is not enabled. The port flag is used to uniquely indicate a port. The detection frequency is used to indicate the number of times the performance of a network device is periodically detected per unit time. The threshold is used to indicate the limit for starting energy saving based on the performance of the network device. The threshold includes a minimum threshold and a maximum threshold. The minimum threshold is used to indicate whether to shut down the port of the network device or the channel corresponding to the port. The maximum threshold is used to indicate whether to restart the port of the network device or the channel corresponding to the port.
[0084] Step 320: Obtain performance data of the network device.
[0085] Performance data is used to indicate the operating characteristics of the port of the network device during the current cycle. For example, performance data includes at least one of the following: data interface bandwidth utilization, queue depth, and message delay. Interface bandwidth utilization indicates the bandwidth utilization of the interface bandwidth for receiving or sending information per unit time. For example, if the interface bandwidth is 100M and the actual traffic is 90M, the utilization rate is 90%. A higher interface bandwidth utilization indicates a higher traffic volume; a lower interface bandwidth utilization indicates a lower traffic volume. Queue depth indicates the number of messages to be transmitted. Message delay indicates the time it takes for a message to be transmitted from the sender to the receiver. Port states include energy-saving state and active state.
[0086] In some embodiments, the network device obtains performance data of the network device according to the energy saving policy. For example, if the network device determines that the energy saving enable flag included in the energy saving policy indicates that energy saving is enabled, the network device obtains performance data of each port in the network device.
[0087] For another example, the network device periodically obtains performance data of each port in the network device according to the detection frequency included in the energy-saving strategy.
[0088] For another example, the energy-saving strategy includes a port identifier, and the network device obtains performance data of the port indicated by the port identifier.
[0089] For another example, the energy-saving strategy includes port priority, and the network device obtains performance data of the port in the network device based on the port priority.
[0090] Step 330: Adjust the state of the channel corresponding to the port according to the energy-saving strategy and performance data.
[0091] When the performance data of the port meets the conditions indicated by the energy-saving policy, the state of the channel corresponding to the port in the network device is adjusted according to the performance data of the port, and the state includes open or closed.
[0092] For example, the condition indicates whether the interface bandwidth occupancy exceeds the interface bandwidth occupancy threshold. When the interface bandwidth occupancy of the port is less than or equal to the first interface bandwidth occupancy threshold, it means that the load of the port is low and the data to be transmitted is small, then at least one channel corresponding to the port is closed. When the interface bandwidth occupancy of the port is greater than or equal to the second interface bandwidth occupancy threshold, it means that the load of the port is high and the data to be transmitted is large, then at least one channel corresponding to the port is opened. The first interface bandwidth occupancy threshold is less than the second interface bandwidth occupancy threshold. The first interface bandwidth occupancy threshold can be the minimum threshold for closing a channel. The second interface bandwidth occupancy threshold can be the maximum threshold for opening a channel.
[0093] For another example, the condition indicates whether the queue depth of the port exceeds a queue depth threshold. For another example, the condition indicates whether the packet delay of the port exceeds a delay threshold.
[0094] In some embodiments, adjusting the state of the channel corresponding to the port may refer to adjusting the state of the serdes corresponding to the channel corresponding to the port. The states of the serdes include an active state and a power-saving state. The active state of the serdes includes a working state and a non-working state. The working state means that the serdes converts parallel signals into serial signals, or converts serial signals into parallel signals, and the channel corresponding to the serdes transmits data normally, and the energy consumption of the serdes is relatively high. The non-working state means that the serdes is not transmitting data and is in an idle state. The power-saving state of the serdes means that the serdes is in a low-power state and the serdes turns off the functions of parallel and serial signals.
[0095] For example, as shown in Figure 5, shutting down the channel corresponding to the port will cause the SerDes state to transition from active to energy-saving, and from high-power to low-power. Consequently, by adjusting the SerDes state to energy-saving, the SerDes' energy consumption will decrease, thereby reducing the energy consumption of the network device. Enabling the channel corresponding to the port will cause the SerDes state to transition from energy-saving to active, resuming data transmission.
[0096] For example, the first port of the first network device is connected to the second port of the second network device through a link. The first network device sends data to the second network device through the first port. The second network device receives the data sent by the first network device through the second port. For the sending side, when the performance data of the first port meets the shutdown condition indicated by the energy-saving strategy, the channel in the link between the first port and the second port is closed, that is, the serdes in the network device where the first port corresponding to the channel is located is adjusted to be in an energy-saving state, and then no data is transmitted on the channel. For the receiving side, when the performance data of the second port meets the shutdown condition indicated by the energy-saving strategy, the serdes in the network device where the second port corresponding to the channel is located is adjusted to be in an energy-saving state. As a result, there is no need for the network devices to negotiate with each other, and there is no need to be controlled by the controller. They only need to adjust the opening or closing of the channels corresponding to the ports of the network devices based on their own performance, thereby simplifying the control process of the channels corresponding to the ports of the network devices, quickly and timely adjusting the channel closure of the network devices, and reducing the energy consumption of the network devices.
[0097] It should be noted that the link corresponding to the port includes multiple channels, and multiple channels can form a channel group. When the performance data of the port meets the shutdown conditions indicated by the energy-saving policy, at least one channel in the channel group is shut down according to preset rules. For example, at least one channel is randomly selected from the channel group and shut down. In another example, at least one channel is shut down in ascending order of channel identifiers in the channel group. In another example, based on the performance data of the port, while ensuring the transmission requirements of the data to be transmitted, at least one channel is randomly selected from the channel group and shut down.
[0098] For example, a link includes 4 channels, 2 channels are needed to transmit data to be transmitted, 2 channels are randomly selected from the 4 channels, and 2 channels are closed.
[0099] In addition, in order to avoid the situation where multiple channels included in the link corresponding to the port are all closed, resulting in the link corresponding to the port being unable to transmit data, the state of at least one channel in the link corresponding to the port is retained to be open to ensure that the link corresponding to the port transmits data. The port transmits data based on the at least one reserved channel, thereby facilitating the judgment of whether to open the closed channel corresponding to the port based on the performance data of the port.
[0100] When the performance data of a port meets the activation conditions indicated by the energy-saving policy, the channels in the link corresponding to the port are enabled, that is, the serdes corresponding to the channels are adjusted to an active state. The number of enabled channels corresponding to the port is less than or equal to the number of disabled channels corresponding to the port. At least one channel is randomly enabled from the disabled channels corresponding to the port, or at least one channel is enabled from the disabled channels corresponding to the port based on the performance data of the port.
[0101] Optionally, for a port receiving data, when the port's performance data meets the opening conditions indicated by the energy-saving policy, all closed channels corresponding to the port are opened. Thus, the port opens these closed channels and resumes data transmission on these channels as quickly as possible. In other embodiments, after adaptively closing at least one channel corresponding to the port based on the port's performance data, all closed channels corresponding to the port are opened after a timer expires. In other embodiments, after opening all closed channels corresponding to the port, when the port's performance data meets the closing conditions indicated by the energy-saving policy, at least one opened channel is closed again, or energy-saving operations are not performed on the opened channels of the port, so as to facilitate the reception of data based on these opened channels as quickly as possible.
[0102] The above embodiment explains that when the performance data of the port meets the shutdown condition indicated by the energy-saving policy, the channel corresponding to the port in the network device is closed, that is, the serdes corresponding to the channel is put into an energy-saving state, and the channel corresponding to the serdes does not transmit data, thereby reducing the power consumption of the network device by quickly adjusting the state of the channel and forcibly closing the serdes.
[0103] In other embodiments, non-mandatory shutdown of SerDes is used to reduce power consumption of network devices. When the performance data of a port meets the conditions indicated by the energy-saving policy, the training stream is stopped, so that the port receiving data can quickly detect the abnormal data transmission of the port and adjust the status of the channel corresponding to the port.
[0104] Here, the first network device is used as a transmitting end and the second network device is used as a receiving end. The first port of the first network device and the second port of the second network device are connected via a first link. The first link includes N channels.
[0105] When the performance data of the first port meets the shutdown conditions indicated by the energy-saving policy, it is determined to shut down the first channel corresponding to the first port, and the first chip in the first network device instructs the second chip to stop sending the training code stream. The first chip is configured to perform energy-saving operations according to the control method provided in this application. The second chip is configured to perform switching functions. Furthermore, the first network device shuts down the first channel corresponding to the first port, i.e., adjusts the state of the SerDes (Serdes) corresponding to the first channel in the first network device to an energy-saving state.
[0106] Since the first network device did not send the training code stream to the second network device and the second network device did not receive the training code stream, the second network device determines that the second port is abnormal, determines that the performance data of the second port meets the shutdown condition indicated by the energy-saving policy, and closes the first channel corresponding to the second port, that is, adjusts the state of the serdes corresponding to the first channel in the second network device to the energy-saving state.
[0107] When the performance data of the first port meets the activation condition indicated by the energy-saving policy, it is determined that the first channel corresponding to the first port is activated, and the first network device sends a training code stream to the second network device via the first channel corresponding to the first port. When the first channel corresponding to the second port of the second network device is activated, the second port of the second network device receives the training code stream based on the first channel, and data transmission on the first channel between the first port and the second port is resumed.
[0108] In other embodiments, when the performance data of a port meets the shutdown conditions indicated by the energy-saving policy, the state of the channel corresponding to the port in the network device is adjusted, instructing the link layer to stop transmitting data. Understandably, the physical layer applies back pressure to the link layer, i.e., prohibiting the link layer from transmitting data to the physical layer and ensuring that data transmission on the link corresponding to the port is completed, thereby preventing data loss during the shutdown process.
[0109] For example, as shown in Figure 6 (a), a schematic diagram of the channel state transition is shown. When the channel is in the established state, it indicates that the channel is normal; when the channel is in the unestablished state, it indicates that the channel is abnormal. When the channel is in the unestablished state, the channel can be trained. After successful training, the channel transitions from the unestablished state to the established state. When the channel is in the established state, if channel training fails, the channel transitions from the established state to the unestablished state. As shown in Figure 6 (b), the physical layer applies back pressure to the link layer. For example, SerDes instructs the link layer to stop transmitting data.
[0110] Optionally, after channel training is completed, the link layer is instructed to cancel back pressure. For example, after the state of the serdes corresponding to the first channel in the first network device is adjusted to an energy-saving state, the link layer is instructed to cancel back pressure.
[0111] The overall process of the control method provided by the present application is schematically illustrated below in conjunction with Figures 7 to 10. Figure 7 is a flow chart of an energy-saving mechanism provided by the present application. The network device starts the energy-saving agent and initializes the energy-saving agent (step 710). The network device scans the port and reads the stored configuration information (step 720). The network device reports the configuration information to the controller (step 730). The network device obtains the energy-saving policy from the controller (step 740). The network device periodically scans the performance data of the port (step 750). The network device determines whether the performance data of the port meets the enable condition (step 760).
[0112] When the performance data of the port does not meet the opening condition, the network device determines whether the performance data of the port meets the closing condition (step 770).
[0113] When the performance data of the port meets the shutdown conditions, back pressure is applied to the link layer (step 780). For the sending side, determine whether to forcibly close the channel corresponding to the port (step 790). When the channel corresponding to the port is forcibly closed, at least one channel in the link state corresponding to the port is closed (step 7100). When the channel corresponding to the port is not forcibly closed, the training code stream of at least one channel in the link state corresponding to the port is closed (step 7110). Wait for the training to be completed, execute step 7100, and cancel the link layer back pressure (step 7120). For the receiving side, close at least one channel in the channel corresponding to the port (step 7130).
[0114] When the port performance data meets the opening conditions, at least one of the closed channels corresponding to the port is opened on the sending side (step 7140). On the receiving side, all closed channels corresponding to the port are opened (step 7150). After training is completed, all channels corresponding to the trained ports that have not yet received data are closed (step 7160).
[0115] Figure 8 is a flowchart of a forced channel closure process provided by the present application. 1. The energy-saving agent on the sending side detects that the port load is lower than the energy-saving threshold; 2. The energy-saving agent on the sending side notifies the physical layer on the sending side to implement back pressure; 3. The physical layer back pressures the link layer on the sending side; 4. The energy-saving agent on the sending side determines that the back pressure is effective and the data is sent; 5. The energy-saving agent on the sending side selects n channels according to the energy-saving strategy and closes the serdes corresponding to the n channels; 6. Closes the serdes corresponding to the n channels; 7. The energy-saving agent on the sending side determines that the closure is effective; 8. The energy-saving agent on the sending side notifies the physical layer on the sending side to cancel the back pressure; 9. The physical layer cancels the back pressure to the link layer on the sending side. 10. The physical layer on the receiving side detects an abnormality and starts training; 11. After training, the receiving side corresponding to the channel closed by the sending side does not receive the training code stream; 12. Close the serdes of the channel that does not receive the training code stream; 13. The serdes is closed.
[0116] Figure 9 is a flowchart of a non-forced channel closure process provided by the present application. 1. Detecting that the port load is lower than the energy-saving threshold; 2. The energy-saving agent on the sending side notifies the physical layer on the sending side to implement back pressure; 3. The physical layer back pressures the link layer on the sending side; 4. The energy-saving agent on the sending side determines that the back pressure is effective and the data is sent; 5. The energy-saving agent on the sending side selects n channels according to the energy-saving strategy and closes the training code streams corresponding to the n channels; 6. Closes the training code streams corresponding to the n channels; 7. Delays and waits for training to complete; 8. Training is completed; 9. The energy-saving agent on the sending side notifies the serdes corresponding to the n channels to close; 10. Closes the serdes corresponding to the n channels; 11. The energy-saving agent on the sending side notifies the physical layer on the sending side to cancel back pressure; 12. The physical layer cancels back pressure to the link layer on the sending side. 13. The physical layer on the receiving side detects an abnormality and starts training; 14. After training, the receiving side corresponding to the channel closed by the sending side does not receive training data; 15. Closes the serdes of the channel that did not receive training data; 16. The serdes is closed.
[0117] Figure 10 is a schematic diagram of a process for opening a channel provided by the present application. 1. The energy-saving agent on the sending side detects that the port load is higher than the energy-saving threshold; 2. The energy-saving agent on the sending side selects n channels according to the energy-saving strategy and opens the serdes corresponding to the n channels; 3. Opens the serdes corresponding to the n channels; 4. Trains the n channels; 5. Delays and waits for the training to complete; 6. The training is completed; 7. After training, n channels are opened at both ends, but n channels are in an inoperative state. 8. The energy-saving agent on the receiving side detects that the port load is higher than the energy-saving threshold; 9. Opens the serdes corresponding to all closed channels; 10. Opens the serdes; 11. Trains all channels; 12. Delays and waits for the training to complete; 13. Trains channels at both ends. If both ends open the channel training successfully, and either end does not open it, the training fails; 14. The training is completed; 15. Closes the serdes of the channel that failed training; 16. The serdes is closed.
[0118] For detailed explanation of FIG. 7 to FIG. 10 , reference may be made to the description of the above embodiment.
[0119] Next, the control method provided by the present application described in the above embodiment is illustrated with reference to FIG11 and FIG12 .
[0120] Assume that network device A includes ports A1 through A4. Network device B includes ports B1 through B4. Port A1 of network device A is connected to port B1 of network device B via link 1. Port A1 is used to send data, and port B1 is used to receive data. Network device A sends data to network device B via port A1, which is transmitted over link 1. Network device B receives the data sent by network device A via port B1. Port A2 of network device A is connected to port B2 of network device B via link 2. Port A2 is used to receive data, and port B2 is used to send data. Each link consists of two channels.
[0121] Network devices A and B are configured with energy-saving agents. These agents adjust the opening and closing of the corresponding channels based on the energy-saving policies and performance data obtained from the controller. The channel closing process shown in Figures 11 (a) through (c) represents the energy-saving process. The channel opening process shown in Figures 11 (d) through (f) represents the energy-raising process.
[0122] As shown in Figure 11 (a), the performance data of port A1 meets the shutdown conditions indicated by the energy-saving policy, so channel 1 corresponding to port A1 is shut down. The performance data of port A4 meets the shutdown conditions indicated by the energy-saving policy, so channel 1 corresponding to port A4 is shut down. The performance data of port B2 meets the shutdown conditions indicated by the energy-saving policy, so channel 2 corresponding to port B2 is shut down.
[0123] As shown in Figure 11 (b), network device A stops sending the training stream. Network device B does not receive the training stream through channel 1 corresponding to port B1. Network device B then determines that port B1 is in an inoperative state, and the performance data of port B1 meets the shutdown condition indicated by the energy-saving policy. After training on channel 1 corresponding to port A4 and channel 2 corresponding to port B2, network device B determines that port B4 is in an inoperative state, and the performance data of port B4 meets the shutdown condition indicated by the energy-saving policy. Network device A then determines that port A2 is in an inoperative state, and that the performance data of port A2 meets the shutdown condition indicated by the energy-saving policy.
[0124] As shown in (c) of Figure 11, the performance data for port B1 meets the shutdown conditions indicated by the energy-saving policy, so channel 1 corresponding to port B1 is shut down. The performance data for port B4 also meets the shutdown conditions indicated by the energy-saving policy, so channel 1 corresponding to port B4 is shut down. The performance data for port A2 also meets the shutdown conditions indicated by the energy-saving policy, so channel 2 corresponding to port A2 is shut down.
[0125] As shown in (d) of Figure 11, the performance data of port A1 meets the power-saving policy's activation conditions. Therefore, channel 1 corresponding to port A1 is activated. Channel 2 corresponding to port A2 is activated. Channel 1 corresponding to port B4 is activated. Channel 1 corresponding to port B1 is activated.
[0126] As shown in Figure 11 (e), after port A1 of network device A and port B1 of network device B successfully train over channel 1 in link 1, data transmission resumes. After port A2 of network device A and port B2 of network device B successfully train over channel 2 in link 2, data transmission resumes. Channel 1 corresponding to port A4 of network device A is closed, and training fails.
[0127] As shown in Figure 11(f), after channel 1 of port B4 is enabled, no data is received through channel 1 of port B4, so channel 1 corresponding to port B4 is disabled. Port A4 of network device A and port B2 of network device B are in an energy-saving state through channel 1 of link 4.
[0128] Figure 12 (a) is a schematic diagram of energy-saving instruction issuance provided by this application. The control chip in the network device runs an energy-saving agent application, which sends monitoring and commands to the SerDes. When performance data meets the shutdown conditions indicated by the energy-saving policy, back pressure is applied to shut down the SerDes corresponding to the channel. Figure 12 (b) is a schematic diagram of energy-saving instruction issuance provided by this application.
[0129] The network device A is used as the sending end (A end) and the network device B is used as the receiving end (B end) for explanation.
[0130] a) The service code stream is transmitted through M channels of serdes;
[0131] b) The energy-saving agent at end A detects that the load on the serdes interface is lower than the preset data traffic threshold;
[0132] c) The physical layer at end A turns on the back pressure signal to the link layer to stop transmitting data to the physical layer;
[0133] d) The energy-saving agent at end A controls and shuts down the serdes of n channels on the sending side;
[0134] e) Some channels on the receiving side of terminal B do not receive data streams and start retraining the link;
[0135] f) The physical layer of end A cooperates with end B to retrain the link;
[0136] g) End A and end B re-establish the link using the (MN) channel;
[0137] h) The physical layer at end A turns off the back pressure signal to the link layer, and the link layer prepares to transmit data to the physical layer;
[0138] i) The link layer at end B sends a retransmission request to the link layer at end A;
[0139] j) End A responds to the retransmission request and starts transmitting data to End B;
[0140] k) The energy-saving agent at end A sends a command to the energy-saving agent at end B, controlling end B to shut down the receiving side of the serdes of the N channels that are not linked.
[0141] The above embodiments are described by taking as an example an adjustment of the state of a channel corresponding to a port in a network device according to the performance data of the port, and energy saving is implemented on the channel corresponding to each port.
[0142] In other embodiments, the multiple ports included in the network device are taken as a port group, and energy saving is implemented for the port group as a whole. The difference from the above embodiment is that the performance data of the network device obtained may refer to the performance data of the entire network device. For example, the performance data of the network device includes the sum of the performance data of each port included in the network device. When the performance data of the network device meets the shutdown condition indicated by the energy-saving policy, at least one port among the multiple ports included in the network device is closed, that is, all channels corresponding to the port are closed. For example, the port with the smallest load among the multiple ports included in the network device is closed. When the performance data of the network device meets the opening condition indicated by the energy-saving policy, at least one port among the multiple ports included in the network device is opened, that is, at least one closed channel corresponding to the port is opened.
[0143] Optionally, before closing at least one of the multiple ports included in the network device, traffic on the at least one port may be migrated to a port in the network device that does not need to be closed, thereby avoiding data transmission failure after closing the at least one port.
[0144] It should be noted that the status of at least one of the ports between the sending-side network device and the receiving-end network device is retained as open to ensure that the link between the sending-side network device and the receiving-end network device transmits data. The sending-side network device sends data based on the at least one reserved link, and the receiving-end network device receives data based on the at least one reserved link, thereby facilitating the judgment of whether to open the closed receiving port based on the performance data of the receiving-end network device.
[0145] For a detailed explanation of adjusting the state of the port, please refer to the description of the state of the channel corresponding to the port in the above embodiment, which will not be repeated here.
[0146] For example, as shown in FIG13 , it is a flow chart of a control method provided by the present application.
[0147] 1. There are M ports between network device A and network device B. These ports share the traffic between network device A and network device B.
[0148] 2. After network device A detects that the performance data of network device A meets the conditions indicated by the energy-saving policy, it selects N ports from the ports between network device A and network device B for energy-saving operations (M>N).
[0149] a) Network device A stops sending traffic on these N ports by modifying the routing or traffic load sharing configuration, and then shuts down the sending direction of these N ports to enter the energy-saving state.
[0150] b) If the receiving side of the corresponding port of network device B detects a port abnormality, network device B stops sending traffic on N ports by modifying the routing or traffic load sharing configuration, and then closes the sending direction of N ports.
[0151] c) Network device B detects an abnormality in the N ports of network device A, and then network device B shuts down the receiving side of the N ports that detected the abnormality, so that the N ports of network device A completely enter the energy-saving state.
[0152] d) If network device B also needs to take energy-saving measures for the ports between network device A and network device B based on load, network device B shuts down the receiving sides of the N ports that are in abnormal states.
[0153] 3. After network device A and network device B detect that the bidirectional traffic load between network devices A and B exceeds the energy-saving threshold, they perform energy-saving operations on N interfaces between network devices A and B that are in energy-saving state:
[0154] a) Network device A opens the interface that was shut down for energy saving.
[0155] b) Network device B turns on the interface that was shut down for energy saving.
[0156] It is understandable that in order to implement the functions in the above embodiments, the controller includes hardware structures and / or software modules that perform the corresponding functions. Those skilled in the art should easily appreciate 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 the form of hardware or computer software driving hardware depends on the specific application scenario and design constraints of the technical solution.
[0157] The control method provided by the present application is described in detail above with reference to FIG. 1 to FIG. 13 . The control device provided by the present application will be described below with reference to FIG. 14 .
[0158] Figure 14 is a schematic diagram of the structure of possible control devices provided by this application. These control devices can be used to implement the functions of the controller in the above method embodiments, thereby also achieving the beneficial effects of the above method embodiments. In this embodiment, the control device can be a network device as shown in Figure 3, or a module (such as a chip) applied to a server.
[0159] As shown in Figure 14, the control device 1400 includes a communication module 1410, an energy consumption control module 1420, and a storage module 1430. The control device 1400 is used to implement the functions of the network device in the method embodiment shown in Figure 3 above.
[0160] The communication module 1410 is used to obtain the energy-saving policy of the network device, which is used to indicate the conditions for opening or closing the port or the channel corresponding to the port of the network device. For example, the communication module 1410 is used to execute step 310 in Figure 3.
[0161] Energy consumption control module 1420 is configured to obtain performance data of the network device and, based on the energy-saving policy and the performance data, adjust the state of the port or the channel corresponding to the port. The state may include open or closed. The performance data indicates the operating characteristics of the port of the network device during the current cycle. For example, energy consumption control module 1420 is configured to execute steps 320 and 330 in FIG. 3 .
[0162] The storage module 1430 is used to store energy-saving strategies, performance data, and status, so that the energy consumption control module 1420 can adjust the status of the port or the channel corresponding to the port according to the energy-saving strategies and performance data.
[0163] It should be understood that the control device 1400 of the embodiment of the present application can be implemented by an application-specific integrated circuit (ASIC) or a programmable logic device (PLD), wherein the PLD can be a complex programmable logical device (CPLD), a field-programmable gate array (FPGA), a generic array logic (GAL), or any combination thereof. Alternatively, when the control method shown in FIG. 3 is implemented by software, the control device 1400 and its modules can also be software modules.
[0164] According to the embodiment of the present application, the control device 1400 can correspond to executing the method described in the embodiment of the present application, and the above-mentioned and other operations and / or functions of each unit in the control device 1400 are respectively for implementing the corresponding processes of each method in Figure 3. For the sake of brevity, they will not be repeated here.
[0165] Figure 15 is a schematic diagram of the structure of a network device 1500 provided in this application. As shown in the figure, network device 1500 includes a control chip 1510, a bus 1520, a memory 1530, a communication interface 1540, a memory unit 1550 (also called a main memory unit), and a switch chip 1560. Switch chip 1560 includes a serial-to-parallel converter 1561. Control chip 1510, switch chip 1560, memory 1530, memory unit 1550, and communication interface 1540 are connected via bus 1520.
[0166] It should be understood that in this embodiment, the control chip 1510 may be a CPU, but may also be other general-purpose processors, digital signal processors (DSP), ASICs, FPGAs or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc.
[0167] The processor may also be a graphics processing unit (GPU), a neural network processing unit (NPU), a microprocessor, an ASIC, or one or more integrated circuits for controlling the execution of the program of the present application.
[0168] Communication interface 1540 is used to enable communication between network device 1500 and external devices or components. In this embodiment, when network device 1500 is used to implement the functions of the network device shown in Figure 3, communication interface 1540 is used to obtain energy-saving strategies and performance data so that control chip 1510 can adjust the status of the port or the channel corresponding to the port based on the energy-saving strategy and performance data, including whether the status is open or closed.
[0169] Bus 1520 may include a path for transmitting information between the aforementioned components (e.g., control chip 1510, memory unit 1550, storage 1530, and switch chip 1560). In addition to a data bus, bus 1520 may also include a power bus, a control bus, and a status signal bus. However, for the sake of clarity, various buses are labeled as bus 1520 in the figure. Bus 1520 may be a Peripheral Component Interconnect Express (PCIe) bus, an extended industry standard architecture (EISA) bus, a unified bus (Ubus or UB), a compute express link (CXL), a cache coherent interconnect for accelerators (CCIX), etc. Bus 1520 may be divided into an address bus, a data bus, a control bus, etc.
[0170] As an example, the control chip 1510 may be a multi-core (multi-CPU) control chip. The control chip herein may refer to one or more devices, circuits, and / or computing units for processing data (eg, computer program instructions).
[0171] It is worth noting that Figure 15 only takes the network device 1500 including 1 control chip 1510 and 1 memory 1530 as an example. Here, the control chip 1510 and the memory 1530 are respectively used to indicate a type of device or equipment. In a specific embodiment, the number of each type of device or equipment can be determined according to business requirements.
[0172] Memory unit 1550 may be a volatile memory pool or a nonvolatile memory pool, or may include both volatile and nonvolatile memories. Nonvolatile memories may be read-only memories (ROM), programmable ROM (PROM), erasable programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memories may be random access memories (RAM), which serve as external cache memory. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic random access memory (DRAM), synchronous DRAM (SDRAM), double data rate synchronous DRAM (DDR SDRAM), enhanced synchronous DRAM (ESDRAM), synchronous link DRAM (SLDRAM), and direct RAM bus RAM (DR RAM). Memory unit 1550 is used to store information such as power saving policies, performance data, and status.
[0173] The memory 1530 may correspond to a storage medium used to store information such as energy-saving strategies, performance data, and status in the above method embodiments, for example, a disk such as a mechanical hard disk or a solid-state drive.
[0174] The network device 1500 may be a general-purpose device or a dedicated device. For example, the network device 1500 may be an edge device (e.g., a box carrying a chip with processing capabilities). Alternatively, the network device 1500 may be a server or other device with computing capabilities.
[0175] It should be understood that the network device 1500 according to this embodiment may correspond to the control device 1400 in this embodiment, and may correspond to the corresponding subject executing any method in Figure 3, and the above-mentioned and other operations and / or functions of each module in the control device 1400 are respectively for implementing the corresponding processes of each method in Figure 3. For the sake of brevity, they will not be repeated here.
[0176] An embodiment of the present application provides a chip, comprising: a processor and a power supply circuit; wherein the power supply circuit is used to supply power to the processor; and the processor is used to execute the operating steps of the control method described in the above method embodiment.
[0177] The method steps in this embodiment can be implemented by hardware or by executing software instructions on a control chip. The software instructions can be composed of corresponding software modules, which can be stored in random access memory (RAM), flash memory, read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), registers, hard disks, mobile hard disks, CD-ROMs, or any other form of storage medium 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. Of course, 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 computing device. Of course, the processor and storage medium can also exist as discrete components in a computing device.
[0178] In the above embodiments, all or part of the embodiments can be implemented by software, hardware, firmware or any combination thereof. When implemented using software, all or part of the embodiments can 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 process or function described in the embodiments of the present application is performed in whole or in part. The computer can 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 instruction can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer program or instruction can be transmitted 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 can 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 can be a magnetic medium, such as a floppy disk, a hard disk, or a tape; it can also be an optical medium, such as a digital video disc (DVD); it can also be a semiconductor medium, such as a solid state drive (SSD). The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present application, and such modifications or substitutions should be included in the scope of protection of the present application. Therefore, the scope of protection of the present application should be based on the scope of protection of the claims.
Claims
1. A control method, It is characterized in that The method is executed by a first chip of a network device, and the method includes: Acquire an energy-saving strategy of the network device, where the energy-saving strategy is used to indicate a condition for opening or closing a port of the network device or a channel corresponding to the port; Acquire performance data of the network device, where the performance data is used to indicate operating characteristics of a port of the network device in a current cycle; According to the energy-saving strategy and the performance data, the state of the port or the channel corresponding to the port is adjusted, and the state includes being on or off.
2. The method according to claim 1, It is characterized in that According to the energy-saving strategy and the performance data, adjusting the state of the port or the channel corresponding to the port includes: When the performance data meets the shutdown condition indicated by the energy-saving strategy, the state of at least one port in the network device or the state of a channel corresponding to the port is adjusted according to the performance data.
3. The method according to claim 2, It is characterized in that The performance data includes at least one of an interface bandwidth occupancy rate and a queue depth.
4. The method according to any one of claims 1 to 3, It is characterized in that Adjusting the state of the channel corresponding to the port includes: The state of the serial-to-parallel converter corresponding to the channel is adjusted to migrate from an active state to a power-saving state.
5. The method according to claim 4, It is characterized in that The network device further includes a second chip, the port is used to send data, and adjusting the state of the channel corresponding to the port includes: Instruct the second chip to stop sending the training code stream and adjust the state of the channel corresponding to the port.
6. The method according to claim 4, It is characterized in that The port is used to receive data, and the state of the channel corresponding to the port is adjusted, including: When the training code stream is not received, the state of the channel corresponding to the port is adjusted.
7. The method according to any one of claims 1 to 5, It is characterized in that The port is used to send data, and the state of the channel corresponding to the port is adjusted, including: When the link layer stops transmitting data, the state of the channel corresponding to the port is adjusted.
8. The method according to any one of claims 1 to 7, It is characterized in that The state of the port or the channel corresponding to the port is closed, and the method further includes: When the performance data meets the enabling condition indicated by the energy-saving strategy, the port or the channel corresponding to the port is adjusted to be enabled.
9. The method according to claim 8, It is characterized in that Adjust the channel opening corresponding to the port, including: The state of the serial-to-parallel converter corresponding to the channel is adjusted to migrate from a power-saving state to an active state.
10. The method according to any one of claims 1 to 9, It is characterized in that Obtaining the energy saving strategy of the network device, including: An energy-saving strategy for the network device is obtained based on characteristics of the network device, wherein the characteristics of the network device include at least one of a location of the network device in the network, a scale of the network device, a configuration of the network device, and performance data of the network device.
11. A control device, It is characterized in that The control device comprises a module for executing the operation steps of any one of the methods of claims 1-10.
12. A chip, It is characterized in that The chip includes a processor and a power supply circuit; wherein the power supply circuit is used to supply power to the processor; and the processor is used to execute the operation steps of the method described in any one of claims 1 to 10.
13. A network device, It is characterized in that The network device includes a memory and a processor, wherein the memory is used to store a group of computer instructions; when the processor executes the group of computer instructions, the operation steps of the method described in any one of claims 1 to 10 are performed.
14. A communication system, It is characterized in that The communication system includes a first network device and a second network device, the first network device is used to execute the operation steps of the method described in any one of claims 1-5 and 7-10, and the second network device is used to execute the operation steps of the method described in any one of claims 1-4 and 6-10.
15. The system according to claim 14, It is characterized in that The communication system also includes a controller; the controller is used to send an energy-saving strategy to the first network device and the second network device, and the energy-saving strategy is used to indicate the conditions for opening or closing the ports of the first network device and the second network device or the channels corresponding to the ports.
Citation Information
Patent Citations
Control method, apparatus, chip, network device, and communication system
CN118842664B
Energy saving method of network equipment, apparatus thereof and equipment
CN102571367A
Method and apparatus for controlling power supply of network device, and network device
CN104662849A
Network device for controlling by using network device power supply control method
CN108337096A
Network equipment power supply control method
CN108418694A
