A bandwidth configuration method, system, device and computer readable storage medium

By generating and identifying all initial bandwidth configurations for server slots and selecting the bandwidth configuration method with the maximum number of devices, the problem of server bandwidth configuration depending on the supplier in existing technologies is solved, and flexible bandwidth configuration is achieved.

CN119728438BActive Publication Date: 2025-10-17INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202412000534.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-10-17
Estimated Expiration
2044-12-31

AI Technical Summary

Technical Problem

In the existing technology, server bandwidth configuration requires relying on suppliers to customize firmware or perform manual settings, which has poor flexibility.

Method used

By determining the total bandwidth of the target slot, all initial bandwidth configuration methods are generated, the number of devices is identified, and the bandwidth configuration method corresponding to the maximum number of devices is selected, thus achieving flexible bandwidth configuration.

Benefits of technology

It eliminates the supplier's restrictions on bandwidth allocation, improves the flexibility of bandwidth configuration, and can automatically adjust the bandwidth configuration according to the number of devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119728438B_ABST
    Figure CN119728438B_ABST
Patent Text Reader

Abstract

The application discloses a bandwidth configuration method, system, device and computer readable storage medium, relates to the technical field of servers, is applied to system firmware, determines the total bandwidth of a target slot; generates all initial bandwidth configuration modes of the target slot according to the total bandwidth; performs bandwidth configuration on the target slot according to the initial bandwidth configuration mode, and performs device identification on the target slot to obtain an initial device quantity value of the target slot under each initial bandwidth configuration mode; determines that the initial device quantity value with the maximum value is a target device quantity value; determines a target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target device quantity value; and performs bandwidth configuration on the target slot according to the target bandwidth configuration mode. The application filters the target bandwidth configuration mode by enumerating all bandwidth configuration modes and according to the identified device quantity, and is free from the limitation of bandwidth allocation by a supplier, and is high in flexibility.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of servers, and more particularly to a bandwidth configuration method, system, device and computer readable storage medium. BACKGROUND

[0002] In the use of a server, the server needs to be functionally extended according to user needs, such as by connecting different target devices to the server to extend the functions of the server. In this process, the bandwidth allocation of the server needs to be changed by the target device supplier in a firmware customization or manual setting manner to ensure that the target device can be used by the server. However, this bandwidth configuration method needs to rely on the supplier and has poor flexibility.

[0003] To sum up, how to flexibly configure the bandwidth of the server is a problem that needs to be solved by those skilled in the art. SUMMARY

[0004] The purpose of the present application is to provide a bandwidth configuration method which can solve the technical problem of how to flexibly configure the bandwidth of the server to some extent. The present application also provides a bandwidth configuration system, an electronic device and a computer readable storage medium.

[0005] In order to achieve the above-mentioned purpose, the present application provides the following technical solutions:

[0006] A bandwidth configuration method applied to a system firmware, comprising:

[0007] determining a total bandwidth of a target slot;

[0008] generating all initial bandwidth configuration modes of the target slot according to the total bandwidth;

[0009] configuring the bandwidth of the target slot according to the initial bandwidth configuration mode and identifying the devices of the target slot to obtain an initial device quantity value of the target slot under each initial bandwidth configuration mode;

[0010] determining the initial device quantity value with the maximum value as a target device quantity value;

[0011] determining a target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target device quantity value;

[0012] configuring the bandwidth of the target slot according to the target bandwidth configuration mode.

[0013] In an exemplary embodiment, the generating all initial bandwidth configuration modes of the target slot according to the total bandwidth comprises:

[0014] determining a selectable bandwidth setting value of the target slot;

[0015] The optional bandwidth setting values ​​are combined to obtain each initial bandwidth configuration mode in which the bandwidth value is equal to the total bandwidth.

[0016] In an exemplary embodiment, the system firmware includes a basic input and output system.

[0017] In an exemplary embodiment, generating all initial bandwidth configuration modes of the target slot according to the total bandwidth includes:

[0018] In the initialization phase, all initial bandwidth configuration modes of the target slot are generated according to the total bandwidth.

[0019] In an exemplary embodiment, determining the target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target number of devices includes:

[0020] Each initial bandwidth configuration mode corresponding to the target number of devices is used as a candidate bandwidth configuration mode;

[0021] Count the number of candidate bandwidth configuration methods;

[0022] Checking whether the number of candidate bandwidth configuration methods is one;

[0023] In response to the number of candidate bandwidth configuration modes being one, determining the candidate bandwidth configuration mode as the target bandwidth configuration mode;

[0024] In response to the number of candidate bandwidth configuration modes being greater than one, reading a rated bandwidth of each of the target devices;

[0025] The largest candidate bandwidth configuration mode whose maximum bandwidth value is not greater than the rated bandwidth is determined as the target bandwidth configuration mode.

[0026] In an exemplary embodiment, configuring bandwidth for the target slot according to the initial bandwidth configuration mode, identifying devices in the target slot, and obtaining an initial number of devices for the target slot under each initial bandwidth configuration mode includes:

[0027] selecting an initial bandwidth configuration mode that is not recorded in the non-volatile memory as the bandwidth configuration mode to be tested;

[0028] Performing bandwidth configuration on the target slot according to the bandwidth configuration mode to be measured, and performing device identification on the target slot to obtain an initial device quantity value of the target slot under the bandwidth configuration mode to be measured;

[0029] Storing the bandwidth configuration mode to be tested and the corresponding initial device quantity value in the non-volatile memory;

[0030] detecting whether all kinds of initial bandwidth configuration manners are stored in the non-volatile memory;

[0031] in response to that all kinds of initial bandwidth configuration manners are not stored in the non-volatile memory, controlling the server to perform the step of selecting an initial bandwidth configuration manner not recorded in the non-volatile memory as a to-be-tested bandwidth configuration manner after the server is restarted;

[0032] in response to that all kinds of initial bandwidth configuration manners are stored in the non-volatile memory, ending.

[0033] In an exemplary embodiment, after the target slot is configured with bandwidth according to the target bandwidth configuration manner, the method further comprises:

[0034] generating a correspondence between the target slot and the target bandwidth configuration manner;

[0035] storing the correspondence in the non-volatile memory.

[0036] A bandwidth configuration system applied to system firmware, comprising:

[0037] a first determining module configured to determine a total bandwidth of a target slot;

[0038] a first generating module configured to generate all initial bandwidth configuration manners of the target slot according to the total bandwidth;

[0039] a first configuring module configured to configure the target slot with bandwidth according to an initial bandwidth configuration manner, and to perform device identification on the target slot to obtain an initial device quantity value of the target slot under each initial bandwidth configuration manner;

[0040] a second determining module configured to determine that an initial device quantity value with a maximum value is a target device quantity value;

[0041] a third determining module configured to determine a target bandwidth configuration manner according to an initial bandwidth configuration manner corresponding to the target device quantity value;

[0042] a second configuring module configured to configure the target slot with bandwidth according to the target bandwidth configuration manner.

[0043] An electronic device, comprising:

[0044] a memory configured to store a computer program;

[0045] a processor configured to implement steps of the bandwidth configuration method according to any one of the above when executing the computer program.

[0046] A computer-readable storage medium stores a computer program, wherein the computer program implements the steps of any of the above bandwidth configuration methods when executed by a processor.

[0047] The present application provides a bandwidth configuration method, which is applied to system firmware to determine the total bandwidth of a target slot; generate all initial bandwidth configuration modes for the target slot based on the total bandwidth; configure bandwidth for the target slot according to the initial bandwidth configuration modes, identify devices in the target slot, and obtain an initial device quantity value for the target slot under each initial bandwidth configuration mode; determine the initial device quantity value with the largest value as the target device quantity value; determine a target bandwidth configuration mode based on the initial bandwidth configuration mode corresponding to the target device quantity value; and configure bandwidth for the target slot according to the target bandwidth configuration mode. The system firmware in this application only needs to know the total bandwidth of the target slot, and can generate all the initial bandwidth configuration methods of the target slot based on the total bandwidth, that is, exhaustively enumerate all the initial bandwidth configuration methods of the target slot. Then, considering that the initial bandwidth configuration method is compatible with the device on the target slot, all the devices on the target slot will be identified, that is, the maximum number of devices will be obtained. Therefore, the initial device quantity value of the target slot under each initial bandwidth configuration method can be determined. The final target bandwidth configuration method of the target slot can be determined based on the initial bandwidth configuration method corresponding to the initial device quantity value with the largest value. This achieves the goal of filtering the target bandwidth configuration method by exhaustively enumerating all bandwidth configuration methods and screening the target bandwidth configuration method based on the number of identified devices, getting rid of the supplier's restrictions on bandwidth allocation, and having high flexibility. The bandwidth configuration system, electronic device and computer-readable storage medium provided by this application also solve corresponding technical problems. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are merely embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without any creative work.

[0049] Figure 1 A flow chart of a bandwidth configuration method provided in an embodiment of the present application;

[0050] Figure 2 A schematic diagram of the structure of a bandwidth configuration system provided in an embodiment of the present application;

[0051] Figure 3 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application;

[0052] Figure 4Another structural schematic diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0053] The technical solutions in the embodiments of the present application will be clearly and completely described with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, but not all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by a person of ordinary skill in the art without creative work fall within the protection scope of the present application.

[0054] Please refer to Figure 1 , Figure 1 A flowchart of a bandwidth configuration method provided by an embodiment of the present application.

[0055] The bandwidth configuration method provided by an embodiment of the present application is applied to a system firmware and can include the following steps.

[0056] Step S101: Determine the total bandwidth of the target slot.

[0057] Step S102: Generate all initial bandwidth configuration modes of the target slot according to the total bandwidth.

[0058] In actual application, the bandwidth allocated to each slot has an upper limit, that is, the total bandwidth of the slot is fixed, and the bandwidth allocated to the slot by the system firmware needs to be equal to the total bandwidth, so the system firmware needs to determine the total bandwidth of the target slot and generate all initial bandwidth configuration modes of the target slot according to the total bandwidth, and each initial bandwidth configuration mode makes the bandwidth of the target slot equal to the total bandwidth.

[0059] Step S103: Perform bandwidth configuration on the target slot according to the initial bandwidth configuration mode, and perform device identification on the target slot to obtain an initial device quantity value of the target slot under each initial bandwidth configuration mode.

[0060] In actual application, after the system firmware obtains all initial bandwidth configuration modes of the target slot, the system firmware can perform bandwidth configuration on the target slot according to each initial bandwidth configuration mode. Since the target slot can be identified after the bandwidth configuration, the target slot can be identified next to obtain an initial device quantity value of the target slot under each initial bandwidth configuration mode, so as to determine the final bandwidth configuration mode of the target slot by using the initial device quantity value of the target slot under each initial bandwidth configuration mode subsequently.

[0061] Step S104: Determine the initial device quantity value with the maximum value as the target device quantity value.

[0062] Step S105: determining the target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target device quantity value.

[0063] Step S106: configuring the target slot according to the target bandwidth configuration mode.

[0064] In practical application, considering that the bandwidth configuration mode of the target slot will affect the recognized device quantity, for example, the total bandwidth of the target slot is x16, the initial bandwidth configuration mode is x8x8, assuming that the target device is two x8 devices, then the initial device quantity value under this configuration mode is 2, assuming that the initial bandwidth configuration mode is x16, only one device can be detected, that is, the initial device quantity value under this configuration mode is 1, by comparison, the initial bandwidth configuration mode corresponding to the initial device quantity value with the maximum value matches the target bandwidth configuration mode, so it can be determined that the initial device quantity value with the maximum value is the target device quantity value, the target bandwidth configuration mode is determined according to the initial bandwidth configuration mode corresponding to the target device quantity value, and finally the target slot is configured according to the target bandwidth configuration mode.

[0065] In a specific application scenario, in the process of generating all initial bandwidth configuration modes of the target slot according to the total bandwidth, considering that the total bandwidth only limits the total bandwidth of the target slot, and the bandwidth of the target slot is composed of multiple setting values, the selectable bandwidth setting values of the target slot can be determined; each initial bandwidth configuration mode with a bandwidth value equal to the total bandwidth is obtained by combining the selectable bandwidth setting values.

[0066] In a specific application scenario, in the process of combining the optional bandwidth setting values to obtain each initial bandwidth configuration mode with a bandwidth value equal to the total bandwidth, the optional bandwidth setting values can be combined randomly to obtain each initial bandwidth configuration mode with a bandwidth value equal to the total bandwidth, or each initial bandwidth configuration mode can be obtained by combining the optional bandwidth setting values. For example, each optional bandwidth value setting value can be taken as a reference bandwidth setting value, and an unselected reference bandwidth setting value can be selected as a selected bandwidth setting value. The difference between the total bandwidth and the selected bandwidth setting value is generated, and the optional bandwidth setting value that is not greater than the difference is taken as a candidate bandwidth setting value. An unselected candidate bandwidth setting value is selected as a selected bandwidth setting value. It is detected whether the selected bandwidth setting value is equal to the total bandwidth. If the selected bandwidth setting value is less than the total bandwidth, the step of selecting an unselected candidate bandwidth setting value as a selected bandwidth setting value is returned. If the selected bandwidth setting value is equal to the total bandwidth, the selected bandwidth setting value is taken as an initial bandwidth configuration mode. It is detected whether there is a candidate bandwidth setting value that has not been combined with the reference bandwidth setting value. If there is a candidate bandwidth setting value that has not been combined with the reference bandwidth setting value, the step of generating the difference between the total bandwidth and the selected bandwidth setting value is returned to generate a new initial bandwidth configuration mode based on the reference bandwidth setting value. If all candidate bandwidth setting values have been combined with the reference bandwidth setting value, the step of selecting an unselected reference bandwidth setting value as a selected bandwidth setting value is returned to generate a new initial bandwidth configuration mode based on a new reference bandwidth setting value. Until all reference bandwidth setting values are selected, all initial bandwidth configuration modes are obtained.

[0067] According to the implementation process, in the process of combining the optional bandwidth setting values to obtain each initial bandwidth configuration mode with a bandwidth value equal to the total bandwidth, each optional bandwidth value setting value is taken as a reference bandwidth setting value. By selecting the reference bandwidth setting value, the initial bandwidth configuration mode based on the optional bandwidth setting value can be obtained. After an unselected reference bandwidth setting value is selected as a selected bandwidth setting value, the candidate bandwidth setting value can be determined according to the difference between the total bandwidth and the selected bandwidth setting value. The candidate bandwidth setting value and the current reference bandwidth setting value are combined to obtain various initial bandwidth configuration modes under the reference bandwidth setting value. In addition, other initial bandwidth configuration modes can be obtained by updating the reference bandwidth setting value. The initial bandwidth configuration modes can be enumerated by updating and combining the reference bandwidth setting value and the corresponding candidate bandwidth setting value. There is no missing initial bandwidth configuration mode, which ensures the enumeration accuracy of the initial bandwidth configuration mode.

[0068] In a specific application scenario, in the process of generating all initial bandwidth configuration modes of the target slot according to the total bandwidth, the system firmware can generate all initial bandwidth configuration modes of the target slot according to the total bandwidth in the initialization (PEI) stage, that is, the method can be applied to the initialization stage of the system firmware. In addition, the type of the system firmware can be flexibly determined according to actual needs, such as the system firmware can be a basic input output system (BIOS) and the like.

[0069] In a specific application scenario, in the process of determining the target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target device quantity value, the system firmware can further determine the target bandwidth configuration mode according to the rated bandwidth of the target device, that is, each initial bandwidth configuration mode corresponding to the target device quantity value can be regarded as a candidate bandwidth configuration mode; the number of candidate bandwidth configuration modes is counted; it is detected whether the number of candidate bandwidth configuration modes is one; in response to the number of candidate bandwidth configuration modes being one, the candidate bandwidth configuration mode is determined as the target bandwidth configuration mode; in response to the number of candidate bandwidth configuration modes being greater than one, the rated bandwidth of each target device is read; the candidate bandwidth configuration mode with the maximum bandwidth value not greater than the rated bandwidth and the maximum is determined as the target bandwidth configuration mode, that is, the candidate bandwidth configuration mode with the bandwidth value not greater than the rated bandwidth and the maximum bandwidth value is determined as the target bandwidth configuration mode. In order to facilitate understanding, it is assumed that the total bandwidth of the target slot is x16, there are three initial bandwidth configuration modes in total, which are x16, x8x8 and x4x4x4, and there are two target devices with a rated bandwidth of x8, then the initial device quantity values corresponding to the three initial bandwidth configuration modes x16, x8x8 and x4x4x4 are 1, 2 and 0 respectively, at this time the selected bandwidth configuration mode is only x8x8, so the target bandwidth configuration mode can be determined as x8x8, and then it is assumed that there is one target device with a rated bandwidth of x16, then the initial device quantity values corresponding to the three initial bandwidth configuration modes x16, x8x8 and x4x4x4 are 1, 1 and 0 respectively, at this time the selected bandwidth configuration mode is x16 and x8x8, so the target bandwidth configuration mode needs to be determined as x16 according to the rated bandwidth of the target device.

[0070] In a specific application scenario, in the process that the system firmware configures the target slot with the initial bandwidth configuration mode and identifies the device of the target slot to obtain the initial device quantity value of the target slot under each initial bandwidth configuration mode, an initial bandwidth configuration mode not recorded in the non-volatile memory can be selected as the to-be-tested bandwidth configuration mode; the target slot is configured with the to-be-tested bandwidth configuration mode, and the device of the target slot is identified to obtain the initial device quantity value of the target slot under the to-be-tested bandwidth configuration mode, for example, a depth-first strategy can be used to traverse the device, if the device can be normally identified, the BDF (Bus / Device / Function) and the upper slot ID of the connected device on each port are recorded, the design generation table of each slot is obtained and stored in the non-volatile memory; the to-be-tested bandwidth configuration mode and the corresponding initial device quantity value are stored in the non-volatile memory; it is detected whether all kinds of initial bandwidth configuration modes are stored in the non-volatile memory; in response to that not all kinds of initial bandwidth configuration modes are stored in the non-volatile memory, the server is controlled to restart to perform the step of selecting an initial bandwidth configuration mode not recorded in the non-volatile memory as the to-be-tested bandwidth configuration mode; in response to that all kinds of initial bandwidth configuration modes are stored in the non-volatile memory, the process is ended.

[0071] From the implementation process, it can be known that the initial device quantity value of the target slot under each initial bandwidth configuration mode is recorded in the non-volatile memory, so that after the target slot is configured with a to-be-tested bandwidth configuration mode and the device of the target slot is identified to obtain the initial device quantity value of the target slot under the to-be-tested bandwidth configuration mode, the to-be-tested bandwidth configuration mode and the corresponding initial device quantity value can be stored in the non-volatile memory, so if there is a to-be-tested bandwidth configuration mode not recorded in the non-volatile memory, it indicates that the recording of the initial device quantity value corresponding to all initial bandwidth configuration modes is not completed, and the initial device quantity value corresponding to the to-be-tested bandwidth configuration mode still needs to be counted, thereby achieving the effect that the initial device quantity value corresponding to the initial bandwidth configuration mode is counted in the non-volatile memory, avoiding the situation that the initial device quantity value corresponding to the initial bandwidth configuration mode is missed, and ensuring the accuracy of the initial device quantity value.

[0072] In a specific application scenario, after the system firmware configures the target slot with the target bandwidth configuration mode, a corresponding relationship between the target slot and the target bandwidth configuration mode can be generated; the corresponding relationship is stored in the non-volatile memory, so that the corresponding relationship stored in the non-volatile memory can be directly applied to configure the bandwidth of the target slot next time.

[0073] The bandwidth configuration method provided in the application is applied to system firmware, determines the total bandwidth of a target slot, generates all initial bandwidth configuration modes of the target slot according to the total bandwidth, performs bandwidth configuration on the target slot according to the initial bandwidth configuration modes, and performs device identification on the target slot to obtain initial device quantity values of the target slot under each initial bandwidth configuration mode, determines the initial device quantity value with the maximum value as a target device quantity value, determines a target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target device quantity value, and performs bandwidth configuration on the target slot according to the target bandwidth configuration mode. The system firmware in the application only needs to know the total bandwidth of the target slot, and can generate all initial bandwidth configuration modes of the target slot according to the total bandwidth, that is, all initial bandwidth configuration modes of the target slot are exhausted, and then if the initial bandwidth configuration mode is adapted to the device on the target slot, all devices on the target slot are identified, that is, the maximum device quantity is obtained, so that the initial device quantity values of the target slot under each initial bandwidth configuration mode can be determined, and the target bandwidth configuration mode of the target slot can be determined according to the initial bandwidth configuration mode corresponding to the initial device quantity value with the maximum value, which realizes the selection of the target bandwidth configuration mode by exhausting all bandwidth configuration modes and according to the identified device quantity, and breaks the restriction of the supplier on bandwidth allocation, and has high flexibility.

[0074] In order to facilitate understanding of the bandwidth configuration scheme of the application, it is assumed that the system firmware is a basic input and output system, and the following steps can be performed by the basic input and output system in the process of performing bandwidth configuration on the target slot:

[0075] After entering the initialization stage, whether the bandwidth configuration switch of the target slot is turned on is detected through a user interface;

[0076] If the bandwidth configuration switch is turned on, the total bandwidth of the target slot is determined;

[0077] All initial bandwidth configuration modes of the target slot are generated according to the total bandwidth;

[0078] The value of the initialization flag bit is 1;

[0079] An initial bandwidth configuration mode that has not been selected is selected to perform bandwidth configuration on the target slot, and device identification is performed on the target slot to obtain an initial device quantity value of the target slot under the initial bandwidth configuration mode, and the value of the flag bit is increased by 1;

[0080] Whether the value of the flag bit is greater than the total number of initial bandwidth configuration modes is detected;

[0081] If the value of the flag bit is less than or equal to the total number of initial bandwidth configuration modes, the step of selecting an initial bandwidth configuration mode that has not been selected to perform bandwidth configuration on the target slot is returned;

[0082] If the value of the flag is greater than the total number of initial bandwidth configuration modes, the initial device quantity value with the maximum value is determined as the target device quantity value;

[0083] Each initial bandwidth configuration mode corresponding to the target device quantity value is taken as a candidate bandwidth configuration mode;

[0084] The number of candidate bandwidth configuration modes is counted;

[0085] It is detected whether the number of candidate bandwidth configuration modes is one;

[0086] In response to the number of candidate bandwidth configuration modes being one, the candidate bandwidth configuration mode is determined as the target bandwidth configuration mode;

[0087] In response to the number of candidate bandwidth configuration modes being greater than one, the rated bandwidth of each target device is read; the candidate bandwidth configuration mode with the maximum bandwidth value not greater than the rated bandwidth and the maximum value is determined as the target bandwidth configuration mode;

[0088] The target bandwidth configuration mode is written into the non-volatile memory and a restart is set;

[0089] After the restart, the target bandwidth configuration mode in the non-volatile memory is read, and the target slot is configured with bandwidth according to the target bandwidth configuration mode.

[0090] Please refer to Figure 2 , Figure 2 A structure schematic diagram of a bandwidth configuration system provided by an embodiment of the present application.

[0091] The bandwidth configuration system provided by an embodiment of the present application is applied to a system firmware and can include:

[0092] A first determination module 101 is configured to determine the total bandwidth of the target slot;

[0093] A first generation module 102 is configured to generate all initial bandwidth configuration modes of the target slot according to the total bandwidth;

[0094] A first configuration module 103 is configured to configure the target slot with bandwidth according to the initial bandwidth configuration mode, and identify the target slot to obtain an initial device quantity value of the target slot under each initial bandwidth configuration mode;

[0095] A second determination module 104 is configured to determine the initial device quantity value with the maximum value as a target device quantity value;

[0096] A third determination module 105 is configured to determine the target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target device quantity value;

[0097] The second configuration module 106 is configured to perform bandwidth configuration on the target slot according to the target bandwidth configuration mode.

[0098] The bandwidth configuration system provided in the embodiments of the present application is applied to system firmware, and the first generation module can include:

[0099] The first determination unit is configured to determine an optional bandwidth setting value of the target slot.

[0100] The first combination unit is configured to combine the optional bandwidth setting value to obtain each initial bandwidth configuration mode with a bandwidth value equal to the total bandwidth.

[0101] The bandwidth configuration system provided in the embodiments of the present application is applied to system firmware, and the system firmware includes a basic input / output system.

[0102] The bandwidth configuration system provided in the embodiments of the present application is applied to system firmware, and the first generation module can include:

[0103] The first generation unit is configured to generate all initial bandwidth configuration modes of the target slot according to the total bandwidth in an initialization stage.

[0104] The bandwidth configuration system provided in the embodiments of the present application is applied to system firmware, and the third determination module can include:

[0105] The first setting unit is configured to take each initial bandwidth configuration mode corresponding to the target device quantity value as a candidate bandwidth configuration mode.

[0106] The first statistical unit is configured to count the number of the candidate bandwidth configuration modes.

[0107] The first detection unit is configured to detect whether the number of the candidate bandwidth configuration modes is one. In response to the number of the candidate bandwidth configuration modes being one, the candidate bandwidth configuration mode is determined as the target bandwidth configuration mode. In response to the number of the candidate bandwidth configuration modes being greater than one, the rated bandwidth of each target device is read, and the candidate bandwidth configuration mode with a maximum bandwidth value not greater than the rated bandwidth is determined as the target bandwidth configuration mode.

[0108] The bandwidth configuration system provided in the embodiments of the present application is applied to system firmware, and the first configuration module can include:

[0109] The first selection unit is configured to select an initial bandwidth configuration mode not recorded in a nonvolatile memory as a to-be-tested bandwidth configuration mode.

[0110] The first configuration unit is configured to perform bandwidth configuration on the target slot according to the to-be-tested bandwidth configuration mode, and perform device identification on the target slot to obtain an initial device quantity value of the target slot under the to-be-tested bandwidth configuration mode.

[0111] The first storage unit is configured to store the to-be-tested bandwidth configuration mode and the corresponding initial device quantity value in the non-volatile memory.

[0112] The second detection unit is configured to detect whether all kinds of initial bandwidth configuration modes are stored in the non-volatile memory. In response to the fact that all kinds of initial bandwidth configuration modes are not stored in the non-volatile memory, the server is controlled to perform the step of selecting an initial bandwidth configuration mode not recorded in the non-volatile memory as the to-be-tested bandwidth configuration mode after being restarted. In response to the fact that all kinds of initial bandwidth configuration modes are stored in the non-volatile memory, the process ends.

[0113] The bandwidth configuration system provided by the embodiment of the present application is applied to a system firmware, and further includes:

[0114] The second generation module is configured to generate a correspondence between the target slot and the target bandwidth configuration mode after the second configuration module performs bandwidth configuration on the target slot according to the target bandwidth configuration mode.

[0115] The first storage module is configured to store the correspondence in the non-volatile memory.

[0116] The present application further provides an electronic device and a computer readable storage medium, both of which have the corresponding effects of the bandwidth configuration method provided by the embodiment of the present application. Please refer to Figure 3 , Figure 3 FIG. 1 is a structural schematic diagram of an electronic device provided by the embodiment of the present application.

[0117] The electronic device provided by the embodiment of the present application includes a memory 201 and a processor 202. The memory 201 stores a computer program. When the processor 202 executes the computer program, the steps of the bandwidth configuration method described in any one of the above embodiments are implemented.

[0118] Please refer to Figure 4The electronic device provided in another embodiment of the present application can further include: an input port 203 connected to the processor 202, configured to transmit an externally input command to the processor 202; a display unit 204 connected to the processor 202, configured to display a processing result of the processor 202 to the outside world; and a communication module 205 connected to the processor 202, configured to realize communication between the electronic device and the outside world. The display unit 204 can be a display panel, a laser scanning display, or the like. The communication module 205 can adopt a communication mode including but not limited to a Mobile High-Definition Link (MHL) technology, a Universal Serial Bus (USB) technology, a High-Definition Multimedia Interface (HDMI) technology, a wireless connection technology such as a WIreless Fidelity (WiFi) technology, a Bluetooth communication technology, a low-power Bluetooth communication technology, and an IEEE 802.11s-based communication technology.

[0119] The computer readable storage medium provided in the embodiment of the present application stores a computer program, and the computer program is executed by a processor to implement the steps of the bandwidth configuration method described in any one of the above embodiments.

[0120] The computer readable storage medium involved in the present application includes a Random Access Memory (RAM), a memory, a Read-Only Memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable magnetic disk, a Compact Disc Read-Only Memory (CD-ROM), or any other form of storage medium known in the technical field.

[0121] The computer program product provided in the embodiment of the present application includes a computer program / instruction, and the computer program / instruction is executed by a processor to implement the steps of the bandwidth configuration method described in any one of the above embodiments.

[0122] The bandwidth configuration system, the electronic device, and the related part of the computer readable storage medium provided in the embodiment of the present application are described in detail in the corresponding part of the bandwidth configuration method provided in the embodiment of the present application, and will not be described here again. In addition, the part of the above technical solution provided in the embodiment of the present application which is consistent with the implementation principle of the corresponding technical solution in the prior art is not described in detail, so as to avoid excessive description.

[0123] It is also to be noted that, as used in this specification and the appended claims, the singular forms "a," "an," and "the" include plural referents unless the context clearly dictates otherwise. Thus, for example, reference to "a component" can include a combination of two or more components, and the term "an element" can include comparable reference to a plurality of elements. Additionally, the term "or" as used herein means any one member of a logical disjunction (i.e., it is equivalent to "or" and "or else") and not a logical exclusion. Also, the terms "comprise," "comprising," "include," "including," and the like mean "including but not limited to." Furthermore, the terms "first," "second," "third," etc. are used merely as labels, and are not intended to impose numerical requirements on their objects.

[0124] The above description of disclosed embodiments provides examples, and is not intended to be limiting. Numerous modifications of the embodiments, as defined herein, will be apparent to those skilled in the art, and will be encompassed within the spirit or scope of the application. Accordingly, the scope of the application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A bandwidth configuration method, characterized in that: Applied to system firmware, including: Determine the total bandwidth of the target slot; generating all initial bandwidth configuration modes of the target slot according to the total bandwidth; Performing bandwidth configuration on the target slot according to the initial bandwidth configuration mode, and performing device identification on the target slot to obtain an initial device quantity value of the target slot under each initial bandwidth configuration mode; Determine the maximum initial device quantity value as the target device quantity value; Determining a target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target number of devices; Performing bandwidth configuration on the target slot according to the target bandwidth configuration method; The step of determining the target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target number of devices includes: Each initial bandwidth configuration mode corresponding to the target number of devices is used as a candidate bandwidth configuration mode; Count the number of candidate bandwidth configuration methods; Checking whether the number of candidate bandwidth configuration methods is one; In response to the number of candidate bandwidth configuration modes being one, determining the candidate bandwidth configuration mode as the target bandwidth configuration mode; In response to the number of candidate bandwidth configuration modes being greater than one, reading a rated bandwidth of each of the target devices; The largest candidate bandwidth configuration mode whose maximum bandwidth value is not greater than the rated bandwidth is determined as the target bandwidth configuration mode.

