Server preboot function self-adaptive supporting method and apparatus

By traversing the server network card device library, selecting target network card devices and ports, executing custom requirements and burning them to the BIOS, the problem of cumbersome and inability to customize the PXE function in the existing technology is solved, and convenient PXE function management and customization requirements are achieved. satisfaction.

WO2025025803A1PCT designated stage expired Publication Date: 2025-02-06INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/097565
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-08-01
Filing Date
2024-06-05
Publication Date
2025-02-06

AI Technical Summary

Technical Problem

When the existing technology closes the PXE function of the server network card port, the setting process is cumbersome and it is impossible to customize the PXE requirements of the customer network card, which makes it inconvenient to realize the customer's needs.

Method used

Provide an adaptive support method for server pre-start function. By traversing the network card device library, selecting the target network card device and port, performing the on and off functions corresponding to custom requirements, and compiling the requirements into version files and burning them to read-only of the BIOS in memory.

Benefits of technology

The switching process of PXE function is simplified, and the customization needs of customer network card PXE function is supported, which improves customer satisfaction and convenience of setting.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024097565_06022025_PF_FP_ABST
    Figure CN2024097565_06022025_PF_FP_ABST
Patent Text Reader

Abstract

The present disclosure relates to the technical field of computers. Disclosed are a server preboot function self-adaptive supporting method and apparatus. The method comprises: when target indication information is acquired, traversing network card devices in a network card device library, wherein the target indication information is used for representing that a target object has a customization requirement on enabling / disabling of a preboot execution environment function; selecting from among the network card devices a target network card device corresponding to the customization requirement, and a target port of the target network card device; enabling the preboot execution environment function of the target port, and disabling the preboot execution environment function of a reference port other than the target port in the target network card; and compiling the customization requirement into a version file and burning the version file into a read-only memory of a basic input / output system, so that the preboot execution environment function is correspondingly enabled / disabled after the read-only memory is loaded. The problems that the current whole setting procedure is complex and inconvenient, and the customization requirement of a customer on the PXE of a network card cannot be satisfied are solved.
Need to check novelty before this filing date? Find Prior Art

Description

Method and device for adaptively supporting server pre-start function

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] This application claims priority to the Chinese patent application filed with the China Patent Office on August 1, 2023, with application number 202310955447.3 and application name “Method and device for adaptive support of server pre-start function”, all contents of which are incorporated by reference into this application. Technical Field

[0003] The present disclosure relates to the field of computer technology, and in particular to a method and device for adaptively supporting a server pre-start function. Background Art

[0004] After the current BIOS (Base Input / Output System) initializes the network card, it will create a startup item for each network card port in the BIOS Setup window. There will also be a dedicated function key to boot all startup items, or the startup items of all network card ports, so that users can enable or disable the PXE (Preboot eXecution Environment) startup function of the network card port.

[0005] In the case of this function processing, if the customer wants to turn off the PXE function of certain ports of a certain network card, he needs to boot the computer and enter the BIOS Setup interface to the corresponding window, turn off the startup item of the corresponding network card port, or turn off the corresponding function setting item that specifically controls the PXE of the network card port, and then save the settings and restart the machine to achieve the purpose, or the machine needs to boot into the OS (Operating System) or UEFI (Unified Extensible Firmware Interface) shell and then execute a shell script to control it.

[0006] However, the related technologies for disabling the PXE function of the port have the following problems: the entire setting procedure is cumbersome and inconvenient; and the PXE requirements of the customer network card cannot be customized, which is not conducive to meeting the customer's needs.

[0007] Summary of the Invention

[0008] In a first aspect, the present disclosure provides a method for adaptively supporting a server pre-start function, the method comprising:

[0009] In response to acquiring the target indication information, traversing each network card device in the network card device library, wherein the target indication information is used to indicate that the target object has a customized requirement for the switch function of the pre-boot execution environment;

[0010] Select the target network card device and the target port of the target network card device corresponding to the custom requirements from each network card device;

[0011] Executing an opening function on the pre-boot execution environment of the target port and executing a closing function on the pre-boot execution environment of the reference port other than the target port in the target network card; and

[0012] The customized requirements are compiled into a version file and burned into the read-only memory of the basic input and output system, so that the switch function corresponding to the pre-boot execution environment is executed after the read-only memory is loaded.

[0013] In an optional implementation, before traversing each network card device in the network card device library, the method further includes:

[0014] Get multiple preset devices;

[0015] determining whether the preset device is a network card device according to a target value of a register in a configuration space of the preset device; and

[0016] In response to determining that the preset device is a network card device, a network card device library is generated by the preset device.

[0017] In an optional embodiment, before selecting the target network card device and the target port of the target network card device corresponding to the custom requirement from each network card device, the method further includes:

[0018] In response to acquiring instruction information composed of a plurality of signal values, determining a corresponding topology type according to the instruction information; and

[0019] Determine the target design diagram based on the topology type.

[0020] In an optional implementation, selecting a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device includes:

[0021] Obtain the target network card device from various network card devices according to the target design diagram and customized requirements; and

[0022] A target port is selected from multiple ports of a target network card device according to a target design drawing and custom requirements.

[0023] In an optional embodiment, according to the target design diagram and the customized requirements, the target network card device is obtained from various network card devices, including:

[0024] According to the target design diagram, a target network card device corresponding to the customized requirements is obtained from various network card devices in a depth-first traversal manner.

[0025] In an optional implementation, after obtaining the target network card device corresponding to the customized requirement from each network card device, the method further includes:

[0026] Obtaining a historical global variable value, wherein the historical global variable value is used to indicate the number of network card devices that have been traversed in the network card device library;

[0027] Increment the target network card device's serial number by a preset value; and

[0028] Based on the historical global variable values ​​and the preset values, the global variable values ​​corresponding to the target network card device are obtained.

[0029] In an optional embodiment, according to the target design diagram and the customized requirements, the target network card device is obtained from various network card devices, including:

[0030] According to the target design diagram, obtain the bus value and device value of each network card device; and

[0031] Get the target network card device based on bus values, device values, and custom requirements.

[0032] In an optional implementation, obtaining a target network card device according to bus values ​​and device values ​​and customized requirements includes:

[0033] Comparing the bus values ​​of the various network card devices, sorting the bus values ​​according to a preset order, and obtaining a first sorting result;

[0034] In response to any predetermined number of reference network card devices having the same bus value, comparing the device values ​​of the reference network card devices;

[0035] Sort the reference network card devices according to the device values ​​to obtain a second sorting result; and

[0036] Obtain the target network card device according to the custom requirements, the first sorting result, and the second sorting result.

[0037] In an optional embodiment, selecting a target port from multiple ports of a target network card device according to a target design diagram and customized requirements includes:

[0038] According to the target design diagram, obtain the port number of each port of the target network card device; and

[0039] Select the target port from multiple ports based on custom requirements and port numbers.

[0040] In an optional embodiment, selecting a target port from multiple ports of a target network card device according to a target design diagram and customized requirements includes:

[0041] According to the target design diagram, obtain the current position value of each port of the target network card device; and

[0042] Select the target port from multiple ports based on custom requirements and position values.

[0043] In an optional embodiment, the method further includes:

[0044] In response to the adaptive support for the pre-boot execution environment switch function in the basic input and output system scenario, obtaining a target network card device according to the customized requirements, the first sorting result, and the second sorting result; and

[0045] Sort ports by position value and get target port according to custom requirements.

[0046] In an optional embodiment, the method further includes:

[0047] In response to the adaptive support of the pre-boot execution environment switch function in the operating system scenario, obtaining the target network card device according to the customized requirements, the first sorting result and the second sorting result; and

[0048] Sort ports by position value and get target port according to custom requirements.

[0049] In an optional embodiment, selecting a target port from multiple ports of a target network card device according to a target design diagram and customized requirements includes:

[0050] According to the target design diagram, obtain the current position value of each port of the target network card device;

[0051] Generate the first arrangement based on the position value;

[0052] Obtain the target object's custom requirements for identifying and sorting each port;

[0053] Adjust the first arrangement according to custom requirements to obtain the second arrangement; and

[0054] Select the target port from the second array.

[0055] In an optional implementation, selecting a target network card device corresponding to the customized requirement from each network card device includes:

[0056] Determine the target bus value according to custom requirements;

[0057] Obtaining a preset bus value range corresponding to each network card device, wherein the preset bus value ranges do not overlap with each other;

[0058] matching a preset bus value range with the target bus value; and

[0059] In response to the target bus value falling within the target bus value range, the network card device corresponding to the target bus value range is used as the target network card device corresponding to the target bus value, wherein the target bus value range is included in the preset bus value range.

[0060] In an optional implementation, after the network card device corresponding to the target bus value range is used as the target network card device corresponding to the target bus value, the method further includes:

[0061] Determine the corresponding target port according to the target network card device; and

[0062] Determine the socket that houses the processor based on the target port.

[0063] In an optional implementation manner, there are multiple target network card devices and multiple target ports.

[0064] In an optional embodiment, performing an enabling function on the pre-boot execution environment of the target port includes:

[0065] The on-demand read-only memory driver file is used to execute a start function on the pre-boot execution environment of the target port.

[0066] In a second aspect, the present disclosure provides a server pre-start function adaptive support device, the device comprising:

[0067] A traversal module is configured to traverse each network card device in the network card device library in response to obtaining target indication information, wherein the target indication information is used to indicate that the target object has a customized requirement for the switch function of the pre-boot execution environment;

[0068] A selection module is used to select a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device;

[0069] an execution module, configured to execute an opening function on the pre-start execution environment of the target port and to execute a closing function on the pre-start execution environment of the reference port other than the target port in the target network card; and

[0070] The burning module is used to compile the customized requirements into a version file and burn it into the read-only memory of the basic input and output system, so that the switch function corresponding to the pre-boot execution environment is executed after the read-only memory is loaded.

[0071] In a third aspect, the present disclosure provides a computer device comprising: a memory and a processor, the memory and the processor being communicatively connected to each other, computer instructions being stored in the memory, and the processor executing the server pre-start function adaptive support method of the above-mentioned first aspect or any corresponding embodiment thereof by executing the computer instructions.

[0072] In a fourth aspect, the present disclosure provides one or more non-volatile computer-readable storage media storing computer instructions. When the computer instructions are executed by one or more processors, the one or more processors execute the server pre-start function adaptive support method of the above-mentioned first aspect or any corresponding embodiment thereof. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0074] FIG1 is a flow chart of a method for adaptively supporting a server pre-start function according to one or more embodiments of the present disclosure;

[0075] FIG2 is a hardware diagram of adaptive support for a server pre-start function according to one or more embodiments of the present disclosure;

[0076] FIG3 is a schematic diagram of a functional implementation flow of a server pre-start function adaptive support according to one or more embodiments of the present disclosure;

[0077] FIG4 is a flow chart of a BIOS code function implementation process according to one or more embodiments of the present disclosure;

[0078] 5 is a structural block diagram of a server pre-start function adaptive support device according to one or more embodiments of the present disclosure;

[0079] FIG6 is a schematic diagram of the hardware structure of a computer device according to one or more embodiments of the present disclosure. DETAILED DESCRIPTION

[0080] To make the purpose, technical solutions, and advantages of the embodiments of the present disclosure more clear, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments of the present disclosure, all other embodiments obtained by those skilled in the art without making creative efforts shall fall within the scope of protection of the present disclosure.

[0081] After the current BIOS initializes the network card, if the customer wants to disable the PXE function of certain ports of a certain network card, it is usually necessary to boot the computer and enter the BIOS Setup interface to the corresponding window, turn off the startup item of the corresponding network card port, or turn off the corresponding function setting item that specifically controls the PXE of the network card port, then save the settings and restart the machine to achieve the purpose, or control the switch by writing a shell script.

[0082] However, the relevant technology has many defects: First, this method requires entering the BIOS window interface for settings, or booting into the OS or UEFI Shell environment, and then executing the script for settings. This is inconvenient for customer machine deployment or functional testing of the machine at the factory before shipment, especially when controlling batch machines, the disadvantages are even more obvious; second, this method cannot customize the customer's network card PXE requirements. For example, after the customer makes a request, the BIOS cannot be customized according to the customer's needs. It is still necessary to enter the BIOS setup window interface for settings, or it needs to be implemented through a script, which is not conducive to meeting customer needs; third, when the user's network card configuration changes, such as increasing or decreasing the number of network cards, or changing the slot position of the original network card, the original script or BIOS setup window interface settings may not be applicable, and the script needs to be redeveloped or the BIOS setup window interface settings need to be changed.

[0083] In order to solve the above problems, according to an embodiment of the present disclosure, an embodiment of a method for adaptively supporting server pre-start functions is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0084] In this embodiment, a method for adaptively supporting a server pre-start function is provided. FIG1 is a flow chart of the method for adaptively supporting a server pre-start function according to an embodiment of the present disclosure. As shown in FIG1 , the method can be applied to a basic input / output system. The method flow includes the following steps:

[0085] Step S101 , when target indication information is obtained, traverse each network card device in the network card device library, wherein the target indication information is used to indicate that the target object has a customized requirement for the switch function of the pre-boot execution environment.

[0086] Optionally, in an embodiment of the present disclosure, when the basic input / output system receives target indication information from the target object and determines that the target object has a customized requirement for the switch function of the pre-boot execution environment, it traverses and scans each network card device stored in the network card device library one by one.

[0087] It is understandable that the target object here can be a customer, and the custom requirement can be a functional requirement for PXE customization proposed by the target object, such as the first port (such as Port0) of the first enumerated network card supports PXE, and other network cards and ports do not support PXE.

[0088] Step S102 : selecting a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device.

[0089] Optionally, according to the customized requirement, a target network card device is selected from a plurality of network card devices in a network card device library, and then a target port is selected from a plurality of ports of the target network card device.

[0090] Step S103 : performing an opening function on the pre-boot execution environment of the target port, and performing a closing function on the pre-boot execution environments of the reference ports other than the target port in the target network card.

[0091] Optionally, the PXE switch function executed on the target port and other reference ports other than the target port can be determined according to the customized requirements. Specifically, the PXE on the target port is turned on, and the PXE on the reference port is turned off.

[0092] It can be understood that the target port and the reference port are both ports in the target network card device.

[0093] In step S104 , the customized requirements are compiled into a version file and burned into the READ-ONLY MEMORY of the basic input / output system, so that the switch function corresponding to the pre-boot execution environment is executed after being loaded into the READ-ONLY MEMORY.

[0094] Optionally, the custom requirements are compiled into the basic input and output system to obtain a new version file, which is burned into the read-only memory (ROM) of the basic input and output system on the machine. When the machine is turned on, the read-only memory can be loaded to realize the switch function corresponding to the corresponding pre-boot execution environment.

[0095] In the disclosed embodiment, according to the target object's customized requirements for the switch function of the pre-boot execution environment, the target network card device and target port corresponding to the customized requirements can be selected from each network card device, and then the pre-boot execution environment opening function is executed on the selected target port, and the pre-boot execution environment closing function is executed on other reference ports in the target network card except the target port, and then the customized requirements of the target object are burned into the read-only memory of the basic input and output system, thereby adaptively realizing the customized requirements of the target object for the network card PXE function, improving the function implementation method, abandoning the cumbersome and inconvenient defects of the relevant technical setting procedures, meeting customer needs, and improving customer satisfaction.

[0096] In some optional implementations, before traversing each network card device in the network card device library, the method further includes:

[0097] Get multiple preset devices;

[0098] determining whether the preset device is a network card device according to a target value of a register in a configuration space of the preset device;

[0099] When it is determined that the preset device is a network card device, a network card device library is generated based on the preset device.

[0100] Optionally, when traversing each network card device, the BIOS needs to read the target value of the register in the configuration space of each preset device (i.e., PCIE (PCI-Express, peripheral component interconnect express) device). For example, if the target value is 1, it means that the preset device is a network card device, and if the target value is 0, it means that the preset device is not a network card device. Then, if the preset device is determined to be a network card device, a network card device library is generated based on the multiple preset devices.

[0101] In the embodiment of the present disclosure, it is determined which of the preset devices are network card devices according to the target value of the register, and then a network card device library is obtained, so as to facilitate the selection of the target network card device from the network card device library.

[0102] In some optional implementations, before selecting the target network card device and the target port of the target network card device corresponding to the custom requirement from each network card device, the method further includes:

[0103] When instruction information consisting of multiple signal values ​​is obtained, a corresponding topology type is determined according to the instruction information;

[0104] Determine the target design diagram based on the topology type.

[0105] Optionally, in the embodiment of the present disclosure, since the settings of the network card device and each port of the network card device are determined by the hardware topology, for the embodiment of the present disclosure, it is necessary to first determine the design drawing determined by the hardware topology, and then select the target network card device and target port from the design drawing.

[0106] Furthermore, when the basic input / output system receives instruction information consisting of multiple signal values ​​(such as 01110), the corresponding topology type (such as the topology type is 1) is determined according to the instruction information, and then based on the correspondence between the topology type and the design drawing, such as one topology type corresponds to one design drawing, the current corresponding target design drawing is determined.

[0107] In the embodiment of the present disclosure, the topology type of the hardware topology is obtained according to the currently issued instruction information, and then the target design diagram is determined according to the topology type, so that information such as the network card port can be determined according to the target design diagram.

[0108] In some optional implementations, selecting a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device includes:

[0109] Obtain the target network card device from various network card devices according to the target design diagram and custom requirements;

[0110] A target port is selected from multiple ports of a target network card device according to a target design drawing and custom requirements.

[0111] Optionally, the processor slots and locations of each network card device can be determined based on the target design drawing, and the target network card device can be further determined based on the custom requirements; similarly, the arrangement and specific locations of each port in the target network card can be determined based on the target design drawing, and the target port can be further determined based on the custom requirements.

[0112] In the embodiment of the present disclosure, a more accurate target network card device and target port are determined by combining the target design diagram with the customized requirements.

[0113] In some optional implementations, obtaining a target network card device from various network card devices according to a target design diagram and customized requirements includes:

[0114] According to the target design diagram, a target network card device corresponding to the customized requirements is obtained from various network card devices in a depth-first traversal manner.

[0115] Optionally, in an embodiment of the present disclosure, when traversing multiple network card devices, a depth-first traversal method is used to traverse the network card devices. The first traversed network card device can be selected and accessed first. Then, the adjacent network card device of this network card device is used as the initial node, and its first adjacent network card device is retrieved. In other words, each time after accessing the current network card device, the first adjacent network card device of the current network card device is accessed first. In this way, when selecting a target network card device from multiple network card devices, customized requirements can be combined to find the correct target network card device.

[0116] In the embodiment of the present disclosure, a target network card device corresponding to the custom requirements can be selected from multiple network card devices in a depth-first traversal manner, reducing the labor cost of repeatedly developing versions, scripts, and maintaining code branches in the old way, and reducing the probability of errors.

[0117] In some optional implementations, after obtaining the target network card device corresponding to the customized requirement from each network card device, the method further includes:

[0118] Obtaining a historical global variable value, wherein the historical global variable value is used to indicate the number of network card devices that have been traversed in the network card device library;

[0119] Increase the preset value of the target network card device's serial number;

[0120] Based on the historical global variable values ​​and the preset values, the global variable values ​​corresponding to the target network card device are obtained.

[0121] Optionally, in the embodiment of the present disclosure, the network card devices that are traversed and scanned are recorded using global variables or the like. For example, starting from 0, each time a network card device is enumerated, the value of the corresponding global variable is increased by 1.

[0122] Specifically, since the values ​​of global variables are cumulative, when obtaining the target network card device, it is necessary to first obtain the historical global variable value, such as the value 3, and then increase the preset value (such as 1) based on the historical global variable value 3 to obtain the value 4. The value 4 is the global variable value corresponding to the target network card device.

[0123] In the disclosed embodiment, the global variable values ​​of the network card device are continuously changed to achieve the real-time purpose, so as to facilitate finding the accurate target network card device according to the customer's customized requirements.

[0124] In some optional implementations, obtaining a target network card device from various network card devices according to a target design diagram and customized requirements includes:

[0125] According to the target design diagram, obtain the bus value and device value of each network card device;

[0126] Get the target network card device based on bus values, device values, and custom requirements.

[0127] Optionally, after determining the target design drawing, the bus values ​​and device values ​​of each network card device can be obtained, these bus values ​​and device values ​​can be recorded and the network card devices can be sorted based on the bus values ​​and device values, and then the target network card device that meets the custom requirements can be selected from the sorted network card devices according to the custom requirements.

[0128] In the disclosed embodiment, based on the bus values ​​and device values ​​of each network card device, a target network card device that meets the customer's customized needs is obtained, thereby improving customer satisfaction.

[0129] In some optional implementations, obtaining a target network card device according to bus values ​​and device values ​​and customized requirements includes:

[0130] Comparing the bus values ​​of the various network card devices, sorting the bus values ​​according to a preset order, and obtaining a first sorting result;

[0131] When there are any preset number of reference network card devices with the same bus values, comparing the device values ​​of the reference network card devices;

[0132] Sort the reference network card devices according to the device values ​​to obtain a second sorting result;

[0133] Obtain the target network card device according to the custom requirements, the first sorting result, and the second sorting result.

[0134] Optionally, the bus values ​​and device values ​​are ranked from small to large, and the order of the network card device being scanned is determined by the order in which the bus values ​​are ranked. Specifically, the comparison method is as follows: first, the bus values ​​of the network card devices are compared, and the bus values ​​are sorted according to a preset order to obtain a first sorting result; when any preset number of bus values ​​are the same, for example, when the bus values ​​of any two network card devices are the same, these two network card devices are referred to as reference network card devices, and their device values ​​are compared again. These reference network card devices are then sorted using the device values ​​to obtain a second sorting result.

[0135] Then, according to the first sorting result, the second sorting result and the customer's customized requirements, a target network card device is selected from the multiple network card devices.

[0136] In the embodiment of the present disclosure, a first sorting result based on bus values ​​and a second sorting result based on device values ​​are used to obtain a target network card device that meets the customer's customized needs, thereby improving customer satisfaction.

[0137] In some optional implementations, selecting a target port from multiple ports of a target network card device according to a target design diagram and customized requirements includes:

[0138] According to the target design diagram, obtain the port number of each port of the target network card device;

[0139] Select the target port from multiple ports based on custom requirements and port numbers.

[0140] Optionally, after determining the target design drawing, the port number of each port contained in each network card device can be obtained, and then the custom requirements can be obtained. For example, the custom requirement is that the first port (such as Port0) of the first enumerated network card supports PXE, and other network cards and ports do not support PXE. At this time, after finding the first enumerated target network card device, find the target port with port number 0 (corresponding to Port0), and load the on-demand read-only memory driver file. For other network cards and ports, the process of loading the on-demand read-only memory driver file is skipped. In this way, the function that Port0 of the first enumerated network card can support PXE, and other network cards and ports do not support PXE is achieved.

[0141] In the disclosed embodiment, it is only necessary to determine the port numbers of each port of the target network card device according to the target design drawing to obtain the target port that meets the customer's customized needs, eliminating the tediousness of the old method, reducing the probability of error, and improving the robustness and competitiveness of the basic input and output system code.

[0142] In some optional implementations, selecting a target port from multiple ports of a target network card device according to a target design diagram and customized requirements includes:

[0143] According to the target design diagram, obtain the current position value of each port of the target network card device;

[0144] Select the target port from multiple ports based on custom requirements and position values.

[0145] Optionally, after determining the target design drawing, the current position value of each port contained in each network card device can be obtained. For example, the port number starts counting from 0, so the corresponding position value of port N (which can be 0 / 1 / 2 / 3, etc.) can also be obtained.

[0146] If the customer requires that the target network card device on a certain slot supports the PXE function of its Nth port, then the Nth port is selected as the target port based on the position values ​​of each port.

[0147] In the disclosed embodiment, it is only necessary to determine the current position value of each port according to the target design drawing to obtain the target port that meets the customer's customized needs, eliminating the tediousness of the old method, reducing the probability of error, and improving the robustness and competitiveness of the basic input and output system code.

[0148] In some optional embodiments, the method further comprises:

[0149] When the pre-boot execution environment switch function is adaptively supported in the basic input and output system scenario, the target network card device is obtained according to the custom requirements and the second sorting result;

[0150] Sort ports by position value and get target port according to custom requirements.

[0151] Optionally, the embodiment of the present disclosure is to process the Nth port of the network card ranked M in the basic input and output system initialization scenario in accordance with the enumeration order to support the PXE function. At this time, according to the target design drawing, identify which slot corresponds to which port of which network card device CPU, and then follow the order of CPU number and port number from small to large, that is, CPU0 port 0, 1, 2...CPU1 port 0, 1, 2...CPUn port 0, 1, 2... to see which position of the network card of each network card device ranks among all the slots, so the ranking of the slot is also the ranking of the bus value or device value. Because the BIOS also follows this order when assigning bus values ​​and device values ​​to each network card device, therefore, based on the above embodiment, the bus value and device value are compared, and the content of the target network card device is determined based on the custom requirements, the first sorting result and the second sorting result, to obtain the target network card device.

[0152] At the same time, since the ports of each network card device are arranged in ascending order, the ascending order here is determined based on the position value of the port. Therefore, when obtaining the target port according to custom requirements, it is necessary to sort all ports according to the position value of each port, and use the Nth port as the target port according to the custom requirements to load the on-demand read-only memory driver file.

[0153] In the embodiment of the present disclosure, the adaptive support requirements of the server pre-start function can also be realized in the basic input and output system scenario, adapting to various customization requirements and improving the implementation method of the switch function.

[0154] In some optional embodiments, the method further comprises:

[0155] When the pre-boot execution environment switch function is adaptively supported in the operating system scenario, the target network card device is obtained according to the custom requirements, the first sorting result, and the second sorting result;

[0156] Sort ports by position value and get target port according to custom requirements.

[0157] Optionally, in the embodiment of the present disclosure, in the operating system scenario, the Nth port of the network card ranked at the Mth is processed to support the PXE function according to the enumeration order. At this time, according to the target design drawing, it is identified which slot corresponds to which port of which network card device CPU, and then the order of CPU number and port number from small to large, that is, CPU0 port 0, 1, 2...CPU1 port 0, 1, 2...CPUn port 0, 1, 2..., is used to see which position of the network card of each network card device ranks among all the slots, so the ranking of the slot is also the ranking of the bus value or the device value. Because the BIOS also follows this order when assigning bus values ​​and device values ​​to each network card device, therefore, based on the above embodiment, the bus value and the device value are compared, and the content of the target network card device is determined based on the custom requirements, the first sorting result and the second sorting result, the target network card device is obtained.

[0158] At the same time, since the ports of each network card device are arranged in ascending order, the ascending order here is determined based on the position value of the port. Therefore, when obtaining the target port according to custom requirements, it is necessary to sort all ports according to the position value of each port, and according to the custom requirements, the Nth port is used as the target port, and the on-demand read-only memory driver file is loaded on it.

[0159] In the embodiment of the present disclosure, the adaptive support requirements of the server pre-start function can also be realized in the operating system scenario, adapting to various customization requirements and improving the implementation method of the switch function.

[0160] In some optional implementations, selecting a target port from multiple ports of a target network card device according to a target design diagram and customized requirements includes:

[0161] According to the target design diagram, obtain the current position value of each port of the target network card device;

[0162] Generate the first arrangement based on the position value;

[0163] Obtain the target object's custom requirements for identifying and sorting each port;

[0164] According to custom requirements, adjust the first arrangement to obtain the second arrangement;

[0165] Select the target port from the second array.

[0166] Optionally, in an embodiment of the present disclosure, if a customer specifies a port of a network card device on a certain slot to perform customized PXE switch functions, and also specifies the enumeration / identification order of the port, such as the first one identified, the Nth one identified, etc., then the specific order of each port can be set according to the identification order specified by the customer.

[0167] Specifically, according to the target design drawing, the current position values ​​of each port of the target network card device are obtained, and a first arrangement is generated based on the position values. The first arrangement can be adjusted, for example, instead of following the order of ports 0, 1, 2..., a second arrangement can be developed in the order of ports 1, 0, 2... to meet the customer's customized identification number requirements. The target port is selected from the second arrangement, and the target port is loaded with the on-demand read-only memory driver file.

[0168] In the embodiment of the present disclosure, the positions of the ports are arranged according to the current position values ​​of the ports and the identification numbers set by the target objects (i.e., customers) for the ports, and then the target ports can be selected according to the customer's specifications to meet the customer's diverse needs.

[0169] In some optional implementations, selecting a target network card device corresponding to the custom requirement from each network card device includes:

[0170] Determine the target bus value according to custom requirements;

[0171] Obtaining a preset bus value range corresponding to each network card device, wherein the preset bus value ranges do not overlap with each other;

[0172] Using the target bus value to match the preset bus value range;

[0173] When the target bus value falls within the target bus value range, the network card device corresponding to the target bus value range is used as the target network card device corresponding to the target bus value, wherein the target bus value range is included in the preset bus value range.

[0174] Optionally, according to Intel's chip framework design, a target network card device may be selected from multiple network card devices based on a bus feature.

[0175] Specifically, in the embodiment of the present disclosure, a preset bus value range is first pre-set for each network card device, and the intervals between these preset bus value ranges do not overlap with each other.

[0176] Determine the target bus value according to the customized requirements, then match the target bus value to the preset bus value range, determine the target bus value range in which the target bus value falls, and use the network card device corresponding to the target bus value range as the network card device corresponding to the target bus value, and refer to it as the target network card device.

[0177] In the embodiment of the present disclosure, the target bus value determined by the custom requirement is used to match the preset bus value range corresponding to each network card device. The network card device that falls into the preset bus value range is used as the target network card device corresponding to the target bus value. Under the premise of saving more process and time, the pre-boot execution environment switch requirement function is realized.

[0178] In some optional implementations, after the network card device corresponding to the target bus value range is used as the target network card device corresponding to the target bus value, the method further includes:

[0179] Determine the corresponding target port according to the target network card device;

[0180] Determine the socket that houses the processor based on the target port.

[0181] Optionally, each network card device (i.e., the PCIE device in FIG2 ) has a slot connected to the CPU port. In this case, in order to determine the slot position of each network card device, the connected slot can be determined by determining the port. Since the port is determined by the network card device, in the embodiment of the present disclosure, after determining the target port that meets the customized requirements based on the target network card device, the corresponding CPU slot can be determined based on the target port.

[0182] In addition, it should be noted that, for any network card device, the slots for storing the CPUs of the corresponding ports are available.

[0183] At the same time, Figure 2 also includes a PCH (Platform Controller Hub, integrated south bridge), and the PCIE device in Figure 2 is also connected to the PCH, and there is also a slot on the port of its CPU.

[0184] PCH can be removed as the platform develops. In addition, the number of BIOS chips may also be two.

[0185] In the embodiment of the present disclosure, based on the target port determined by the target network card device, the corresponding slot for storing the processor (ie, CPU) can be found, thereby completing the design of the entire chip construction framework.

[0186] In some optional implementations, there are multiple target network card devices and multiple target ports.

[0187] Optionally, in the above embodiment, the description of adaptive support for PXE switch function is carried out when there is only one target network card device and only one target port. In the embodiment of the present disclosure, in response to the customized requirement of multiple target network card devices and multiple target ports supporting PXE switch function, multiple target network card devices and multiple target ports that meet the customized requirement can be screened out through the methods of the above embodiments.

[0188] In the embodiment of the present disclosure, it is also applicable to the requirement of supporting the pre-boot execution environment switch function of multiple ports of multiple network cards, thereby achieving diversification.

[0189] In some optional implementations, performing an enabling function on the pre-boot execution environment of the target port includes:

[0190] The on-demand read-only memory driver file is used to execute a start function on the pre-boot execution environment of the target port.

[0191] Optionally, when enumerating the network card device, the BIOS will load the read-only memory for each device with an on-demand read-only memory driver file. The PXE function of the network card is supported by its on-demand read-only memory driver file.

[0192] Based on the above embodiments, the embodiments of the present disclosure can superimpose and reuse the corresponding methods of supporting PXE switch functions in the above embodiments, such as selecting the methods of multiple embodiments for composite design, thereby realizing customized requirements for supporting PXE switch functions.

[0193] In some optional implementations, as shown in FIG3 , FIG3 is a schematic diagram of a function implementation flow of adaptive support for a server pre-start function according to an embodiment of the present disclosure, and the specific process steps are as follows:

[0194] Receive customized requirements from customers;

[0195] Analyze the custom requirements;

[0196] Determine whether the hardware topology needs to be adjusted;

[0197] If necessary, adjust the hardware topology, then generate BIOS code based on the customized requirements, compile a new version file, and burn it to the on-demand ROM driver file of the BIOS on the machine; otherwise, directly generate BIOS code based on the customized requirements, compile a new version file, and burn it to the on-demand ROM driver file of the BIOS on the machine;

[0198] Implement adaptive support requirements for server pre-start function.

[0199] In some optional implementations, as shown in FIG4 , FIG4 is a flow chart of the implementation of the BIOS code function in the implementation of the function according to the embodiment of the present disclosure, which specifically includes the following steps:

[0200] BIOS starts processing;

[0201] Initialize the PCIE device (i.e., the preset device), select the network card device and the initialization order of the network card device and each port;

[0202] Filter target network card devices and target ports according to custom requirements;

[0203] Determine whether these target network card devices and target ports support PXE switch functions;

[0204] If so, the on-demand read-only memory driver file is loaded and the process ends; otherwise, the process ends directly.

[0205] This embodiment also provides a server pre-start function adaptive support device, which is used to implement the above-mentioned embodiments and preferred implementations. Details already described will not be repeated here. As used below, the term "module" may refer to a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, implementation using hardware, or a combination of software and hardware, is also possible and contemplated.

[0206] This embodiment provides a server pre-start function adaptive support device, as shown in FIG5 , including:

[0207] The traversal module 501 is used to traverse each network card device in the network card device library when the target indication information is obtained, wherein the target indication information is used to indicate that the target object has a customized requirement for the switch function of the pre-boot execution environment;

[0208] A selection module 502 is configured to select a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device;

[0209] An execution module 503 is configured to execute an opening function on the pre-start execution environment of the target port and execute a closing function on the pre-start execution environment of the reference port other than the target port in the target network card;

[0210] The burning module 504 is used to compile the customized requirements into a version file and burn it into the read-only memory of the basic input and output system, so that the switch function corresponding to the pre-boot execution environment is executed after loading into the read-only memory.

[0211] In some optional embodiments, the device further comprises:

[0212] A first acquisition module is used to acquire a plurality of preset devices before traversing each network card device in the network card device library;

[0213] A first determining module, configured to determine whether the preset device is a network card device according to a target value of a register in a configuration space of the preset device;

[0214] The generating module is used to generate a network card device library from the preset device when it is determined that the preset device is a network card device.

[0215] In some optional embodiments, the device further comprises:

[0216] The second determining module is configured to determine a corresponding topology type according to instruction information composed of multiple signal values ​​before selecting a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device;

[0217] The third determining module is used to determine the target design diagram according to the topology type.

[0218] In some optional implementations, the selection module 502 includes:

[0219] A first acquisition unit is configured to acquire a target network card device from various network card devices according to a target design diagram and customized requirements;

[0220] The selection unit is used to select a target port from multiple ports of the target network card device according to the target design diagram and customized requirements.

[0221] In some optional implementations, the first acquiring unit includes:

[0222] The first acquisition submodule is used to obtain a target network card device corresponding to the customized requirement from various network card devices according to the target design diagram and in a depth-first traversal manner.

[0223] In some optional implementations, the first acquiring unit includes:

[0224] A second acquisition submodule is configured to obtain a historical global variable value after obtaining a target network card device corresponding to the customized requirement from each network card device, wherein the historical global variable value is used to represent the number of network card devices that have been traversed in the network card device library;

[0225] Add a submodule to increase the preset value of the target network card device's serial number;

[0226] The first obtaining submodule is used to obtain the global variable value corresponding to the target network card device based on the historical global variable value and the preset value.

[0227] In some optional implementations, the first acquiring unit includes:

[0228] The third acquisition submodule is used to obtain the bus value and device value of each network card device according to the target design diagram;

