Dynamic rate control
Aspects of the present disclosure are directed to systems, methods, and computer readable media for dynamic data transfer rate control. One method includes alternating a network device between a plurality of supported data transfer rates that are supported by the network device to achieve an unsupported data transfer rate that is not supported by the network device. Another method includes adding one or more dummy work descriptors to a data stream, and transmitting the data stream including the one or more dummy work descriptors at a supported data transfer rate that is supported by a network device to achieve an effective unsupported data transfer rate that is not supported by the network device.
1 . A method of data transfer rate control, comprising:
receiving, by a first network device from a second network device, a selection of a target data transfer rate, wherein the target data transfer rate is an unsupported data transfer rate that is not supported by the first network device;
determining, based on the target data transfer rate, a first data transfer rate of a plurality of supported data transfer rates and a second data transfer rate different from the first data transfer rate of the plurality of supported data transfer rates, wherein each of the plurality of supported data transfer rates are supported by the first network device; and
achieving data transfer at the target data transfer rate by alternating between transferring data at the first data transfer rate and transferring data at the second data transfer rate.
2 . The method of claim 1 , wherein the first data transfer rate is higher than the target data transfer rate and the second data transfer rate is lower than the target data transfer rate.
3 . The method of claim 2 , further comprising:
determining that the first data transfer rate is a closest supported data transfer rate to the target data transfer rate that is higher than the unsupported data transfer rate;
determining that the second data transfer rate is a closest supported data transfer rate to the target data transfer rate that is lower than the unsupported data transfer rate; and
selecting the first data transfer rate and the second data transfer rate.
4 . The method of claim 2 , further comprising:
transmitting data at the second data transfer rate for a first period of time;
determining an actual amount of data transmitted at the second data transfer rate in the first period of time;
determining a nominal amount of data that would be transmitted at the target data transfer rate in the first period of time;
determining that a difference between the nominal amount of data and the actual amount of data exceeds a predetermined threshold; and
transmitting data at the first data transfer rate for a second period of time.
5 . The method of claim 1 , further comprising:
determining a nominal amount of data that would be transmitted at the target data transfer rate in a first period of time;
determining that a difference between the nominal amount of data and an actual amount of data transmitted at a first data transfer rate during the first period of time exceeds a threshold, wherein the first data transfer rate is one of the plurality of supported data transfer rates; and
responsive to exceeding the threshold, transmitting data at a second data transfer rate for a second period of time, wherein the second data transfer rate is one of the plurality of supported data transfer rates.
6 . The method of claim 5 , wherein the first period and the second period are determined based on synchronized time stamps associated with data transmitted at the first data transfer rate and the second data transfer rate.
7 . The method of claim 1 , wherein the first network device comprises at least one of a network interface card (NIC) or a data processing unit (DPU).
8 . A network device comprising:
a memory device; and
a processing device, operatively coupled with the memory device, to perform operations comprising:
receiving, by the network device from a second network device, a selection of a target data transfer rate, wherein the target data transfer rate is an unsupported data transfer rate that is not supported by the network device;
determining, based on the target data transfer rate, a first data transfer rate of a plurality of supported data transfer rates and a second data transfer rate different from the first data transfer rate of the plurality of supported data transfer rates, wherein each of the plurality of supported data transfer rates are supported by the network device; and
achieving data transfer at the target data transfer rate by alternating between transferring data at the first data transfer rate and transferring data at the second data transfer rate.
9 . The network device of claim 8 , wherein the first data transfer rate is higher than the target data transfer rate and the second data transfer rate is lower than the target data transfer rate.
10 . The network device of claim 9 , wherein the operations further comprise:
determining that the first data transfer rate is a closest supported data transfer rate to the target data transfer rate that is higher than the target data transfer rate;
determining that the second data transfer rate is a closest supported data transfer rate to the target data transfer rate that is lower than the target data transfer rate; and
selecting the first data transfer rate and the second data transfer rate.
11 . The network device of claim 9 , wherein the operations further comprise:
transmitting data at the second data transfer rate for a first period of time;
determining an actual amount of data transmitted at the second data transfer rate in the first period of time;
determining a nominal amount of data that would be transmitted at the target data transfer rate in the first period of time;
determining that a difference between the nominal amount of data and the actual amount of data exceeds a predetermined threshold; and
transmitting data at the first data transfer rate for a second period of time.
12 . The network device of claim 8 , wherein the operations further comprise:
determining a nominal amount of data that would be transmitted at the target data transfer rate in a first period of time;
determining that a difference between the nominal amount of data and an actual amount of data transmitted at a first data transfer rate during the first period of time exceeds a threshold, wherein the first data transfer rate is one of the plurality of supported data transfer rates; and
responsive to exceeding the threshold, transmitting data at a second data transfer rate for a second period of time, wherein the second data transfer rate is one of the plurality of supported data transfer rates.
13 . The network device of claim 12 , wherein the first period and the second period are determined based on synchronized time stamps associated with data transmitted at the first data transfer rate and the second data transfer rate.
14 . The network device of claim 8 , wherein the network device comprises at least one of a network interface card (NIC) or a data processing unit (DPU).
15 . A non-transitory computer-readable storage medium comprising instructions that, when executed by a processing device, cause the processing device to perform operations comprising:
receiving, by a network device different from the processing device, a selection of a target data transfer rate, wherein the target data transfer rate is an unsupported data transfer rate that is not supported by the processing device;
determining, based on the target data transfer rate, a first data transfer rate of a plurality of supported data transfer rates and a second data transfer rate different from the first data transfer rate of the plurality of supported data transfer rates, wherein each of the plurality of supported data transfer rates are supported by the network device; and
achieving data transfer at the target data transfer rate by alternating between transferring data at the first data transfer rate and transferring data at the second data transfer rate.
16 . The non-transitory computer-readable storage medium of claim 15 , wherein the first data transfer rate is higher than the target data transfer rate and the second data transfer rate is lower than the target data transfer rate.
17 . The non-transitory computer-readable storage medium of claim 16 , wherein the operations further comprise:
determining that the first data transfer rate is a closest supported data transfer rate to the target data transfer rate that is higher than the target data transfer rate;
determining that the second data transfer rate is a closest supported data transfer rate to the target data transfer rate that is lower than the target data transfer rate; and
selecting the first data transfer rate and the second data transfer rate.
18 . The non-transitory computer-readable storage medium of claim 16 , wherein the operations further comprise:
transmitting data at the second data transfer rate for a first period of time;
determining an actual amount of data transmitted at the second data transfer rate in the first period of time;
determining a nominal amount of data that would be transmitted at the target data transfer rate in the first period of time;
determining that a difference between the nominal amount of data and the actual amount of data exceeds a predetermined threshold; and
transmitting data at the first data transfer rate for a second period of time.
19 . The non-transitory computer-readable storage medium of claim 16 , wherein the operations further comprise:
determining a nominal amount of data that would be transmitted at the target data transfer rate in a first period of time;
determining that a difference between the nominal amount of data and an actual amount of data transmitted at a first data transfer rate during the first period of time exceeds a threshold, wherein the first data transfer rate is one of the plurality of supported data transfer rates; and
responsive to exceeding the threshold, transmitting data at a second data transfer rate for a second period of time, wherein the second data transfer rate is one of the plurality of supported data transfer rates.
20 . The non-transitory computer-readable storage medium of claim 19 , wherein the first period and the second period are determined based on synchronized time stamps associated with data transmitted at the first data transfer rate and the second data transfer rate.
21 . The non-transitory computer-readable storage medium of claim 15 , wherein the processing device comprises at least one of a network interface card (NIC) or a data processing unit (DPU).