2. The method according to claim 1, characterized in that Generating all initial bandwidth configuration modes of the target slot according to the total bandwidth includes: Determining an optional bandwidth setting value for the target slot; The optional bandwidth setting values ​​are combined to obtain each initial bandwidth configuration mode in which the bandwidth value is equal to the total bandwidth.

3. The method according to claim 1, characterized in that The system firmware includes a basic input and output system.

4. The method according to claim 1, wherein Generating all initial bandwidth configuration modes of the target slot according to the total bandwidth includes: In the initialization phase, all initial bandwidth configuration modes of the target slot are generated according to the total bandwidth.

5. The method according to claim 1, wherein The step of configuring bandwidth for the target slot according to the initial bandwidth configuration mode, identifying devices for the target slot, and obtaining an initial number of devices for the target slot under each initial bandwidth configuration mode includes: selecting an initial bandwidth configuration mode that is not recorded in the non-volatile memory as the bandwidth configuration mode to be tested; Performing bandwidth configuration on the target slot according to the bandwidth configuration mode to be measured, and performing device identification on the target slot to obtain an initial device quantity value of the target slot under the bandwidth configuration mode to be measured; Storing the bandwidth configuration mode to be tested and the corresponding initial device quantity value in the non-volatile memory; Detecting whether all types of initial bandwidth configuration modes are stored in the non-volatile memory; In response to the non-volatile memory not storing all types of initial bandwidth configuration modes, controlling the server to execute the step of selecting an initial bandwidth configuration mode not recorded in the non-volatile memory as the bandwidth configuration mode to be tested after restarting; In response to all types of initial bandwidth configuration modes being stored in the non-volatile memory, the process ends.

6. The method according to claim 5, characterized in that After configuring the bandwidth of the target slot according to the target bandwidth configuration method, the method further includes: generating a correspondence between the target slot and the target bandwidth configuration mode; The corresponding relationship is stored in the non-volatile memory.

7. A bandwidth configuration system, characterized in that: Applied to system firmware, including: A first determination module is used to determine the total bandwidth of the target slot; A first generating module, configured to generate all initial bandwidth configuration modes of the target slot according to the total bandwidth; a first configuration module, configured to configure bandwidth for the target slot according to the initial bandwidth configuration mode, identify devices in the target slot, and obtain an initial number of devices for the target slot under each initial bandwidth configuration mode; A second determining module is used to determine that the maximum value of the initial number of devices is the target number of devices; A third determining module is configured to determine a target bandwidth configuration mode according to the initial bandwidth configuration mode corresponding to the target number of devices; A second configuration module is configured to configure bandwidth for the target slot according to the target bandwidth configuration method; Wherein, the third determination module includes: A first setting unit is configured to use each initial bandwidth configuration mode corresponding to the target device quantity value as a candidate bandwidth configuration mode; A first statistical unit, configured to count the number of candidate bandwidth configuration modes; The first detection unit is configured to detect whether the number of candidate bandwidth configuration modes is one; in response to the number of candidate bandwidth configuration modes being one, determining the candidate bandwidth configuration mode as the target bandwidth configuration mode; in response to the number of candidate bandwidth configuration modes being greater than one, reading the rated bandwidth of each of the target devices; and determining the largest candidate bandwidth configuration mode having a maximum bandwidth value that is not greater than the rated bandwidth as the target bandwidth configuration mode.

8. An electronic device, characterized in that: include: memory for storing computer programs; A processor, configured to implement the steps of the bandwidth configuration method according to any one of claims 1 to 6 when executing the computer program.

9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the bandwidth configuration method according to any one of claims 1 to 6 are implemented.

Citation Information

Patent Citations

  • Server slot bandwidth allocation method and device, terminal and storage medium

    CN115118605A

  • Bandwidth adjustment method and device, electronic equipment and storage medium

    CN116150067A