CN110781115A - Modification method and device for field replaceable unit and storage medium - Google Patents

Modification method and device for field replaceable unit and storage medium Download PDF

Info

Publication number
CN110781115A
CN110781115A CN201911056309.1A CN201911056309A CN110781115A CN 110781115 A CN110781115 A CN 110781115A CN 201911056309 A CN201911056309 A CN 201911056309A CN 110781115 A CN110781115 A CN 110781115A
Authority
CN
China
Prior art keywords
bus
fru
modification
replaceable unit
field replaceable
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
Application number
CN201911056309.1A
Other languages
Chinese (zh)
Other versions
CN110781115B (en
Inventor
巩琦
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Wave Intelligent Technology Co Ltd
Original Assignee
Suzhou Wave Intelligent Technology Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Suzhou Wave Intelligent Technology Co Ltd filed Critical Suzhou Wave Intelligent Technology Co Ltd
Priority to CN201911056309.1A priority Critical patent/CN110781115B/en
Publication of CN110781115A publication Critical patent/CN110781115A/en
Application granted granted Critical
Publication of CN110781115B publication Critical patent/CN110781115B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/40Bus structure
    • G06F13/4063Device-to-bus coupling

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Bus Control (AREA)

Abstract

The embodiment of the invention discloses a modification method, a modification device and a storage medium of a field replaceable unit, wherein the method comprises the following steps: determining a bus to which a target Field Replaceable Unit (FRU) belongs; determining one or more devices mounted on the bus; stopping a bus channel switching function of one or more devices mounted on the bus when an instruction to modify the target FRU is received. When the target FRU is modified, the function of switching the bus channel of one or more devices mounted on the bus is stopped, so that the I2C bus resource is monopolized in the process of modifying the FRU, and the information of the FRU is successfully modified.

Description

Modification method and device for field replaceable unit and storage medium
Technical Field
Embodiments of the present invention relate to bus switching technologies, and in particular, to a method and an apparatus for modifying a field replaceable unit, and a storage medium.
Background
An FRU (Field Replaceable Unit) is an area inside a device, and is mainly used for storing firmware information of the device, including a manufacturer, a version number, a model number, a serial number, and the like. FRU information of different devices is generally stored in different hardware locations, and firmware information thereof is acquired according to methods provided by various manufacturers. Some manufacturers store FRU information in an EEPROM (Electrically Erasable Programmable read Only memory). The FRU information stored in the EEPROM is easily modified compared to being stored in the read-only area.
FRU information of a general board is stored in an EEPROM, and the EEPROM is hung on an I2C bus of a BMC (baseboard management Controller). Usually, other devices are hung on the bus, and a PCA9548 chip is generally used for managing which channel the I2C bus is switched to, and which device is connected.
In general, when FRU information is modified, if the modified data is more and the time is longer, other devices on the BUS may seize resources at this time, and modify the channel of PCA9548, resulting in failure to modify FRU information.
Disclosure of Invention
The embodiment of the invention provides a modification method, a modification device and a storage medium of a field replaceable unit, which are used for monopolizing an I2C bus resource in the FRU modification process and ensuring the information of the FRU to be successfully modified.
To achieve the objects of the embodiments of the present invention, embodiments of the present invention provide a method of modifying a field replaceable unit, the method including:
determining a bus to which a target Field Replaceable Unit (FRU) belongs;
determining one or more devices mounted on the bus;
stopping a bus channel switching function of one or more devices mounted on the bus when an instruction to modify the target FRU is received.
Preferably, the modifying method further includes: restoring the function of switching bus channels of the one or more devices mounted on the bus when it is determined that the target FRU modification is complete.
Preferably, the method previously comprises: setting an FRU flag bit, wherein the FRU flag bit is a flag bit for distinguishing whether the FRU is in a modification state;
and setting a modification flag bit, wherein the modification flag bit is a flag bit for distinguishing whether the equipment is allowed to switch the bus channel.
Preferably, the function of stopping the bus channel switching of the one or more devices mounted on the bus comprises:
when the FRU flag bit is detected to be a first numerical value, setting modification flag bits corresponding to one or more devices mounted on the bus to be a second numerical value, wherein the first numerical value indicates that the FRU is in a modification state, and the second numerical value indicates that the bus channel is not allowed to be modified and switched.
Preferably, when it is determined that the target FRU modification is complete, the function of resuming switching bus channels for the one or more devices mounted on the bus comprises:
modifying the FRU flag to a third value when it is determined that the modification of the target FRU is completed; when the FRU flag bit is detected to be a third value, setting modification flag bits corresponding to one or more devices mounted on the bus to be a fourth value, wherein the third value indicates that the FRU is not in a modification state, and the fourth value indicates that the bus channel is allowed to be modified and switched.
Preferably, determining the bus to which the target field replaceable unit FRU belongs includes:
inquiring the attribution table corresponding to the FRU, and determining the bus of the FRU
Determining one or more devices mounted on the bus comprises:
and inquiring a mounted device table corresponding to the bus, and determining the devices included in the table.
In a second aspect, an embodiment of the present invention further provides a modifying apparatus for a field replaceable unit, including:
an acquisition module configured to determine a bus to which a target Field Replaceable Unit (FRU) belongs; further configured to determine one or more devices mounted on the bus;
and the processing module is set to stop the function of switching the bus channel of one or more devices mounted on the bus when receiving the instruction of modifying the target FRU.
In a third aspect, embodiments of the present invention further provide a computer-readable storage medium storing computer-executable instructions for performing the method for modifying a field replaceable unit described above.
In a fourth aspect, the present invention also provides an apparatus for effecting modification of a field replaceable unit, comprising a memory holding a modification program for the field replaceable unit and a processor for executing the above-described method of modifying a field replaceable unit when the field replaceable unit-based modification program is read.
The beneficial effects of the embodiment of the invention can include:
when the target FRU is modified, the embodiment of the invention stops the function of switching the bus channel of one or more devices mounted on the bus, so that the I2C bus resource is monopolized in the process of modifying the FRU, and the information of the FRU is successfully modified.
In an exemplary embodiment, the FRU information is modified successfully by defining a new flag and setting the flag of whether each device can switch the bus channel to a first value before modifying the FRU and setting the flag of whether each device can switch the bus channel to a second value after modifying the FRU, so as to ensure that the bus channel is not cut away by other devices on the same I2C bus during the modification.
Additional features and advantages of embodiments of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by the practice of the invention. The objectives and other advantages of the embodiments of the invention will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
The accompanying drawings are included to provide a further understanding of the embodiments of the invention and are incorporated in and constitute a part of this specification, illustrate embodiments of the invention and together with the examples of the application do not constitute a limitation of the embodiments of the invention.
FIG. 1 is a flow chart of a method of modifying a field replaceable unit in accordance with an embodiment of the present invention;
fig. 2 is a schematic structural diagram of a modification apparatus of a field replaceable unit according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the embodiments of the present invention will be described in detail below with reference to the accompanying drawings. It should be noted that the embodiments and features of the embodiments in the present application may be arbitrarily combined with each other without conflict.
The steps illustrated in the flow charts of the figures may be performed in a computer system such as a set of computer-executable instructions. Also, while a logical order is shown in the flow diagrams, in some cases, the steps shown or described may be performed in an order different than here.
Example one
An embodiment of the present invention provides a method for modifying a field replaceable unit, as shown in fig. 1, where the method includes S101 to S103:
s101, determining a bus to which a target Field Replaceable Unit (FRU) belongs;
s102, determining one or more devices mounted on the bus;
s103, stopping the function of switching the bus channel of one or more devices mounted on the bus when receiving the command of modifying the target FRU.
In this embodiment of the present invention, the modification method further includes: restoring the function of switching bus channels of the one or more devices mounted on the bus when it is determined that the target FRU modification is complete.
In the embodiment of the invention, the method comprises the following steps: setting an FRU flag bit, wherein the FRU flag bit is a flag bit for distinguishing whether the FRU is in a modification state;
and setting a modification flag bit, wherein the modification flag bit is a flag bit for distinguishing whether the bus channel is allowed to be switched or not.
In this embodiment of the present invention, in step S103, the function of stopping switching of bus channels of one or more devices mounted on the bus includes:
when the FRU flag bit is detected to be a first numerical value, setting modification flag bits corresponding to one or more devices mounted on the bus to be a second numerical value, wherein the first numerical value indicates that the FRU is in a modification state, and the second numerical value indicates that the bus channel is not allowed to be modified and switched.
In this embodiment of the present invention, when it is determined that the modification of the target FRU is completed, the function of restoring the bus channel switching function of the one or more devices mounted on the bus includes:
modifying the FRU flag to a third value when it is determined that the modification of the target FRU is completed; when the FRU flag bit is detected to be a third value, setting modification flag bits corresponding to one or more devices mounted on the bus to be a fourth value, wherein the third value indicates that the FRU is not in a modification state, and the fourth value indicates that the bus channel is allowed to be modified and switched.
In the embodiment of the invention, firstly, the devices hung on the same I2C bus are judged, then a flag bit is set for each device whether the channel of the PCA9548 can be switched, when the flag bit is 1, the channel of the PCA9548 is allowed to be switched, and when the flag bit is 0, the channel of the PCA9548 is not allowed to be switched. Before the FRU is modified, the flag positions of all devices on the same I2C bus are set to 0, so that the channel of the PCA9548 is prevented from being cut off when FRU information is written, and after the FRU information is written, all the flag positions 1 are set to allow other devices on the same bus to cut off the channel.
In an embodiment of the present invention, determining a bus to which a target field replaceable unit FRU belongs includes:
inquiring the attribution table corresponding to the FRU, and determining the bus of the FRU
Determining one or more devices mounted on the bus comprises:
and inquiring a mounted device table corresponding to the bus, and determining the devices included in the table.
In the embodiment of the invention, which bus the FRU belongs to is determined in the code and can be obtained by table lookup. The method includes the steps that a mounted device table corresponding to a bus identifies the bus on which each device is mounted, when an FRU is modified, the bus where the FRU is located is obtained first, and then other devices on the bus can be obtained through table lookup.
Example two
An embodiment of the present invention provides a modification apparatus for a field replaceable unit, as shown in fig. 2, including:
an acquisition module configured to determine a bus to which a target Field Replaceable Unit (FRU) belongs; further configured to determine one or more devices mounted on the bus;
and the processing module is set to stop the function of switching the bus channel of one or more devices mounted on the bus when receiving the instruction of modifying the target FRU.
Embodiments of the present invention provide a computer-readable storage medium storing computer-executable instructions for performing the above method for modifying a field replaceable unit.
An embodiment of the present invention further provides an apparatus for implementing modification of a field replaceable unit, including a memory storing a modification program of the field replaceable unit and a processor for executing the above-described method of modifying a field replaceable unit when the field replaceable unit-based modification program is read.
EXAMPLE III
The present embodiment describes a modification process of the field replaceable unit by taking an example of setting a flag to control whether the device can switch the bus channel:
1. defining a flag bit whether to allow the channel of the PCA9548 to be switched or not for each device on the same bus as the FRU, wherein when the flag bit is 0, the channel of the PCA9548 is not allowed to be switched, and when the flag bit is 1, the channel of the PCA9548 is allowed to be switched;
2. before each time of changing FRU information, the mark positions 0 of all devices on the same bus are set, so that the phenomenon that the channel of PCA9548 is cut off when the FRU information is written to cause failure in modifying the FRU information is prevented;
3. when the equipment on the same bus seizes the resource, the zone bit of the equipment is detected before the channel is switched, when the zone bit is 1, the channel switching action is normally executed, and when the zone bit is 0, the channel switching is stopped;
4. and after the FRU information is modified, setting the flag positions of all the devices to be 1.
It will be understood by those of ordinary skill in the art that all or some of the steps of the methods, systems, functional modules/units in the devices disclosed above may be implemented as software, firmware, hardware, and suitable combinations thereof. In a hardware implementation, the division between functional modules/units mentioned in the above description does not necessarily correspond to the division of physical components; for example, one physical component may have multiple functions, or one function or step may be performed by several physical components in cooperation. Some or all of the components may be implemented as software executed by a processor, such as a digital signal processor or microprocessor, or as hardware, or as an integrated circuit, such as an application specific integrated circuit. Such software may be distributed on computer readable media, which may include computer storage media (or non-transitory media) and communication media (or transitory media). The term computer storage media includes volatile and nonvolatile, removable and non-removable media implemented in any method or technology for storage of information such as computer readable instructions, data structures, program modules or other data, as is well known to those of ordinary skill in the art. Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, Digital Versatile Disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can accessed by a computer. In addition, communication media typically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery media as known to those skilled in the art.

Claims (9)

1. A method of modifying a field replaceable unit, the method comprising:
determining a bus to which a target Field Replaceable Unit (FRU) belongs;
determining one or more devices mounted on the bus;
stopping a bus channel switching function of one or more devices mounted on the bus when an instruction to modify the target FRU is received.
2. The method of modifying according to claim 1, further comprising: restoring the function of switching bus channels of the one or more devices mounted on the bus when it is determined that the target FRU modification is complete.
3. A method of modifying according to claim 1 or 2, characterized in that said method is preceded by: setting an FRU flag bit, wherein the FRU flag bit is a flag bit for distinguishing whether the FRU is in a modification state;
and setting a modification flag bit, wherein the modification flag bit is a flag bit for distinguishing whether the equipment is allowed to switch the bus channel.
4. The modification method according to claim 3, wherein stopping the function of switching bus channels of the one or more devices mounted on the bus comprises:
when the FRU flag bit is detected to be a first numerical value, setting modification flag bits corresponding to one or more devices mounted on the bus to be a second numerical value, wherein the first numerical value indicates that the FRU is in a modification state, and the second numerical value indicates that the bus channel is not allowed to be modified and switched.
5. The modification method of claim 3, wherein resuming the function of switching bus channels of the one or more devices mounted on the bus when it is determined that the target FRU modification is complete comprises:
modifying the FRU flag to a third value when it is determined that the modification of the target FRU is completed; when the FRU flag bit is detected to be a third value, setting modification flag bits corresponding to one or more devices mounted on the bus to be a fourth value, wherein the third value indicates that the FRU is not in a modification state, and the fourth value indicates that the bus channel is allowed to be modified and switched.
6. The modification method of claim 1, wherein determining the bus to which the target Field Replaceable Unit (FRU) belongs comprises:
inquiring the attribution table corresponding to the FRU, and determining the bus of the FRU
Determining one or more devices mounted on the bus comprises:
and inquiring a mounted device table corresponding to the bus, and determining the devices included in the table.
7. A field replaceable unit modification apparatus, comprising:
an acquisition module configured to determine a bus to which a target Field Replaceable Unit (FRU) belongs; further configured to determine one or more devices mounted on the bus;
and the processing module is set to stop the function of switching the bus channel of one or more devices mounted on the bus when receiving the instruction of modifying the target FRU.
8. A computer-readable storage medium having stored thereon computer-executable instructions for performing the method of modifying a field replaceable unit of any one of claims 1-6.
9. An apparatus for effecting modification of a field replaceable unit, comprising a memory and a processor, wherein the memory stores a modification program for the field replaceable unit and the processor is configured to perform the method of modifying a field replaceable unit of any one of claims 1-6 when the modification program for the field replaceable unit is read.
CN201911056309.1A 2019-10-31 2019-10-31 Modification method and device for field replaceable unit and storage medium Active CN110781115B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911056309.1A CN110781115B (en) 2019-10-31 2019-10-31 Modification method and device for field replaceable unit and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911056309.1A CN110781115B (en) 2019-10-31 2019-10-31 Modification method and device for field replaceable unit and storage medium

Publications (2)

Publication Number Publication Date
CN110781115A true CN110781115A (en) 2020-02-11
CN110781115B CN110781115B (en) 2021-07-02

Family

ID=69388381

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911056309.1A Active CN110781115B (en) 2019-10-31 2019-10-31 Modification method and device for field replaceable unit and storage medium

Country Status (1)

Country Link
CN (1) CN110781115B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140244886A1 (en) * 2013-02-28 2014-08-28 Oracle International Corporation Controller for facilitating out of band management of rack-mounted field replaceable units
CN105488009A (en) * 2015-12-03 2016-04-13 英业达科技有限公司 FRU read/write method and read/write system
CN106537822A (en) * 2014-07-17 2017-03-22 Lg 电子株式会社 Broadcast transmission device, method by which broadcast transmission device processes data, broadcast reception device and method by which broadcast reception device processes data
CN108768511A (en) * 2018-06-22 2018-11-06 武汉光迅科技股份有限公司 A kind of intelligent selecting method and device of two dimension MEMS OSW photoswitches Hitless points
CN109495970A (en) * 2018-12-21 2019-03-19 Tcl移动通信科技(宁波)有限公司 Mobile terminal WIFI channel switching method, mobile terminal and storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140244886A1 (en) * 2013-02-28 2014-08-28 Oracle International Corporation Controller for facilitating out of band management of rack-mounted field replaceable units
CN106537822A (en) * 2014-07-17 2017-03-22 Lg 电子株式会社 Broadcast transmission device, method by which broadcast transmission device processes data, broadcast reception device and method by which broadcast reception device processes data
CN105488009A (en) * 2015-12-03 2016-04-13 英业达科技有限公司 FRU read/write method and read/write system
CN108768511A (en) * 2018-06-22 2018-11-06 武汉光迅科技股份有限公司 A kind of intelligent selecting method and device of two dimension MEMS OSW photoswitches Hitless points
CN109495970A (en) * 2018-12-21 2019-03-19 Tcl移动通信科技(宁波)有限公司 Mobile terminal WIFI channel switching method, mobile terminal and storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
JAN WYCHOWANIAK、PIOTR PEREK、DARIUSZ MAKOWSKI等: "Automated generation of FRU devices inventory records for xTCA devices", 《PROCEEDINGS OF THE 18TH INTERNATIONAL CONFERENCE MIXED DESIGN OF INTEGRATED CIRCUITS AND SYSTEMS - MIXDES 2011》 *
梅建超: "IPMI在ATCA系统中的应用与架构设计", 《数字技术与应用》 *

Also Published As

Publication number Publication date
CN110781115B (en) 2021-07-02

Similar Documents

Publication Publication Date Title
US9110843B2 (en) Rack and method thereof for simultaneously updating basic input output systems
CN110347414A (en) Firmware update, device, equipment and computer readable storage medium
CN109412875B (en) zookeeper cluster automatic maintenance method and device
CN104866234A (en) Data migration method, device and system
CN108319492B (en) Method, device and system for resetting physical machine
CN108733454B (en) Virtual machine fault processing method and device
CN108897603B (en) Memory resource management method and device
CN110753040B (en) Request processing method and device
US11388274B2 (en) Method for implementing high availability of bare metal node based on OpenStack and electronic device using the same
CN110716892A (en) Board management method and device and communication board
CN108008969B (en) Software version upgrading method and device and network equipment
CN110781115B (en) Modification method and device for field replaceable unit and storage medium
CN110120877B (en) Configuration circuit of exchange chip and configuration method of parameters of exchange chip
CN110618828B (en) Data updating method and device
CN110555009B (en) Processing method and device for Network File System (NFS) service
US9172418B1 (en) User identity module protocol switch
CN110932884B (en) Method and device for adding multiple networks to cloud physical machine
CN109324871B (en) Virtual machine hardware configuration method and system
CN113141267B (en) Firmware upgrading and information processing method, device and equipment
CN113391959A (en) Anti-error method, device, equipment and medium for upgrading rollback of container of power monitoring system
CN110990052B (en) Configuration preservation method and device
CN113835741A (en) Patch loading method, network element and computer readable storage medium
CN106445623B (en) System component starting method and device
CN112636994A (en) Device testing method, system, network device and readable storage medium
CN112954036B (en) Software upgrading method, terminal equipment and system

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