[0229] The fourth acquisition submodule is used to obtain the target network card device according to the bus value, device value and custom requirements.

[0230] In some optional implementations, the fourth acquisition submodule includes:

[0231] The first sorting subunit is used to compare the bus values ​​of each network card device and sort the bus values ​​according to a preset order to obtain a first sorting result;

[0232] a comparison subunit, configured to compare the device value of the reference network card device when there are any preset number of reference network card devices with the same bus value;

[0233] A second sorting subunit is used to sort the reference network card devices according to the device values ​​to obtain a second sorting result;

[0234] The acquisition subunit is used to acquire the target network card device according to the customized requirements, the first sorting result and the second sorting result.

[0235] In some optional implementations, the selection unit includes:

[0236] The fifth acquisition submodule is used to obtain the port number of each port of the target network card device according to the target design diagram;

[0237] The first selection submodule is used to select a target port from multiple ports according to custom requirements and port numbers.

[0238] In some optional implementations, the selection unit includes:

[0239] The sixth acquisition submodule is used to obtain the current position value of each port of the target network card device according to the target design diagram;

[0240] The second selection submodule is used to select a target port from multiple ports according to custom requirements and position values.

[0241] In some optional embodiments, the device further comprises:

[0242] A second acquisition module is used to acquire a target network card device according to a custom requirement, the first sorting result, and the second sorting result when adaptively supporting the pre-boot execution environment switch function in a basic input and output system scenario;

[0243] The third acquisition module is used to sort the ports according to the position values ​​and obtain the target port according to the customized requirements.

[0244] In some optional embodiments, the device further comprises:

[0245] A fourth acquisition module is used to acquire a target network card device according to the customized requirements, the first sorting result, and the second sorting result when the pre-boot execution environment switch function is adaptively supported in the operating system scenario;

[0246] The fifth acquisition module is used to sort the ports according to the position values ​​and obtain the target port according to the customized requirements.

[0247] In some optional implementations, the selection unit includes:

[0248] The seventh acquisition submodule is used to obtain the current position value of each port of the target network card device according to the target design diagram;

[0249] A generating submodule, for generating a first arrangement according to the position value;

[0250] The eighth acquisition submodule is used to obtain the target object's custom requirements for identifying and sorting each port;

[0251] The second submodule is used to adjust the first arrangement according to the custom requirements to obtain the second arrangement;

[0252] The third selection submodule is used to select a target port from the second arrangement.

[0253] In some optional implementations, the selection module 502 includes:

[0254] A first determining unit, configured to determine a target bus value according to a custom requirement;

[0255] A second acquiring unit is configured to acquire a preset bus value range corresponding to each network card device, wherein the preset bus value ranges do not overlap with each other;

[0256] A matching unit, configured to match a preset bus value range with a target bus value;

[0257] The setting unit is configured to use the network card device corresponding to the target bus value range as the target network card device corresponding to the target bus value when the target bus value falls within the target bus value range, wherein the target bus value range is included in the preset bus value range.

[0258] In some optional implementations, the selection module 502 includes:

[0259] a second determining unit, configured to determine a corresponding target port according to the target network card device after taking the network card device corresponding to the target bus value range as the target network card device corresponding to the target bus value;

[0260] The third determining unit is configured to determine a slot for storing the processor according to the target port.

[0261] In some optional implementations, there are multiple target network card devices and multiple target ports.

[0262] In some optional implementations, executing the activation function on the pre-boot execution environment of the target port includes executing the activation function on the pre-boot execution environment of the target port using an on-demand read-only memory driver file.

[0263] The server pre-start function adaptive support device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.

[0264] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.

[0265] The embodiment of the present disclosure further provides a computer device having the server pre-start function adaptive support device shown in FIG5 .

