A system and method for implementing a boot recovery on a data processing system. According to an embodiment of the present invention, at least one processor compares contents of a first read-only memory (rom) image and a second rom image outputted from a memory. The first rom image is initially selected to boot a data processing system utilizing a first basic input output system (bios) program. In response to determining that contents of the first rom image and the second rom image are different, the second rom image is selected. The data processing system boots utilizing the second bios program stored by the second rom image.
|
7. A computer-implementable method for implementing boot/recovery in a data processing system that includes a first read-only memory (rom) image storing a first basic input output system (bios) program and a second rom image, a replica of said first rom image, that stores a second bios program that is identical to said first bios program, said computer-implementable method comprising:
starting a boot process on said data processing system utilizing said first bios program stored by said first rom image;
comparing contents of said first rom image and said second rom image;
in response to determining said contents are different, determining whether there is an error data pattern in said first rom image;
in response to determining there is an error data pattern in said first rom image, selecting said second rom image; and
booting said data processing system utilizing said second bios program stored by said second rom image.
1. A data processing system comprising:
a processor;
a memory, coupled to said at least one processor, for storing a first read-only memory (rom) image that stores a first basic input output system (bios) program for booting said data processing system and a second rom image that is a replica of said first rom image that stores a second bios program identical to said first bios program; and
a computer-usable medium embodying instructions executable by said at least one processor and configured for:
initially selecting said first rom image to boot said data processing system by utilizing said first bios program stored in said first rom image;
comparing contents of said first rom image and said second rom image outputted from said memory;
in response to a determination that contents of said first rom image are different contents from said second rom image, detecting an error data pattern in said first rom image and said second rom image outputted from said memory; and
in response to a detection of an error data pattern, selecting said second rom image and booting said data processing system utilizing said second bios program stored by said second rom image.
10. A computer-implementable method for implementing boot/recovery in a data processing system that includes stores a first read-only memory (rom) image pair that includes a first rom image that stores a first basic input output system (bios) program for booting said data processing system and a second rom image, a replica of said first rom image, that stores a second bios program that is identical to said first bios program, and wherein said memory stores a second rom image pair that includes a third rom image that stores a third bios program that is identical to or different from said first bios program and a fourth bios program, a replica of said third rom image, that stores a fourth bios program that is identical or different from said first bios program, said computer-implementable method comprises:
starting a boot process on said data processing system utilizing said first bios program stored by said first rom image included in said first rom image pair; comparing contents of said first rom image and said second rom image;
in response to determining said contents of said first rom image and said second rom image are different, selecting said second rom image pair;
booting said data processing system utilizing said third bios program stored by said third rom image included in said second rom image pair;
comparing contents of said third rom image and said fourth rom image; and
in response to determining that said contents of said third rom image and said fourth rom image are identical, replacing said first rom image and said second rom image with said third rom image.
4. A data processing system comprising:
at least one processor;
an interconnect coupled to said at least one processor;
a memory coupled to said at least one processor via said interconnect, wherein said memory stores a first read-only memory (rom) image pair that includes a first rom image that stores a first basic input output system (bios) program for booting said data processing system and a second rom image, a replica of said first rom image, that stores a second bios program that is identical to said first bios program, and wherein said memory stores a second rom image pair that includes a third rom image that stores a third bios program that is identical to or different from said first bios program and a fourth bios program, a replica of said third rom image, that stores a fourth bios program that is identical or different from said first bios program;
a computer-usable medium embodying computer program code, said computer-usable medium being coupled to said interconnect, said computer program code comprising instructions executable by said at least one processor and configured for:
in response to receiving said first rom image pair outputted from said memory, comparing said first rom image and said second rom image;
in response to receiving said second rom image pair, comparing said third rom image and said fourth rom image;
initially selecting said first rom image pair to boot said data processing system utilizing either said first bios program stored in said first rom image or said second bios program stored in said second rom image;
in response to determining contents of said first rom image and said second rom image are different, selecting said second rom image pair; and
booting said data processing system utilizing either said third bios program stored in said third rom image or said fourth bios program stored in said fourth rom image.
2. The data processing system according to
in response to switching between said first rom image and said second rom image, resetting said data processing system.
3. The data processing system according to
in response to detecting an error data pattern in said second rom image, selecting said first rom image.
5. The data processing system according to
detecting an error data pattern in said first rom image and said second rom image outputted from said memory; and
inputting a detection result.
6. The data processing system according to
in response to determining contents of said first rom image and said second rom image are identical, booting said data processing system utilizing said first bios program stored in said first rom image included in said first rom image pair; and
replacing said third rom image and said fourth rom image included in said second rom image pair with said first rom image.
8. The computer-implementable method according to
in response to determining said contents of said first rom image and said second rom image are identical, booting said data processing system utilizing said first bios program of said first rom image.
9. The computer-implementable method according to
in response to determining an error data pattern is detected in said second rom image, replacing said second rom image with said first rom image.
11. The computer-implementable method according to
in response to determining contents of said first rom image and said second rom image are identical, comparing contents of said third rom image and said fourth rom image; and
in response to determining said third rom image is different from said fourth rom image, replacing said third rom image and said fourth rom image with said first rom image.
|
This application claims priority of Japanese Patent Application No. 2006-340224 filed on Dec. 18, 2006, and entitled, “Information Processing System and Boot-Recovery Method Thereof.”
1. Technical Field
This invention relates to a data processing system such as a personal computer. In particular, the invention relates to an information processing system including multiple read-only memory (ROM) images each storing a basic input output system (BIOS) program for executing initialization and so forth during a boot.
2. Description of the Related Art
A BIOS program generally includes a BIOS main body (core block) for executing initialization of various types of devices, loading of an operating system (OS), and so forth and a boot block that boots up immediately after a computer is turned on or reset to execute a cyclic redundancy check (CRC) or the like to detect an error and returns control to the BIOS main body if there is no problem. The BIOS program's failure in operating normally prevents the computer from booting up, so some configurations have been adopted to cope with such failure.
In general, a central processing unit (CPU) reads and executes an instruction from an address set up in a program counter. When the power is turned on, the program counter is set to a default, which typically refers to the top of an initialization code in a ROM. Incidentally, writable flash ROMs have often been used as ROMs in recent years. This is advantageous in that a flash memory can be rewritten without having it to be removed even if a problem has occurred in a program.
Corruption or erasure of an initialization code per se in a flash ROM prevents the system from booting up. Therefore, the initialization code is handled in a special manner as a boot block in the flash ROM, and its rewriting is restrained as much as possible. For this reason, the initialization code stored in the boot block is generally programmed so as to be processed independently of a function block. Upon completing initialization of the system, the initialization code transfers control to the function block and the system performs ordinary processes.
The present invention includes a system and method for implementing a boot recovery on a data processing system. According to an embodiment of the present invention, at least one processor compares contents of a first read-only memory (ROM) image and a second ROM image outputted from a memory. The first ROM image is initially selected to boot a data processing system utilizing a first basic input output system (BIOS) program. In response to determining that contents of the first ROM image and the second ROM image are different, the second ROM image is selected. The data processing system boots utilizing the second BIOS program stored by the second ROM image.
At power-on of the data processing system 100, the CPU 102 sets up its operation parameters (many of them are stored in the memory 106), initializes the memory 106, executes inspection and initialization of system components, and boots the operating system before starting usual user operations. When power is supplied to the data processing system 100, the CPU 102 as a system processor begins to execute a part of a BIOS program called “power on reset (POR).”
The CPU 102 controls the entire data processing system according to the code of a computer program written to the memory 106. Also, the CPU 102 is made accessible to the memory 106 or the like according to data on the BIOS program stored in the ROM 200 at a boot. The ROM 200 is preferably a programmable flash ROM. A flash ROM is a memory that is readable and writable and whose content is retained even at power-off. It stores BIOS data to be used to perform a process such as setup of an input-output device of a data processing system (also referred to as a “computer system”) at a boot of the system.
The ROM 200 will now be described using a flash ROM.
As shown in
As shown in
A function of the boot/recovery mechanism 300 is to select another ROM image even if a ROM image selected at a boot of the data processing system is damaged (at this time, the comparison circuit detects that two ROM images, which must have identical contents when they are normal, are different), to reset the system, more specifically, the CPU using a system resetter, and to reboot the system using a newly selected ROM image. Another function of the boot/recovery mechanism 300 is to execute a boot/recovery program stored in an undamaged ROM image by CPU to replace data on the damaged ROM image with that on the undamaged ROM image, that is, to replicate (also referred to as “copy”) the image content.
As shown in
The comparison circuit 302 includes, for example, a difference circuit for obtaining differences between data signals from data buses coupled to a ROM, including multiple signal lines, and an OR circuit for obtaining an OR result of the obtained difference signals. If two ROM images have identical data, all difference signals each have an identical value 0 and the OR circuit outputs a value 0. If the two ROM images have different data, any one of difference signals has a value 1 and the OR circuit outputs a value 1. In other words, checking the output of the OR circuit allows the two ROM images to be compared. As the comparison circuit 302, an XOR circuit, whose circuit configuration is relatively simple, may be used. In this case, a general XOR circuit may be used.
An example of the address switch 304 is a circuit for outputting a chip select (CS) signal for selecting an address line A having a value 1 or a value 0, which is a circuit serving to invert a value outputted from an output pin. For example, if the circuit receives a signal (value 1) from the comparison circuit while a value 0 is outputted as the address line A (refers to start address of ROM image 1) from the output pin, the circuit changes the value of the address A to be outputted from the output pin, to a value 1. Switching between the ROM images 1 and 2 is controlled by a CS signal for selecting the address line corresponding to these ROM images. As for operations, if the ROM image 1 is initially selected, the value of the address A is 0 and the CS signal indicates the ROM image 1. However, if the address switch 304 receives a value 1 from the comparison circuit because the ROM images have different contents, the address switch 304 makes the address line a value 1 to switch to the ROM image 2 so that the output of the CS signal indicates the ROM image 2. For example, the address switch 304 is realized by a flip-flop circuit for inverting an output value each time a signal from the comparison circuit is inputted.
System resetter 306 generates a reset signal to reset the CPU 102 of the system 100 upon receiving a signal indicating operation (or performance) of switching between ROM images from the address switch 304.
Further, it is also possible to display the state of a system error or the like on the external display 124 or the like via the display controller 122 in response to a signal from the address switch 304.
When power is turned on or the CPU is initially reset, that is, when power-on reset (POR) is performed (S501), the address is set to that of the ROM 1 by the address switch to select the ROM 1 (S502). Thus data in the ROM 1 is outputted to the CPU. Then data outputs of the ROMs 1 and 2 are inputted to an XOR circuit serving as a comparison circuit. An XOR computation is performed to compare the data outputs, and which operation should be taken next is determined on the basis of a result of the computation (S503). If data is normally outputted from the ROM 1 to the CPU, the same data as that in the ROM 1 is outputted from the same address of the ROM 2 to the XOR circuit. Thus the output based on a result of the computation in the XOR circuit 302 becomes “0” (value 0), and the boot operation continues normally (S505). If data in the ROM 1 is damaged in step S503, data in the ROM 1 and data in the ROM 2 are not matched, that is, these pieces of data have different contents. Thus the output of the XOR circuit becomes “1” (value 1) and a boot error is detected. If an error is detected, the address switch 304 switches to the address of the ROM 2 in order to output data in the ROM 2 to the CPU, that is, in order to switch to a BIOS program in the ROM 2 (S504). Subsequently, the CPU 102 is reset using system resetter 306 in response to the address switch and then rebooted using the BIOS program in the ROM 2 (S506). In the first embodiment, the image data in the ROM 1 is replaced with that in the ROM 2 assuming that the ROM 1 has a problem. In other words, it is not detected which of the ROM images is damaged. Note that if the image data in the ROM 2 is initially outputted to the CPU, operations will be performed with the ROM 1 and the ROM 2 interchanged with each other.
In the configuration shown in
A method for writing data (including a program code; the same goes for the description below) to the flash ROM will now be described. The operations of the error data pattern detection circuit (FF detection circuit) 308 are carried out using this method.
1) Erase the region of the current ROM image (S601). Data in the flash ROM will be erased on a block-by-block basis according to an erase command. At this time all the erased blocks will become “1”, that is, FF.
2) Write parts of a new ROM image except for a top part (610) of the initialization code to the ROM (S602).
3) Write normal data to the top part 610 of the initialization code of the new ROM image (S603).
A feature of this write method is that if a data writing to the ROM has succeeded, all data is written without a problem (S605). However, if a problem has occurred in writing data due to a problem or for other reasons, normal data is yet to be written to the top part 610 of the ROM image and FF data remains there (S604). If FF data is left in the region of the ROM 1 and is not left in the region of the ROM 2, it is understood that normal data is written to the ROM 2. While an example in which data is written to parts of the initialization code except for the top part 610 thereof has been described in
As with the comparison circuit 302, the error data pattern circuit 308 includes a difference circuit for obtaining differences between data signals from data buses coupled to ROM, including multiple signal lines, and an OR circuit for obtaining an OR result of the obtained difference signals. If a difference between data in a normal ROM image and a data signal from a ROM image including an error data pattern (e.g., O×FF) is obtained and then a value 1 is outputted by the OR circuit that has received the obtained difference signal outputs, it is demonstrated that the pieces of data in the ROM images have different contents. This allows an error data pattern to be detected.
Note that if data in the ROM 2 is initially outputted to the CPU, the above-mentioned steps are taken with the ROMs 1 and 2 interchanged with each other.
Note that in the description below and the corresponding flowcharts, booting the system using a BIOS program in a ROM image may be referred to as “booting (performing a boot process) using ROMx (x is an integer),” and replicating a ROM image to another ROM image referred to as “copying the ROM 2 to the ROM 1”, for example.
If a ROM image is damaged by a problem other than a write operation to the ROM image during operation of the data processing system, it is also possible to detect such a problem and to switch the damaged ROM image to a normal ROM without resetting the system.
In addition to the flash ROM 200 described above, the data processing system shown in
While an example in which XOR circuits are used as comparison circuits is described here, other types of comparison circuits can be used. Incidentally the address switch 804 includes a counter (n) 805 for counting the number n corresponding to the currently selected ROM image pair so as to select a ROM image pair and thus boot a BIOS program in each ROM image. The n-th ROM image pair is made up of two ROM images, ROM 2n−1 and ROM 2n (n is an integer).
If one of two ROM images (having identical contents when they are normal) forming a ROM image pair initially booted up is damaged, the corresponding XOR circuit outputs “1” (value 1). This makes it possible to detect that the ROM image pair currently being booted is damaged. If it is detected that the ROM image pair currently being used for a boot is damaged, the following series of operations can be performed: a signal (value 1) is sent to the address switch 804, the address switch 804 switches to the address of another ROM image pair, and a boot is attempt using a BIOS program in one of ROM images forming the ROM image pair to which the address switch 804 has switched.
Further, in order to enhance reliability of an data processing system while preventing occurrence of a boot error as much as possible, it is possible to extend the configuration shown in
Operations of the data processing system having four ROM images that has the basic configuration according to the third embodiment will be described with reference to
In
If the output of XOR circuit 1 812 is ‘1’ in step S905, counter (n) 805 is set to n=2 by increasing the count by 1 (S906), the address switch 804 is set to the image pair (2) 820 formed by the ROMs 3 and 4, which is the second image pair formed by ROM images having the numbers 2n−1 and 2n, and the CPU is reset (S907), and a boot process is performed using a BIOS program in one of the ROM images forming image pair (2) 820, for example, ROM 3 (S908). Further the image outputs of the ROMs 3 and 4 are inputted to the XOR circuit 2 822 and subjected to a computation process (S909). If the computation process results in ‘0’, the image pair (2) 820 is normal. The image of the ROM image 3 (ROM 3) is copied to the ROM images 1 and 2 (ROM 1/ROM 2) forming the ROM image pair (1) 810, which may be damaged (S931). Further a boot process is performed, for example, using a BIOS program in ROM 3 (S950). If the computation process results in ‘1’ in step 909, it is considered that none of the two ROM image pairs has correct data. Thus a system error is displayed on the external display 124 via the display controller 122 (S910).
The configuration shown in
If any ROM image pair has succeeded in booting up the system normally and if the number p of a ROM image pair that has failed to boot up the system normally is smaller than the number n of the ROM image pair that has succeeded in booting up the system normally, a process for replacing (copying) the failed ROM image pair p (including ROM 2p−1 and ROM 2p; p is an integer) with ROM 2n−1 in the successful ROM image pair is performed with accordance with the steps shown in (a) of
If a ROM image pair has succeeded in booting up the system normally but there are ROM image pairs with which no attempt to boot the system has been made, subsequent to the successful ROM image pair, the steps (S1131 to S1135) shown in
The count of p and m, comparison between ROM 2m−1 and ROM 2m, or the like can be included in a program code of a boot/recovery block (see
While it is conceivable that a data processing system according to this invention is a computer system, such as a personal computer as shown in
While it is also possible to store the current status of the address switch in the flash ROM so as to retain the current status even at power-off in the above-mentioned embodiments, the current status may be stored in a memory such as a non-volatile RAM (NVRAM).
While the above-mentioned embodiments are configured so that groups made up of two ROM images, each of which has a BIOS program, are formed among multiple ROM images in a ROM and switching between those groups are performed, it is also possible to form groups made up of three or more ROM images (each of which has a BIOS program) and to perform switching between these groups sequentially using an address switch.
While a flash ROM is used as a memory for storing a BIOS program in the above-mentioned embodiments, a BIOS program may be stored in an electronically erasable and programmable read-only memory (EEPROM) or the like.
While the embodiments of this invention have heretofore been described, this invention is not limited to these embodiments. Alternatively, various improvements, modifications, or alterations can be made to these embodiments on the basis of the knowledge of those skilled in the art without departing from the spirit and scope of this invention.
Patent | Priority | Assignee | Title |
10191811, | Aug 13 2015 | QUANTA COMPUTER INC. | Dual boot computer system |
8086841, | Oct 24 2008 | Wistron Corp. | BIOS switching system and a method thereof |
Patent | Priority | Assignee | Title |
5793943, | Jul 29 1996 | Round Rock Research, LLC | System for a primary BIOS ROM recovery in a dual BIOS ROM computer system |
5835695, | Jul 29 1996 | Round Rock Research, LLC | Method for a primary BIOS ROM recovery in a dual BIOS ROM computer system |
6308265, | Sep 30 1998 | KINGLITE HOLDINGS INC | Protection of boot block code while allowing write accesses to the boot block |
6754818, | Aug 31 2000 | Oracle America, Inc | Method and system for bootstrapping from a different boot image when computer system is turned on or reset |
6757838, | Oct 13 2000 | HEWLETT-PACKARD DEVELOPMENT COMPANY, L P | Hardware independent implementation of computer system BIOS recovery |
6892323, | May 05 1999 | GIGA-BYTE TECHNOLOGY CO., LTD. | Dual basic input/output system for a computer |
7007159, | May 10 2002 | Sony Corporation of America | System and method for loading and integrating a firmware extension onto executable base system firmware during initialization |
7100087, | Dec 28 2001 | AsusTek Computer Inc. | Module and method for automatic restoring BIOS device |
7318173, | Jun 03 2002 | National Semiconductor Corporation | Embedded controller based BIOS boot ROM select |
20030005277, | |||
20030120907, | |||
20030149852, | |||
20040193862, | |||
20040268116, | |||
20050273588, | |||
20070033390, | |||
20070136638, | |||
JP2000148467, | |||
JP2000163268, | |||
JP2004013719, | |||
JP2004038529, | |||
JP5028056, | |||
JP61061299, |
Executed on | Assignor | Assignee | Conveyance | Frame | Reel | Doc |
Nov 06 2007 | KIMURA, TOMOAKI | International Business Machines Corporation | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 020100 | /0806 | |
Nov 09 2007 | ABE, ATSUSHI | International Business Machines Corporation | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 020100 | /0806 | |
Nov 13 2007 | International Business Machines Corporation | (assignment on the face of the patent) | / |
Date | Maintenance Fee Events |
Oct 10 2014 | REM: Maintenance Fee Reminder Mailed. |
Mar 01 2015 | EXP: Patent Expired for Failure to Pay Maintenance Fees. |
Date | Maintenance Schedule |
Mar 01 2014 | 4 years fee payment window open |
Sep 01 2014 | 6 months grace period start (w surcharge) |
Mar 01 2015 | patent expiry (for year 4) |
Mar 01 2017 | 2 years to revive unintentionally abandoned end. (for year 4) |
Mar 01 2018 | 8 years fee payment window open |
Sep 01 2018 | 6 months grace period start (w surcharge) |
Mar 01 2019 | patent expiry (for year 8) |
Mar 01 2021 | 2 years to revive unintentionally abandoned end. (for year 8) |
Mar 01 2022 | 12 years fee payment window open |
Sep 01 2022 | 6 months grace period start (w surcharge) |
Mar 01 2023 | patent expiry (for year 12) |
Mar 01 2025 | 2 years to revive unintentionally abandoned end. (for year 12) |