CN113721765A - Method, device and equipment for controlling input/output port of equipment - Google Patents
Method, device and equipment for controlling input/output port of equipment Download PDFInfo
- Publication number
- CN113721765A CN113721765A CN202110989587.3A CN202110989587A CN113721765A CN 113721765 A CN113721765 A CN 113721765A CN 202110989587 A CN202110989587 A CN 202110989587A CN 113721765 A CN113721765 A CN 113721765A
- Authority
- CN
- China
- Prior art keywords
- input
- output port
- equipment
- port information
- output
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 76
- 230000008569 process Effects 0.000 claims abstract description 25
- 230000006978 adaptation Effects 0.000 claims description 16
- 238000004590 computer program Methods 0.000 claims description 9
- 238000004891 communication Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 230000009471 action Effects 0.000 description 3
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 230000000694 effects Effects 0.000 description 3
- 238000013473 artificial intelligence Methods 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000006870 function Effects 0.000 description 1
- 238000010801 machine learning Methods 0.000 description 1
- 230000005055 memory storage Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000002085 persistent effect Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
- 238000009877 rendering Methods 0.000 description 1
- 230000001052 transient effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/4401—Bootstrapping
- G06F9/4411—Configuring for operating with peripheral devices; Loading of device drivers
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Computer Security & Cryptography (AREA)
- Human Computer Interaction (AREA)
- Stored Programmes (AREA)
Abstract
The application discloses a control method, a device, equipment and a computer readable storage medium for input and output ports of the equipment, a model adapting module for storing the corresponding relation between the equipment model and the input and output ports in the equipment in advance, for a single device, after the mainboard identification of the device is identified, the model adapting module is loaded to acquire the input/output port information corresponding to the device according to the mainboard identification, and then in the starting process, scanning and determining all input/output ports of all chips of the device, and only opening the input/output ports described in the input/output port information, therefore, the problem that the same set of basic codes designed uniformly for different types of equipment cannot be uniformly set on the switch configuration of the input/output port is solved, and the automatic switch configuration of the input/output port of the equipment of different types is realized.
Description
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a computer-readable storage medium for controlling an input/output port of a device.
Background
An Input/Output (I/O) port is an outlet for communication between a device and the outside, and refers to registers in an interface circuit, where the registers are used to store data information, control information, and state information, and after a connection (binding) is established with a certain port through system call, data transmitted to the port by a transport layer is received by a corresponding process, and data transmitted to the transport layer by the corresponding process is Output from the port.
In order to save the power consumption of the equipment, the input/output port which is not used by the equipment is required to be closed. The input/output ports that cannot be used by the device at least include input/output ports that are not led out of the device motherboard, that is, all the input/output ports of all chips deployed on the device motherboard are not led out of the motherboard for use by a user, and if the input/output ports of the chips that are not led out in the operation process of the device are also kept in an open state, useless power consumption is caused. The input/output port led out from the equipment mainboard is usually embodied in the mainboard silk-screen information, so that when the equipment service is provided for a user, only the input/output port led out from the mainboard is opened, and the name of the input/output port led out from the mainboard is updated according to the mainboard silk-screen information in the setting interface of the equipment, so that the user can know the corresponding information of the port in the software configuration interface and the port on the mainboard.
To facilitate port switch configuration, the i/o port name of the launch page is typically modified in the underlying code provided by the device manufacturer, and the unused i/o ports are set to off and their informational displays are hidden in the code section defined by the i/o port control options to allow the user to determine the available i/o ports. For a single model, the same port configuration scheme can be adopted, but for basic codes compatible with multiple models, the configuration method is not suitable because the number of input/output ports used by different model products and the names of the input/output ports are often different.
The technical problem to be solved by those skilled in the art is to provide an input/output port configuration scheme for various models.
Disclosure of Invention
The application aims to provide a method, a device, equipment and a computer readable storage medium for controlling input and output ports of equipment, which are used for realizing automatic switch configuration of the input and output ports of various models.
In order to solve the above technical problem, the present application provides a method for controlling an input/output port of a device, including:
a model adapting module storing the corresponding relation between the model of the equipment and the input/output port is deployed in the equipment in advance;
identifying a motherboard identifier of the device;
loading the model adapting module to acquire input/output port information corresponding to the equipment according to the mainboard identification;
in the process of starting up, scanning and determining all input/output ports of all chips of the equipment, and only starting up the input/output ports recorded in the input/output port information.
Optionally, the obtaining, according to the motherboard identifier, input/output port information corresponding to the device specifically includes:
analyzing the mainboard identification to obtain the model of the equipment;
and determining input/output port information corresponding to the equipment according to the model of the equipment.
Optionally, the obtaining, according to the motherboard identifier, input/output port information corresponding to the device specifically includes:
judging whether the machine type adapting module stores input/output port information corresponding to the mainboard identification or not;
if so, taking the input/output port information corresponding to the mainboard identification as the input/output port information corresponding to the equipment;
if not, analyzing the mainboard identification to obtain the model of the equipment, and determining input and output port information corresponding to the equipment according to the model of the equipment.
Optionally, the method further includes:
and if the input/output port information corresponding to the equipment is not successfully acquired, taking default input/output port information pre-stored in a basic input/output system of the equipment as the input/output port information corresponding to the equipment.
Optionally, in the boot process, scanning and determining all input/output ports of all chips of the device, and only starting the input/output ports recorded in the input/output port information includes:
in the process of starting up, judging whether the currently scanned input/output port is the input/output port recorded in the input/output port information; if yes, setting the currently scanned input/output port to be in an open state; if not, setting the currently scanned input/output port to be in a closed state;
judging whether all input/output ports of all chips of the equipment are scanned completely;
if the scanning is finished, ending;
if not, the next non-scanned input/output port is the currently scanned input/output port, and the step of judging whether the currently scanned input/output port is the input/output port described in the input/output port information is returned.
Optionally, the method further includes:
and after all the input/output ports recorded in the input/output port information are opened, updating the input/output port list of the start page of the equipment according to the on/off state of the input/output ports of the equipment.
Optionally, the method further includes:
receiving an input/output port configuration command input by a user on a starting page of the equipment;
and updating the input/output port information corresponding to the equipment and the input/output port switch state of the equipment according to the input/output port configuration command.
In order to solve the above technical problem, the present application further provides a control apparatus for an input/output port of a device, including:
the deployment unit is used for deploying a machine type adapting module which stores the corresponding relation between the machine type of the equipment and the input/output port in the equipment in advance;
the identification unit is used for identifying the mainboard identification of the equipment;
the acquisition unit is used for loading the model adaptation module so as to acquire input/output port information corresponding to the equipment according to the mainboard identification;
and the first control unit is used for scanning and determining all input/output ports of all chips of the equipment in the starting-up process and only starting the input/output ports recorded in the input/output port information.
In order to solve the above technical problem, the present application further provides a control device for an input/output port of a device, including:
a memory for storing instructions, the instructions comprising the steps of any one of the above method for controlling input/output ports of the device;
a processor to execute the instructions.
To solve the above technical problem, the present application further provides a computer-readable storage medium, on which a computer program is stored, wherein the computer program, when executed by a processor, implements the steps of the method for controlling the input/output port of the device according to any one of the above items.
According to the control method for the input and output ports of the equipment, the model adaptation modules of the corresponding relation between the equipment model and the input and output ports are stored in the equipment in advance, for a single piece of equipment, after the mainboard identification of the equipment is identified, the model adaptation modules are loaded to obtain the information of the input and output ports corresponding to the equipment according to the mainboard identification, then, all the input and output ports of all chips of the equipment can be scanned and determined in the starting process, and only the input and output ports recorded in the information of the input and output ports are started, so that the problem that the same basic code which is uniformly designed for different types of equipment cannot be uniformly set on the switch configuration of the input and output ports is solved, and the automatic switch configuration of the input and output ports of the equipment of different models is realized.
The embodiment of the application also provides a control device, equipment and a computer readable storage medium for the input and output ports of the equipment, which have the beneficial effects and are not described herein again.
Drawings
For a clearer explanation of the embodiments or technical solutions of the prior art of the present application, the drawings needed for the description of the embodiments or prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a flowchart of a method for controlling an input/output port of a device according to an embodiment of the present application;
fig. 2 is a schematic structural diagram of a control apparatus for an input/output port of a device according to an embodiment of the present disclosure;
fig. 3 is a schematic structural diagram of a control device of an input/output port of a device according to an embodiment of the present application.
Detailed Description
The core of the application is to provide a method, a device, equipment and a computer readable storage medium for controlling input and output ports of equipment, which are used for realizing automatic switch configuration of the input and output ports of various types.
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Example one
Fig. 1 is a flowchart of a method for controlling an input/output port of a device according to an embodiment of the present disclosure. As shown in fig. 1, a method for controlling an input/output port of a device according to an embodiment of the present application includes:
s101: a model adapting module storing the corresponding relation between the model of the equipment and the input/output port is arranged in the equipment in advance.
S102: and identifying the mainboard identification of the equipment.
S103: and loading the model adapting module to acquire the input/output port information corresponding to the equipment according to the mainboard identification.
S104: in the process of starting up, scanning and determining all input/output ports of all chips of the equipment, and only starting up the input/output ports recorded in the input/output port information.
It should be noted that the method for controlling the input/output port of the device provided in the embodiment of the present application may be applied to an Intel architecture server, but is not limited to a server of an Intel platform, and still has a general application value in servers of other platforms or other computer systems.
In a specific implementation, for step S101, in order to facilitate uniform configuration of devices of different models, a model adaptation module is deployed in the device in advance, where the model adaptation module is an execution program and at least includes correspondence between multiple device models and input/output ports, and is used to provide information of the input/output ports required by the device. The input/output port information of the device model stored in the model adaptation module may be based on all input/output ports of the largest chip set included in the device model used by the basic code deployed by the model adaptation module. In general, the number of chips and the types of chips involved in a set of device models to which the basic code is applied are consistent, and the largest set of input/output ports stored by the model adaptation module is all the input/output ports of all chips on a motherboard of such a device. Specifically, a table for storing input/output port information (including an input/output port type and a port number) applied by the device and a maximum set of input/output ports, and an execution program for extracting information of the input/output ports required by the native type from the maximum set of the table may be deployed in the native type adaptation module. In general, a device can be effective only after being restarted after the switch state of an Input/Output port is changed, and the switch state of the Input/Output port of the device is controlled during the startup process, so that the device is convenient for a user to use, and therefore, a model adaptation module can be deployed in Basic codes of a Basic Input/Output System (BIOS).
For step S102, specifically, in the process of starting up the device, the motherboard identifier of the device may be identified to perform model adaptation.
For step S103, loading the model adapting module to obtain the input/output port information corresponding to the device according to the motherboard identifier, where the obtaining of the input/output port information corresponding to the device according to the motherboard identifier may specifically include: analyzing the mainboard identification to obtain the model of the equipment; and determining input/output port information corresponding to the equipment according to the model of the equipment. Optionally, if the information of the input/output port required by the current device is stored in the model adapting module, the switch control of the input/output port of the device can be directly performed by using the stored information of the input/output port; or after the input/output port information corresponding to the equipment is determined according to the model of the equipment, the input/output port information is compared with the stored input/output port information, and then the on/off control of the input/output port of the equipment is carried out. The obtained input/output port information corresponding to the device may specifically include information such as a type of an input/output port to be opened, a port number of the input/output port, and a port name of the input/output port. Generally, the specific input/output port can be located according to the type of the input/output port and the port number of the input/output port.
In step S104, during the boot process, all the input/output ports to be controlled by the device are determined, and then the switch control is performed on each input/output port according to the input/output port information. Specifically, step S104 may include:
in the process of starting up, judging whether the currently scanned input/output port is the input/output port recorded in the input/output port information; if yes, setting the currently scanned input/output port to be in an open state; if not, setting the currently scanned input/output port to be in a closed state;
judging whether all input/output ports of all chips of the equipment are completely scanned or not;
if the scanning is finished, ending;
if not, the next non-scanned input/output port is the currently scanned input/output port, and the step of judging whether the currently scanned input/output port is the input/output port described in the input/output port information is returned.
The order of scanning the input and output ports may be in accordance with the chip start-up order of the device, or may be user-defined.
Further, the method for controlling an input/output port of a device provided in the embodiment of the present application may further include: after all the input/output ports described in the input/output port information are turned on, the input/output port list of the boot page of the device is updated according to the on/off state of the input/output ports of the device. The starting page of the device is a configuration page (Setup page) of the basic input and output system of the device, and a user can manually set the starting item of the device on the page, so that after the switching states of all input and output ports of the device are well controlled, only the opened input and output ports are displayed on the starting page of the device, and other input and output ports are hidden, so that the user can determine the information of the opened input and output ports and perform further switching control. In addition, an option may be provided for the user to view the closed input-output port.
According to the control method for the input and output ports of the equipment, the model adaptation modules of the corresponding relation between the equipment model and the input and output ports are stored in the equipment in advance, for a single piece of equipment, after the mainboard identification of the equipment is identified, the model adaptation modules are loaded to obtain the information of the input and output ports corresponding to the equipment according to the mainboard identification, then, all the input and output ports of all chips of the equipment can be scanned and determined in the starting process, and only the input and output ports recorded in the information of the input and output ports are started, so that the problem that the same set of basic codes designed uniformly for different types of equipment cannot be uniformly set on the switch configuration of the input and output ports is solved, and the automatic switch configuration of the input and output ports of the equipment of different models is realized.
Example two
In the above embodiment, the input/output port led out from the main board of the device is usually set to be in an on state, while the other input/output ports are set to be in an off state and information thereof is hidden on the start page of the device. On the basis of the foregoing embodiment, in the method for controlling an input/output port of an apparatus according to the embodiment of the present application, the step S103 of obtaining information of the input/output port corresponding to the apparatus according to the motherboard identifier may specifically include:
judging whether the machine type adapting module stores input/output port information corresponding to the mainboard identification or not;
if so, taking the input/output port information corresponding to the mainboard identification as the input/output port information corresponding to the equipment;
if not, analyzing the mainboard identification to obtain the model of the equipment, and determining the input/output port information corresponding to the equipment according to the model of the equipment.
In the above embodiment, it is mentioned that the information of the input/output port applied by the device may be stored in the machine type adaptation module, where the information may specifically be information of an input/output port that is turned on by the device before the device is turned off last time, and the input/output ports included in the information may be all input/output ports led out from a device motherboard, or may be input/output ports that remain to be turned on after being screened by a user on this basis. In the process of starting up the equipment, if the model adapting module is checked to store the input/output port information corresponding to the mainboard identification, the input/output port information can be directly utilized to carry out input/output port switch control on the equipment. On this basis, if the user needs to reset the input/output port setting every time the computer is started, the input/output port information applied to the device where the computer is stored in the model adapting module can be deleted.
And if the input/output port information corresponding to the mainboard identification is not stored in the model adapting module, analyzing the mainboard identification to obtain the model of the equipment, and determining the input/output port information corresponding to the equipment according to the model of the equipment.
EXAMPLE III
On the basis of the foregoing embodiment, the method for controlling an input/output port of a device according to an embodiment of the present application may further include:
and if the input/output port information corresponding to the equipment is not successfully acquired, taking default input/output port information which is pre-stored in a basic input/output system of the equipment as the input/output port information corresponding to the equipment.
In a specific implementation, the default input output port information may be stored in a UNI file (a file format in BIOS code for information defining a character string) of the basic input output system of the device. In the process of starting up the equipment, if the information of the input/output port corresponding to the equipment cannot be acquired successfully, for example, the information of the input/output port corresponding to the mainboard identification and the information of the input/output port corresponding to the equipment model are not acquired, the default information of the input/output port is called to control the on/off of the input/output port of the equipment.
The default input/output port information may be information of an input/output port corresponding to the device model, or information of an input/output port that is turned on before the previous shutdown may update the default input/output port information, or it may be determined whether to retain a custom setting according to a user setting.
Optionally, the method for controlling an input/output port of a device provided in the embodiment of the present application may further include:
if the input/output port information corresponding to the equipment is not successfully acquired, determining the reason for failure in acquiring the input/output port information, and recording an update failure log of the input/output port.
Example four
On the basis of the foregoing embodiment, the method for controlling an input/output port of a device according to an embodiment of the present application may further include:
receiving an input/output port configuration command input by a user on a starting page of equipment;
and updating the input/output port information corresponding to the equipment and the input/output port switch state of the equipment according to the input/output port configuration command.
After the equipment is started, a user can select to enter a starting page of the equipment, the input/output port which is started by the equipment is closed according to personal requirements, and then the equipment is restarted to take effect.
Optionally, after the input/output port information corresponding to the device and the input/output port switch state of the device are updated according to the input/output port configuration command, the method for controlling the input/output port of the device provided in the embodiment of the present application may further include: and automatically restarting the equipment.
On the basis of the above detailed description of the various embodiments corresponding to the control method of the input/output port of the device, the application also discloses a control device, a device and a computer readable storage medium of the input/output port of the device corresponding to the above method.
EXAMPLE five
Fig. 2 is a schematic structural diagram of a control apparatus for an input/output port of a device according to an embodiment of the present disclosure.
As shown in fig. 2, the apparatus for controlling input/output ports of a device according to an embodiment of the present application includes:
a deployment unit 201, configured to deploy a model adaptation module, which stores a correspondence between a model of the device and an input/output port, in the device in advance;
an identification unit 202 for identifying a motherboard identifier of the device;
the obtaining unit 203 is configured to load a model adapting module to obtain input/output port information corresponding to the device according to the motherboard identifier;
the first control unit 204 is configured to scan and determine all input/output ports of all chips of the device during the boot process, and only open the input/output ports described in the input/output port information.
Optionally, the control apparatus for input and output ports of a device provided in this embodiment of the present application may further include:
and the second control unit is used for taking default input/output port information which is stored in the basic input/output system of the equipment in advance as the input/output port information corresponding to the equipment if the input/output port information corresponding to the equipment is not acquired successfully.
Optionally, the control apparatus for input and output ports of a device provided in this embodiment of the present application may further include:
and the recording unit is used for determining the reason of failure in acquiring the information of the input/output port and recording an update failure log of the input/output port if the information of the input/output port corresponding to the equipment is not acquired successfully.
Optionally, the control apparatus for input and output ports of a device provided in this embodiment of the present application may further include:
and a first updating unit for updating the input/output port list of the boot page of the device according to the switch state of the input/output port of the device after all the input/output ports described in the input/output port information are turned on.
Optionally, the control apparatus for input and output ports of a device provided in this embodiment of the present application may further include:
the device comprises a receiving unit, a processing unit and a processing unit, wherein the receiving unit is used for receiving an input/output port configuration command input by a user on a starting page of the device;
and the second updating unit is used for updating the input/output port information corresponding to the equipment and the input/output port switch state of the equipment according to the input/output port configuration command.
Since the embodiments of the apparatus portion and the method portion correspond to each other, please refer to the description of the embodiments of the method portion for the embodiments of the apparatus portion, which is not repeated here.
EXAMPLE six
Fig. 3 is a schematic structural diagram of a control device of an input/output port of a device according to an embodiment of the present application.
As shown in fig. 3, the control device for input and output ports of a device provided in an embodiment of the present application includes:
a memory 310 for storing instructions, the instructions comprising the steps of the method for controlling an input/output port of a device according to any of the above embodiments;
a processor 320 for executing the instructions.
Processor 320 may include one or more processing cores, such as a 3-core processor, an 8-core processor, and so forth. The processor 320 may be implemented in at least one hardware form of a digital Signal processing (dsp), a Field-Programmable Gate Array (FPGA), a Programmable Logic Array (pla), or a digital Signal processing (dsp). The processor 320 may also include a main processor and a coprocessor, where the main processor is a processor for Processing data in an awake state, and is also called a central Processing unit (cpu); a coprocessor is a low power processor for processing data in a standby state. In some embodiments, the processor 320 may be integrated with an image processor GPU (graphics Processing unit), which is responsible for rendering and drawing the content that the display screen needs to display. In some embodiments, processor 320 may also include an Artificial Intelligence (AI) (artificial intelligence) processor for processing computational operations related to machine learning.
Memory 310 may include one or more computer-readable storage media, which may be non-transitory. Memory 310 may also include high speed random access memory, as well as non-volatile memory, such as one or more magnetic disk storage devices, flash memory storage devices. In this embodiment, the memory 310 is at least used for storing a computer program 311, wherein after the computer program 311 is loaded and executed by the processor 320, the relevant steps in the method for controlling the input/output port of the device disclosed in any of the foregoing embodiments can be implemented. In addition, the resources stored by the memory 310 may also include an operating system 312, data 313, and the like, and the storage may be transient storage or persistent storage. The operating system 312 may be Windows, among others. Data 313 may include, but is not limited to, data involved in the above-described methods.
In some embodiments, the control devices for the input and output ports of the device may also include a display 330, a power supply 340, a communication interface 350, an input and output interface 360, a sensor 370, and a communication bus 380.
Those skilled in the art will appreciate that the configuration shown in fig. 3 does not constitute a limitation of the control device input-output ports of the device and may include more or fewer components than those shown.
The control device of the input/output port of the device provided by the embodiment of the application comprises the memory and the processor, and when the processor executes the program stored in the memory, the control method of the input/output port of the device can be realized, and the effects are the same.
EXAMPLE seven
It should be noted that the above-described embodiments of the apparatus and device are merely illustrative, for example, the division of modules is only one division of logical functions, and there may be other divisions when actually implementing, for example, a plurality of modules or components may be combined or integrated into another system, or some features may be omitted or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or modules, and may be in an electrical, mechanical or other form. Modules described as separate parts may or may not be physically separate, and parts displayed as modules may or may not be physical modules, may be located in one place, or may be distributed on a plurality of network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
In addition, functional modules in the embodiments of the present application may be integrated into one processing module, or each of the modules may exist alone physically, or two or more modules are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode.
The integrated module, if implemented in the form of a software functional module and sold or used as a separate product, may be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application may be embodied in the form of a software product, which is stored in a storage medium and executes all or part of the steps of the methods described in the embodiments of the present application, or all or part of the technical solutions.
To this end, an embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the computer program implements the steps of the control method for the input/output port of the device.
The computer-readable storage medium may include: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory ROM (Read-Only Memory), a random Access Memory ram (random Access Memory), a magnetic disk, or an optical disk.
The computer program contained in the computer-readable storage medium provided in this embodiment can implement the steps of the method for controlling the input/output port of the device as described above when executed by the processor, and the effects are the same as above.
The detailed description is provided above for a method, an apparatus, a device and a computer readable storage medium for controlling input/output ports of a device provided in the present application. The embodiments are described in a progressive manner in the specification, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. The device, the apparatus and the computer-readable storage medium disclosed in the embodiments correspond to the method disclosed in the embodiments, so that the description is simple, and the relevant points can be referred to the description of the method. It should be noted that, for those skilled in the art, it is possible to make several improvements and modifications to the present application without departing from the principle of the present application, and such improvements and modifications also fall within the scope of the claims of the present application.
It is further noted that, in the present specification, relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
Claims (10)
1. A method for controlling an input/output port of a device, comprising:
a model adapting module storing the corresponding relation between the model of the equipment and the input/output port is deployed in the equipment in advance;
identifying a motherboard identifier of the device;
loading the model adapting module to acquire input/output port information corresponding to the equipment according to the mainboard identification;
in the process of starting up, scanning and determining all input/output ports of all chips of the equipment, and only starting up the input/output ports recorded in the input/output port information.
2. The method according to claim 1, wherein the obtaining input/output port information corresponding to the device according to the motherboard identifier specifically includes:
analyzing the mainboard identification to obtain the model of the equipment;
and determining input/output port information corresponding to the equipment according to the model of the equipment.
3. The method according to claim 1, wherein the obtaining input/output port information corresponding to the device according to the motherboard identifier specifically includes:
judging whether the machine type adapting module stores input/output port information corresponding to the mainboard identification or not;
if so, taking the input/output port information corresponding to the mainboard identification as the input/output port information corresponding to the equipment;
if not, analyzing the mainboard identification to obtain the model of the equipment, and determining input and output port information corresponding to the equipment according to the model of the equipment.
4. The control method according to claim 1, characterized by further comprising:
and if the input/output port information corresponding to the equipment is not successfully acquired, taking default input/output port information pre-stored in a basic input/output system of the equipment as the input/output port information corresponding to the equipment.
5. The method according to claim 1, wherein during a boot process, scanning and determining all input/output ports of all chips of the device, and only turning on the input/output ports described in the input/output port information, specifically includes:
in the process of starting up, judging whether the currently scanned input/output port is the input/output port recorded in the input/output port information; if yes, setting the currently scanned input/output port to be in an open state; if not, setting the currently scanned input/output port to be in a closed state;
judging whether all input/output ports of all chips of the equipment are scanned completely;
if the scanning is finished, ending;
if not, the next non-scanned input/output port is the currently scanned input/output port, and the step of judging whether the currently scanned input/output port is the input/output port described in the input/output port information is returned.
6. The control method according to claim 1, characterized by further comprising:
and after all the input/output ports recorded in the input/output port information are opened, updating the input/output port list of the start page of the equipment according to the on/off state of the input/output ports of the equipment.
7. The control method according to claim 1, characterized by further comprising:
receiving an input/output port configuration command input by a user on a starting page of the equipment;
and updating the input/output port information corresponding to the equipment and the input/output port switch state of the equipment according to the input/output port configuration command.
8. A control apparatus for an input/output port of a device, comprising:
the deployment unit is used for deploying a machine type adapting module which stores the corresponding relation between the machine type of the equipment and the input/output port in the equipment in advance;
the identification unit is used for identifying the mainboard identification of the equipment;
the acquisition unit is used for loading the model adaptation module so as to acquire input/output port information corresponding to the equipment according to the mainboard identification;
and the first control unit is used for scanning and determining all input/output ports of all chips of the equipment in the starting-up process and only starting the input/output ports recorded in the input/output port information.
9. A control device for an input/output port of a device, comprising:
a memory for storing instructions comprising the steps of a method of controlling an input-output port of the apparatus of any one of claims 1 to 7;
a processor to execute the instructions.
10. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method for controlling an input/output port of a device according to any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110989587.3A CN113721765B (en) | 2021-08-26 | 2021-08-26 | Control method, device and equipment for input/output port of equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202110989587.3A CN113721765B (en) | 2021-08-26 | 2021-08-26 | Control method, device and equipment for input/output port of equipment |
Publications (2)
Publication Number | Publication Date |
---|---|
CN113721765A true CN113721765A (en) | 2021-11-30 |
CN113721765B CN113721765B (en) | 2023-07-25 |
Family
ID=78678195
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202110989587.3A Active CN113721765B (en) | 2021-08-26 | 2021-08-26 | Control method, device and equipment for input/output port of equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN113721765B (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110138220A1 (en) * | 2009-12-07 | 2011-06-09 | Gough Robert E | Methods and apparatus to initiate a bios recovery |
CN110399170A (en) * | 2019-07-19 | 2019-11-01 | 浪潮电子信息产业股份有限公司 | A kind of port management method of SATA hard disc, system and associated component |
CN111222062A (en) * | 2020-01-09 | 2020-06-02 | 百度在线网络技术(北京)有限公司 | Applet running method and device, electronic equipment and storage medium |
CN112350872A (en) * | 2020-11-23 | 2021-02-09 | 网易(杭州)网络有限公司 | Network architecture configuration information generation method and device, storage medium and electronic equipment |
CN112905512A (en) * | 2021-02-05 | 2021-06-04 | 苏州源控电子科技有限公司 | DIO interface configuration method, device, equipment and storage medium based on Windows system |
CN112927434A (en) * | 2021-01-06 | 2021-06-08 | 上海泰砥科技有限公司 | Block chain and DID (digital information device) shared charging method and shared charging pile system |
-
2021
- 2021-08-26 CN CN202110989587.3A patent/CN113721765B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20110138220A1 (en) * | 2009-12-07 | 2011-06-09 | Gough Robert E | Methods and apparatus to initiate a bios recovery |
CN110399170A (en) * | 2019-07-19 | 2019-11-01 | 浪潮电子信息产业股份有限公司 | A kind of port management method of SATA hard disc, system and associated component |
CN111222062A (en) * | 2020-01-09 | 2020-06-02 | 百度在线网络技术(北京)有限公司 | Applet running method and device, electronic equipment and storage medium |
CN112350872A (en) * | 2020-11-23 | 2021-02-09 | 网易(杭州)网络有限公司 | Network architecture configuration information generation method and device, storage medium and electronic equipment |
CN112927434A (en) * | 2021-01-06 | 2021-06-08 | 上海泰砥科技有限公司 | Block chain and DID (digital information device) shared charging method and shared charging pile system |
CN112905512A (en) * | 2021-02-05 | 2021-06-04 | 苏州源控电子科技有限公司 | DIO interface configuration method, device, equipment and storage medium based on Windows system |
Also Published As
Publication number | Publication date |
---|---|
CN113721765B (en) | 2023-07-25 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CA2046356C (en) | Method and apparatus for improved initialization of computer system features | |
CN1545654A (en) | Quick starting method for computer | |
CN102200916A (en) | Electronic equipment, configurable member and method for storing configuration information of configurable member | |
CN113867743B (en) | Network operating system loading and burning method and device, electronic equipment and storage medium | |
CN116009921A (en) | Method, device and medium for upgrading embedded operating system | |
CN107368343A (en) | A kind of starting up of terminal method, terminal and storage medium based on Android system | |
CN112486522A (en) | Deployment method and device of OpenStack bare machine with intelligent network card | |
CN113485754A (en) | Chip starting method and device and electronic equipment | |
CN112506745B (en) | Memory temperature reading method and device and computer readable storage medium | |
CN114385251A (en) | Operating system booting method, system, terminal and storage medium based on memory | |
CN113315675B (en) | White box switch U-Boot automatic testing method, system and storage medium | |
CN113031999A (en) | Method, device and equipment for controlling firmware upgrade of server component and storage medium | |
CN102214105B (en) | Parallelization quick start method and the electronic installation with multiplied unit | |
CN112732556A (en) | Automatic testing method, device, equipment and storage medium for distributed system | |
CN113721765A (en) | Method, device and equipment for controlling input/output port of equipment | |
CN115878327A (en) | Bus reservation method, device, server, electronic equipment and storage medium | |
CN106095643A (en) | The establishing method of systematic parameter access and server thereof | |
CN113849233A (en) | BIOS null boot entry deleting method, system, terminal and storage medium | |
US20070016761A1 (en) | Method, apparatus, and computer program product for implementing enhanced system behavior control | |
CN113377418A (en) | File loading method, storage medium and equipment | |
CN111694300B (en) | Automatic configuration method and device for control panel input and output ports | |
CN107506271A (en) | A kind of method of testing and device | |
CN110442387B (en) | Parameter self-adaption method and device of vehicle-mounted system and vehicle | |
CN112148376A (en) | Terminal starting method and device | |
CN117311890B (en) | Picture display method and device in starting process of server |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |