CN100543676C - The method of firmware update - Google Patents

The method of firmware update Download PDF

Info

Publication number
CN100543676C
CN100543676C CNB2003101247022A CN200310124702A CN100543676C CN 100543676 C CN100543676 C CN 100543676C CN B2003101247022 A CNB2003101247022 A CN B2003101247022A CN 200310124702 A CN200310124702 A CN 200310124702A CN 100543676 C CN100543676 C CN 100543676C
Authority
CN
China
Prior art keywords
firmware
execution
firmware update
indication
stored
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.)
Expired - Fee Related
Application number
CNB2003101247022A
Other languages
Chinese (zh)
Other versions
CN1629808A (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.)
Tatung Co Ltd
Original Assignee
Tatung 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 Tatung Co Ltd filed Critical Tatung Co Ltd
Priority to CNB2003101247022A priority Critical patent/CN100543676C/en
Publication of CN1629808A publication Critical patent/CN1629808A/en
Application granted granted Critical
Publication of CN100543676C publication Critical patent/CN100543676C/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention relates to a kind of method of firmware update, can be used for the renewal of microprocessor internal firmware, the microprocessor internal group is provided with a store device, one load reservoir, reach a temporary reservoir, in the load reservoir, store firmware update program and firmware trace routine, when each start, whether detect firmware correct, in addition, can be in the process of firmware update, guarantee correctness and the integrality upgraded, if in the process of firmware update, the situation of firmware update failure takes place, processor will repeat the firmware update program, and the action of pointing out the user to re-execute firmware update, till completing successfully firmware update.

Description

The method of firmware update
Technical field
The invention relates to a kind of method of firmware update, refer to a kind of firmware update that is used for microprocessor especially.
Background technology
Be to carry out calculation process by microprocessor in the computer system, microprocessor can be carried out earlier usually and be stored in storage facilities (for example: the program ROM) is with as broker or driver, with as microprocessor and extraneous bridge of linking up.The program that is stored in storage facilities is general claim again be firmware, if firmware is to be mistake, its result will cause microprocessor to operate, hot good, under the user normally used, firmware was determined by manufacturer, and all is complete executable.As shown in Figure 1, conformability microprocessor 10 is to have store device (Application Memory) 11, load reservoir (Load Memory) 12, and temporary reservoir 13, but conformability microprocessor 10 access external storages 14 and carry out relevant data transmission with peripheral device 15.Wherein, load reservoir 12 internal reservoir firmware update programs, when the user desires to carry out the processing of firmware update, the firmware update program is loaded into the firmware of new edition in the store device in regular turn, after computer system is reset, conformability microprocessor 10 is written into the stored firmware in store device 11 inside, and conformability microprocessor 10 can be linked up with external storage 14 and peripheral device 15.Temporary reservoir 13 is to keep in value or store flag (Flag) in order to store, and flag can provide conformability microprocessor 10 to carry out the judgement that configuration (configuration) is set.
Because progressing greatly or carry out deinsectization (debug) and handle on the function, the user need carry out the firmware update program to obtain new or the more redaction firmware of function.The user carries out the firmware update program to upgrade conformability microprocessor 10 employed firmwares, if, upgrade in the process of firmware the user, it is unexpected that situation take place, for example: outage, the firmware transmission is interrupted, or situation such as firmware program code mistake, because conformability microprocessor 10 is not finished the step of firmware update as yet, this moment, conformability microprocessor 10 stored firmwares may be imperfect or wrong firmware, when computer system is reset, because firmware can't be loaded into conformability microprocessor 10 effectively and maybe can't carry out, computer system will enter the pattern when machine, at this moment., the user also can't learn the problem place that computer system produces.Therefore, the security of system when existing firmware update also can't effectively protect conformability microprocessor 10 to carry out firmware update, and give improved necessity.
Summary of the invention
Fundamental purpose of the present invention is that a kind of method of firmware update is being provided, so that can be in the process of firmware update, if when the firmware update failure takes place, with repeating the program of firmware update, till finishing firmware update.
Secondary objective of the present invention is that a kind of method of firmware update is being provided, so that can be in the process of firmware update, if when the firmware update failure takes place, microprocessor can point out the user to re-execute the action of firmware update.
For reaching above-mentioned purpose, the present invention discloses a kind of method of firmware update, can be used for the renewal of microprocessor internal firmware, the microprocessor internal group is provided with store device, load reservoir, reaches temporary reservoir, and it comprises the following steps: (A) computer system boot-strap; (B) read the stored firmware of load reservoir, and carry out; (C) judge whether to exist the renewal indication, if set up then execution in step (I); (D) judge whether to exist the mistake indication, if set up then execution in step (I); (E) judge whether the stored firmware of store device is correct, if be false then execution in step (K); (F) read the stored firmware of store device, and carry out; (G) judge whether the stored firmware of desire renewal store device, if be false then repeated execution of steps (G); (H) store renewal indication and execution in step (B); (I) program of execution firmware update; (J) judge whether the stored firmware of store device is correct, if set up then execution in step (L); (K) store wrong indication and execution in step (B); And (L) remove to upgrade indication and should the mistake indication and execution in step (B); Wherein renewal indication and wrong indication are to be stored in temporary reservoir.
Description of drawings
Fig. 1 is the calcspar of computer system;
Fig. 2 is the process flow diagram of firmware update of the present invention.
Embodiment
For more understanding technology contents of the present invention, be described as follows especially exemplified by a preferred embodiment.
Under the framework of figure computer system, and in load reservoir 12 internal reservoir firmwares, this firmware is to comprise: firmware update program and firmware trace routine.Whether the firmware trace routine is correct in order to detect the stored firmware program code of store device 11, whether the mode of its detection is preferably uses bug check sign indicating number (checksum code) correct to detect firmware program code, certainly, the user also can add bogus program sign indicating number (pseudo code) and carries out the detection of firmware program code for the firmware trace routine in firmware program code.
See also shown in Figure 2ly, the method for firmware update of the present invention is to be applied to conformability microprocessor 10, and needs store device 11, load reservoir 12, and the cooperation running of temporary reservoir 13, and it comprises the following steps:
Step S20: computer system boot-strap.
Step S21: read the stored firmware of load reservoir 12, and carry out.When computer system boot-strap, conformability microprocessor 10 will read the stored firmware of load reservoir, and carries out this firmware.
Step S22: judge whether to exist to upgrade and indicate? conformability microprocessor 10 is checked the flag of temporary reservoir 13, indicates to judge whether to exist to upgrade.Suppose that a flag in the temporary reservoir 13 is as the renewal flag, and its preset value is 0.If upgrading the flag target value is 1 o'clock, execution in step S28 then, otherwise execution in step S23.
Step S23: judge whether to exist the mistake indication? conformability microprocessor 10 is checked the flag of temporary reservoir 13, to judge whether to exist the mistake indication.Suppose that another flag in the temporary reservoir 13 is as wrong flag, and its preset value is 0.If wrong flag target value is 1 o'clock, execution in step S28 then, otherwise execution in step S24.
Step S24: judge whether the stored firmware of store device correct? conformability microprocessor 10 is called out the firmware trace routines when detecting the stored firmware of store device 11, if firmware program code is correct, then altering error flag target value not, and execution in step S25; When the firmware trace routine was carried out the firmware detection, the result of detection was expression firmware program code mistake, then execution in step S30.
Step S25: read the stored firmware of store device 11, and carry out.When reading store device 11 stored firmwares is for correct and when complete, and conformability microprocessor 10 begins to read the stored firmware of store device 11, and carries out.
Step S26: judge whether the stored firmware of desire renewal store device? if user's desire is upgraded firmware, execution in step S27 then, otherwise, repeated execution of steps S26.
Step S27: store and upgrade indication.Conformability microprocessor 10 will upgrade the flag target value and change to 1 by 0, upgrade indication to store, and execution in step S21.
Step S28: the program of carrying out firmware update.The inner stored firmware update program of conformability microprocessor 10 call load reservoirs 12 is carrying out the program of firmware update, and execution in step S29.Well imagine that this moment, the user need provide the firmware program code of new edition, the firmware update program can be finished the program of firmware update.
Step S29: judge whether the stored firmware of store device correct? whether the inner stored firmware trace routine of conformability microprocessor 10 call load reservoirs 12 is correct to judge the stored firmware of store device.If firmware is for complete and correct, execution in step S31 then, otherwise execution in step S30.
Step S30: store wrong indication.Conformability microprocessor 10 changes to 1 with wrong flag target value by 0, indicates to store mistake, and execution in step S21.
Step S31: remove and upgrade indication and wrong indication.Conformability microprocessor 10 will upgrade flag and wrong flag target value, all change to 0 by 1, upgrade indication and wrong indication to remove, and execution in step S21.
Thus, computer system checks by the firmware trace routine whether firmware is correct when each start, if unusual situation appears in firmware, then informs the unusual situation of this firmware of user by the user interface, and execution in step S28 is to upgrade firmware.Thus, can guarantee to upgrade the integrality and the correctness of firmware process, the situation of avoiding the user to cause computer system to start shooting because of firmware error.
The foregoing description only is to give an example for convenience of description, and the interest field that the present invention advocated should be as the criterion so that claim is described certainly, but not only limits to the foregoing description.

Claims (2)

1. the method for a firmware update can be used for the renewal of the firmware on the microprocessor internal store device, and the microprocessor internal group is provided with this store device, a load reservoir, reaches a temporary reservoir, it is characterized in that it comprises the following steps:
(A) computer system boot-strap;
(B) read the stored firmware of this load reservoir, and carry out;
(C) judge whether to exist one to upgrade indication, if set up then execution in step (I);
(D) judge whether to exist a wrong indication, if set up then execution in step (I);
(E) judge whether the stored firmware of this store device is correct, if be false then execution in step (K);
(F) read the stored firmware of this store device, and carry out;
(G) judge whether that desire upgrades the stored firmware of this store device, if be false then repeated execution of steps (G);
(H) store this renewal indication and execution in step (B);
(I) program of execution firmware update;
(J) judge whether the stored firmware of this store device is correct, if set up then execution in step (L);
(K) store this mistake indication and execution in step (B); And
(L) remove this renewal indication and should the mistake indication, and execution in step (B); Wherein
This renewal indication and the indication of this mistake are to be stored in this temporary reservoir.
2. the method for claim 1 is characterized in that, described this renewal indication and the indication of this mistake are the forms with flag, are stored in this temporary reservoir.
CNB2003101247022A 2003-12-18 2003-12-18 The method of firmware update Expired - Fee Related CN100543676C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2003101247022A CN100543676C (en) 2003-12-18 2003-12-18 The method of firmware update

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2003101247022A CN100543676C (en) 2003-12-18 2003-12-18 The method of firmware update

Publications (2)

Publication Number Publication Date
CN1629808A CN1629808A (en) 2005-06-22
CN100543676C true CN100543676C (en) 2009-09-23

Family

ID=34845053

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2003101247022A Expired - Fee Related CN100543676C (en) 2003-12-18 2003-12-18 The method of firmware update

Country Status (1)

Country Link
CN (1) CN100543676C (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI475486B (en) * 2012-06-06 2015-03-01 Acer Inc Method for executing key function and electronic apparatus
TWI478061B (en) * 2012-04-03 2015-03-21 Asrock Inc Method for updating firmware
TWI498822B (en) * 2012-12-27 2015-09-01 Giga Byte Tech Co Ltd Electronic device for bios updatable and bios updating method thereof

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8893112B2 (en) * 2009-12-21 2014-11-18 Intel Corporation Providing software distribution and update services regardless of the state or physical location of an end point machine
CN104239109A (en) * 2014-09-30 2014-12-24 上海瑞猫自动化控制技术有限公司 Method for on-line management of embedded system firmware
CN111766797A (en) * 2019-04-02 2020-10-13 海盗船存储器公司 Microcontroller, memory module and method for updating firmware of microcontroller
CN111651297B (en) * 2020-05-21 2023-10-03 深圳市同泰怡信息技术有限公司 SPS firmware monitoring method and monitoring system

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI478061B (en) * 2012-04-03 2015-03-21 Asrock Inc Method for updating firmware
TWI475486B (en) * 2012-06-06 2015-03-01 Acer Inc Method for executing key function and electronic apparatus
TWI498822B (en) * 2012-12-27 2015-09-01 Giga Byte Tech Co Ltd Electronic device for bios updatable and bios updating method thereof

Also Published As

Publication number Publication date
CN1629808A (en) 2005-06-22

Similar Documents

Publication Publication Date Title
US20070074201A1 (en) Method and system for updating software and computer readable recording medium storing the method
US7512749B2 (en) Safe software revision for embedded systems
US20040205745A1 (en) Method and system for identifying compatibility between firmware images
US20030037225A1 (en) Apparatus and method for microcontroller debugging
US20140136826A1 (en) Method and apparatus for updating boot loader
US20140201726A1 (en) Updating firmware compatibility data
CN101373451B (en) Computer system for protecting double-basic input /output system program and control method thereof
CN111142911B (en) Embedded system with abnormal recovery function and upgrading method thereof
CN103761112A (en) Vehicle-mounted multimedia device and control method thereof
CN104335186A (en) Processor assist facility
CN108197476B (en) Vulnerability detection method and device for intelligent terminal equipment
CN103019787A (en) Function call relation determining method, hotfix updating method and hotfix updating device
CN103777971A (en) Electronic device, method for updating firmware, and recording medium capable of being read by computer
EP3977288B1 (en) Executable code branch annotations for objective branch verification
CN100543676C (en) The method of firmware update
CN112379932A (en) Boot method and Boot device of electronic equipment and electronic equipment
CN106201640A (en) A kind of method and device of BootLoader program of upgrading
CN100570560C (en) Start chip software version information method to set up and device
JP5167936B2 (en) Information processing device
WO2015184732A1 (en) Bootstrap storage method, bootstrap fault recovery method and device, and computer storage medium
CN113238790B (en) Firmware program updating method and system based on SD card and EEPROM
CN113138791A (en) Upgrade processing method and device based on embedded system and electronic equipment
CN111857785B (en) MCU starting method and device and terminal equipment
CN111352764A (en) Chip repairing method, device, equipment and storage medium
CN113360161A (en) Resource upgrading method and related product

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
C17 Cessation of patent right
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20090923

Termination date: 20111218