[0266] Please refer to Figure 6, which is a structural diagram of a computer device provided by an optional embodiment of the present disclosure. As shown in Figure 6, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. The various components are connected to each other using different buses and can be installed on a common motherboard or installed in other ways as needed. The processor can process instructions executed in the computer device, including instructions stored in or on the memory to display graphical information of the GUI on an external input / output device (such as a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 6 takes a processor 10 as an example.

[0267] The processor 10 may be a central processing unit, a network processor, or a combination thereof. The processor 10 may further include a hardware chip. The hardware chip may be an application-specific integrated circuit, a programmable logic device, or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic, or any combination thereof.

[0268] The memory 20 stores instructions that can be executed by at least one processor 10, so as to enable at least one processor 10 to execute the method shown in the above embodiment.

[0269] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created based on the use of a computer device for displaying a small program landing page, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely located relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and a combination thereof.

[0270] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid-state drive; the memory 20 may also include a combination of the above types of memory.

[0271] The computer device further includes a communication interface 30 for the computer device to communicate with other devices or a communication network.

[0272] The embodiments of the present disclosure also provide one or more non-volatile computer-readable storage media storing computer instructions. The above-mentioned methods according to the embodiments of the present disclosure can be implemented in hardware, firmware, or can be implemented as computer code that can be recorded in a storage medium, or can be implemented as computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and downloaded via a network and will be stored in a local storage medium, so that the methods described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state drive, etc.; further, the storage medium can also include a combination of the above-mentioned types of memory. It can be understood that a computer, a processor, a microprocessor controller or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor or hardware, the method shown in the above embodiment is implemented.

[0273] Although the embodiments of the present disclosure have been described with reference to the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present disclosure, and such modifications and variations are all within the scope defined by the appended claims.

Claims

1. A method for adaptively supporting a server pre-start function, characterized in that: The method comprises: In response to acquiring the target indication information, traversing each network card device in the network card device library, wherein the target indication information is used to indicate that the target object has a customized requirement for the switch function of the pre-start execution environment; Selecting a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device; Performing an opening function on the pre-boot execution environment of the target port, and performing a closing function on the pre-boot execution environment of the reference port other than the target port in the target network card; and The customized requirement is compiled into a version file and burned into the read-only memory of the basic input and output system, so that the switch function corresponding to the pre-start execution environment is executed after the read-only memory is loaded.

2. The method according to claim 1, characterized in that Before traversing each network card device in the network card device library, the method further includes: Get multiple preset devices; Determining whether the preset device is a network card device according to a target value of a register in a configuration space of the preset device; and In response to the preset device being the network card device, the network card device library is generated by the preset device.

3. The method according to claim 1, characterized in that Before selecting the target network card device and the target port of the target network card device corresponding to the custom requirement from the network card devices, the method further includes: In response to acquiring instruction information composed of a plurality of signal values, determining a corresponding topology type according to the instruction information; and A target design diagram is determined according to the topology type.

4. The method according to claim 3, characterized in that The step of selecting a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device includes: According to the target design diagram and the customized requirements, obtaining the target network card device from the various network card devices; and The target port is selected from multiple ports of the target network card device according to the target design diagram and the custom requirements.

5. The method according to claim 4, characterized in that The step of obtaining the target network card device from the various network card devices according to the target design diagram and the custom requirements includes: According to the target design diagram, the target network card device corresponding to the customized requirement is obtained from the various network card devices in a depth-first traversal manner.

6. The method according to claim 5, characterized in that After obtaining the target network card device corresponding to the customized requirement from the various network card devices, the method further includes: Obtaining a historical global variable value, wherein the historical global variable value is used to indicate the number of network card devices that have been traversed in the network card device library; Increasing a preset value to the serial number of the target network card device; and Based on the historical global variable value and the preset value, a global variable value corresponding to the target network card device is obtained.

7. The method according to claim 4, characterized in that The step of obtaining the target network card device from the various network card devices according to the target design diagram and the custom requirements includes: According to the target design diagram, obtaining bus values ​​and device values ​​of each of the network card devices; and The target network card device is obtained according to the bus value, the device value and the custom requirement.

8. The method according to claim 7, characterized in that The acquiring the target network card device according to the bus value, the device value and the custom requirement includes: Comparing the bus values ​​of the network card devices, sorting the bus values ​​according to a preset order, and obtaining a first sorting result; In response to the existence of any preset number of reference network card devices having the same bus value, comparing the device values ​​of the reference network card devices; Sort the reference network card devices according to the device values ​​to obtain a second sorting result; and The target network card device is acquired according to the custom requirement, the first sorting result and the second sorting result.

9. The method according to claim 8, characterized in that The step of selecting the target port from multiple ports of the target network card device according to the target design diagram and the custom requirement includes: According to the target design diagram, obtaining the port number of each port of the target network card device; and The target port is selected from a plurality of ports according to the custom requirement and the port number.

10. The method according to claim 8, characterized in that The step of selecting the target port from multiple ports of the target network card device according to the target design diagram and the custom requirement includes: According to the target design diagram, obtaining the current position value of each port of the target network card device; and The target port is selected from a plurality of ports according to the custom requirement and the position value.

11. The method according to claim 10, characterized in that The method further comprises: In response to the adaptive support of the pre-boot execution environment switch function in the basic input and output system scenario, the target network card device is acquired according to the custom requirement, the first sorting result and the second sorting result; and The ports are sorted according to the position values, and the target port is obtained according to the custom requirement.

12. The method according to claim 10, characterized in that The method further comprises: In response to the adaptive support of the pre-boot execution environment switch function in the operating system scenario, the target network card device is acquired according to the custom requirement, the first sorting result and the second sorting result; and The ports are sorted according to the position values, and the target port is obtained according to the custom requirement.

13. The method according to claim 8, characterized in that The step of selecting the target port from multiple ports of the target network card device according to the target design diagram and the custom requirement includes: According to the target design diagram, obtaining the current position values ​​of each port of the target network card device; Generating a first arrangement according to the position value; Obtaining the custom requirement of the target object for identifying and sorting each of the ports; According to the customized requirement, adjusting the first arrangement to obtain a second arrangement; and The target port is selected from the second arrangement.

14. The method according to claim 1, characterized in that The step of selecting a target network card device corresponding to the custom requirement from the various network card devices includes: Determine the target bus value according to the custom requirement; Obtaining a preset bus value range corresponding to each of the network card devices, wherein the preset bus value ranges do not overlap with each other; using the target bus value to match the preset bus value range; and In response to the target bus value falling within a target bus value range, a network card device corresponding to the target bus value range is used as the target network card device corresponding to the target bus value, wherein the target bus value range is included in the preset bus value range.

15. The method according to claim 14, characterized in that After taking the network card device corresponding to the target bus value range as the target network card device corresponding to the target bus value, the method further includes: Determine the corresponding target port according to the target network card device; and A slot for storing a processor is determined according to the target port.

16. The method according to any one of claims 1 to 15, characterized in that The number of the target network card devices is multiple, and the number of the target ports is multiple.

17. The method according to any one of claims 1 to 15, characterized in that The performing of an enabling function on the pre-boot execution environment of the target port includes: The on-demand read-only memory driver file is used to execute an activation function on the pre-boot execution environment of the target port.

18. A server pre-start function adaptive support device, characterized in that: The device comprises: A traversal module, configured to traverse each network card device in the network card device library in response to acquiring target indication information, wherein the target indication information is used to indicate that the target object has a customized requirement for the switch function of the pre-start execution environment; A selection module, used for selecting a target network card device and a target port of the target network card device corresponding to the custom requirement from each network card device; an execution module, configured to execute an opening function on the pre-start execution environment of the target port, and execute a closing function on the pre-start execution environment of the reference port other than the target port in the target network card; and The burning module is used to compile the user-defined requirements into a version file and burn it into the read-only memory of the basic input and output system, so that the switch function corresponding to the pre-start execution environment is executed after the read-only memory is loaded.

19. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the server pre-start function adaptive support method according to any one of claims 1 to 17 by executing the computer instructions.

20. One or more non-volatile computer-readable storage media storing computer instructions, which, when executed by one or more processors, cause the one or more processors to perform the steps of the method according to any one of claims 1 to 17.

Citation Information

Patent Citations

  • PXE function enabling method and device for network card port and related equipment

    CN110413328A

  • Control method and system for pre-starting of different network ports, and medium

    CN112905251A

  • Pre-starting function control method and system and medium

    CN113190279A

  • Port configuration method, port configuration component and hard disk expansion device

    CN115562738A

  • Self-adaptive support method and device for pre-starting function of server

    CN116700809A