[Not Applicable]
[Not Applicable]
1. Field of the Invention
The present invention relates generally to update of firmware/software components in mobile handsets using an update agent, and, more specifically, to the generation of compact update packages employing optimization techniques.
2. Background of the Art
Electronic devices, such as mobile phones and personal digital assistants (PDAs), often contain firmware and application software that are either provided by the manufacturer of the electronic devices, by telecommunication carriers, or by third parties. These firmware and application software often contain software bugs. New versions of the firmware/software are periodically released to fix the bugs or to introduce new features, or both.
When informing a mobile electronic device of the need to update its firmware/software, problems might arise. For example, problems may arise when attempting to control the size of an update package containing the difference information. Update package generation is prone to an “avalanche” effect, wherein a minor change to code may result in relocation of a large amount of other code or components. The relocation of the code may result in difference information that is very large, thereby prolonging the download process and making it more costly. Other problems may arise, such as the inability to clearly and efficiently specify the steps needed to update firmware/software in the electronic device to a new version.
Further limitations and disadvantages of conventional and traditional approaches will become apparent to one of ordinary skill in the art through comparison of such systems with the present invention as set forth in the remainder of the present application with reference to the drawings.
Aspects of the present invention may be seen in a mobile services network comprising a mobile electronic device having a non-volatile memory, a random access memory and security services; the network further comprising a management server; an update package repository; and a generator with a partial predictive mapping (PPM) preprocessor for generating update packages for updating an old version of a firmware to a new version of the firmware. The update packages generated by the generator with a partial predictive mapping (PPM) preprocessor may incorporate a shift region list.
The process of generating an update package with the generator with a partial predictive mapping (PPM) preprocessor comprises creating a module map of module locations and sizes in the old image of firmware versus the new image of firmware; creating a shift region list; and generating an update package with the shift region list information.
The shift region list is created by, for example, identifying shift points within each module of the firmware, wherein the shift points define shift regions; creating and modifying a first shift region list to include external shifts; consolidating shift regions across modules if address adjustments remain the same across a module boundary; and creating a second shift region list by consolidating shift regions from the first shift region list.
These and other features and advantages of the present invention may be appreciated from a review of the following detailed description of the present invention, along with the accompanying figures in which like reference numerals refer to like parts throughout.
In one embodiment, the generator with a partial predicting mapping preprocessor 145 may be coupled to the update package repository 133. The management server 109 may access the update package repository 133 to retrieve the update packages and associated information, such as metadata, shift region list information, etc.
In another embodiment, the generator with a partial predicting mapping preprocessor 145 may be located at a location remote from the update package repository 133. In such an embodiment, the output of the generator with a partial predicting mapping preprocessor 145, namely update packages and associated shift region list information, etc., may be communicated to the update package repository 133 through a storage medium, such as a CD-ROM disk, and loaded into the update package repository 133. Then, the update package may be disseminated to the mobile handset 107 via the management server 109. The generator with a partial predictive mapping preprocessor 145 may generate an update package and associated information, by comparing two different versions of the firmware/software of the mobile handset 107.
The mobile handset 107 may comprise a non-volatile memory 111, a random access memory (RAM) 125, and security services 123. The non-volatile memory 111 of the mobile handset 107 may comprise an update agent 113 with partial predictive mapping support, a firmware and real-time operating system (RTOS) 115, an operating system (OS) layer 117, a download agent or browser 119, an end-user-related data and content 121, and boot initialization 127.
In one embodiment, the mobile handset 107 downloads an update package from the update package repository 133, and then reboots. Upon rebooting, the mobile handset 107 starts up, executes the boot initialization 127, and determines whether the update agent 113 needs to execute the update process. The decision to execute the update process by the update agent 113 may be based on status information such as, for example, the availability of an update package. The status information may be available in the non-volatile memory 111. If it is determined that the update agent 113 needs to execute the update process, the mobile handset 107 may invoke the update agent 113.
In one embodiment, the generator with a partial predictive mapping preprocessor 145 may generate a list of shift regions when it generates an update package. Each entry in the list of shift regions may comprise three values, for example, one value indicating a shift region number, another value indicating shift region length, and the last value indicating an adjustment value used as an offset, as illustrated in an example hereinafter. The shift region list may be incorporated into the update package and loaded into the update package repository 133. When the mobile handset 107 requests an update package from the management server 109, the update package may be delivered to the mobile handset 107 from the update package repository 133 via the management server 109. The update agent 113 in the mobile handset 107 may execute a “preprocessing” step using the shift region list, to prepare the existing or old image of the firmware/software for update. After the preprocessing, the update agent 113 may employ other information from the update package to update the firmware/software.
In one embodiment, the partial predictive mapping technique for preprocessing binary images of firmware/software may utilize “logical” alignment elements within different versions of code such as, for example, an old version and a new version of firmware. The output of the partial predictive mapping preprocessor component of the generator with a partial predictive mapping preprocessor 145 may include shift-related information in terms of location of the region, length of the region, and the associated offset. The shift-related information may be incorporated into the update package to be sent as a single package to the mobile handset 107.
The update package generation by the generator with a partial predictive mapping preprocessor 145 may be used for mobile handsets and other electronic devices, such as devices that contain code or data in non-volatile memory which may require updates to newer or different versions.
In a firmware image, there may be thousands of modules. Each module may shift its location and/or change its order relative to other modules, as show in
In one embodiment, as illustrated by the example of
In the example illustrated by
A partial predictive mapping shift region list is a list of shift regions as described hereinabove, along with their shift adjustments. A shift region list may be created by a generator analysis module, and used by a preprocessor in a generator with a partial predictive mapping preprocessor to modify branch link address/offset parameters throughout the affected portion of the firmware image. The modifications may adjust branch link address/offset parameters in the old image of the firmware to match the new image of the firmware. The generator with a partial predictive mapping preprocessor may then process the modified old image and the new image to produce difference information comprising core generator instructions. Using this approach, the partial predictive mapping preprocessor may not need to produce accurate adjustments to branch link address parameters in all cases, but improves core generator efficiency in the majority of cases. Hence, partial predictive mapping is designed to produce a high accuracy of branch link address parameter adjustment despite module shifts and/or changes in module order.
In one embodiment, the partial predictive mapping implementation may utilize executable and linking format (ELF) files to determine module location changes. However, shift region lists may also be created by using only the old and new binary images of the firmware, such that partial predictive mapping may change from a tool chain-specific approach to a CPU-specific approach. The preprocessor may determine where modules begin and end in both the old and the new images of firmware, by analyzing the old and new binary images.
To create a shift region list, the partial predictive mapping preprocessor may identify shift points. In one embodiment, the partial predictive mapping preprocessor may identify shift points within each module, and consolidate shift regions across modules if branch link adjustments are the same across a module boundary. This may be done, for example, using two preprocessing operations, one for analysis, and another for preprocessing shift information to be output to the core generator.
The analysis operation may consist of several steps. A first step may create a module map, which may be comprised of module locations and sizes in the old image of firmware and the new image of firmware. The module map may be used by the partial predictive mapping preprocessor in the generator with a partial predictive mapping preprocessor. The next step, step 2, in creating a shift region list may create an initial shift region list for “internal” shifts. In this list, each shift region may correspond to a module in the old image of firmware. The “adjustment” value in this case may be the difference between the start location of the module in the old image and the start location of the same module in the new image of firmware. Step 3 may modify the shift region list for “external” shifts. In this step, the preprocessor may identify the modules that have changed in size from the old image to the new image of firmware. The preprocessor may then adjust the branch link addresses in the old image of firmware by the adjustment values from step 2. Adjusting the branch link addresses makes it possible to identify areas where new code may have been inserted, added, or removed. Each area of the new image that is different from the old image may result in a shift point inside the module being analyzed. These shift points may form the boundaries for shift regions inside that module in the old image of firmware. At this point in the process, the existing shift region list entries for each module that was identified as changing size may be deleted, and the preprocessor may insert the appropriate entries for the newly identified shift regions into the shift region list. Proceeding from the beginning of the shift region list, contiguous shift regions having the same adjustment values may be identified. Such entries may be consolidated into one shift region. The module map may then be discarded. This process produces a region shift list, which may be sent with a standard update package. A shift region list produced in this manner may be utilized by the partial predictive mapping preprocessor of the update agent to modify the old image of firmware to look more like the new image of firmware. An update algorithm may then be applied to the old image to produce the new image.
A shift region list may be encoded in one of several ways. In one embodiment, a shift region list may be encoded utilizing a shift region matrix as illustrated by an example in the following table:
Since this is a preprocessor, the shift region length is the length of the shift region in the old image of the firmware. In reference to
In one embodiment, the partial predictive mapping algorithm does not simply adjust branch links within a shift region by the adjustment amount stored in the shift region matrix, since that may be incorrect for “external” branch links referencing regions outside that particular shift region. In the example of the shift region matrix shown above, and
Several methods may be used to ensure branch links are adjusted correctly to accommodate any “external” branch links. In one embodiment, the pseudo-code shown below may be used. In this embodiment, it may be assumed that the preprocessor is familiar with CPU-specific op code and parameter format for branch link and other instructions that use absolute or offset addressing parameters.
Set pointer to address zero in old firmware image
Let BeginPoint = 0
For each shift region
Next shift region
While the present invention has been described with reference to certain embodiments, it will be understood by those skilled in the art that various changes may be made and equivalents may be substituted without departing from the scope of the present invention. In addition, many modifications may be made to adapt a particular situation or material to the teachings of the present invention without departing from its scope. Therefore, it is intended that the present invention not be limited to the particular embodiment disclosed, but that the present invention will include all embodiments falling within the scope of the appended claims.
This patent application makes reference to, claims priority to and claims benefit from U.S. Provisional Patent Application Ser. No. 60/405,253, entitled “Firmware Update Network And Process Employing Preprocessing Techniques,” filed on Aug. 22, 2002, U.S. Provisional Patent Application Ser. No. 60/415,620, entitled “System for Generating Efficient And Compact Update Packages,” filed on Oct. 2, 2002, U.S. Provisional Patent Application Ser. No. 60/441,867, entitled “Mobile Handset Update Package Generator That Employs Nodes Technique,” filed on Jan. 22, 2003, and U.S. Provisional Patent Application Ser. No. 60/447,977, entitled “Update Package Generator Employing Partial Predictive Mapping Techniques For Generating Update Packages For Mobile Handsets,” filed on Feb. 18, 2003. The complete subject matter of each of the above-referenced United States Patent Applications is hereby incorporated herein by reference, in its entirety. In addition, this application makes reference to U.S. Provisional Patent Application Ser. No. 60/249,606, entitled “System and Method for Updating and Distributing Information,” filed Nov. 17, 2000, and International Patent Application Publication No. WO 02/41147 A1, entitled “Systems And Methods For Updating And Distributing Information,” publication date Mar. 23, 2002, the complete subject matter of each of which is hereby incorporated herein by reference, in its entirety. This application is also related to the following co-pending applications, the complete subject matter of each of which is hereby incorporated herein by reference in its entirety: Ser.No.Docket No.TitleFiledInventors14121US02Firmware Update NetworkAug. 21,Chenand Process Employing2003GustafsonPreprocessing Techniques14122US02System for GeneratingAug. 21,ChenEfficient and Compact2003GustafsonUpdate PackagesBarber14312US02Mobile Handset UpdateAug. 21,ChenPackage Generator That2003Employs Nodes Technique The Applicant hereby identifies the following patent applications pursuant to 37 C.F.R. §1.78(f)(1): U.S. patent application Ser. No. 10/631,567 filed Jul. 31, 2003; U.S. patent application Ser. No. 10/654,412 filed Sep. 3, 2003; U.S. patent application Ser. No. 10/681,861 filed Oct. 8, 2003; U.S. patent application Ser. No. 10/689,309 filed Oct. 20, 2003, which issued as U.S. Pat. No. 6,978,453 on Dec. 20, 2005; U.S. patent application Ser. No. 11/251,046 filed Oct. 14, 2005; PCT Application No. PCT/US03/33241 filed Oct. 20, 2003; and U.S. patent application Ser. No. 10/788,768 filed on Feb. 27, 2004.
| Number | Name | Date | Kind |
|---|---|---|---|
| 5084816 | Boese et al. | Jan 1992 | A |
| 5261055 | Moran et al. | Nov 1993 | A |
| 5442771 | Filepp et al. | Aug 1995 | A |
| 5479637 | Lisimaque et al. | Dec 1995 | A |
| 5579522 | Christeson et al. | Nov 1996 | A |
| 5596738 | Pope | Jan 1997 | A |
| 5598534 | Haas | Jan 1997 | A |
| 5608910 | Shimakura | Mar 1997 | A |
| 5623604 | Russell et al. | Apr 1997 | A |
| 5666293 | Metz et al. | Sep 1997 | A |
| 5752039 | Tanimura | May 1998 | A |
| 5778440 | Yiu et al. | Jul 1998 | A |
| 5790974 | Tognazzini | Aug 1998 | A |
| 5878256 | Bealkowski et al. | Mar 1999 | A |
| 5960445 | Tamori et al. | Sep 1999 | A |
| 5968182 | Chen et al. | Oct 1999 | A |
| 6009497 | Wells et al. | Dec 1999 | A |
| 6018747 | Burns et al. | Jan 2000 | A |
| 6038636 | Brown, III et al. | Mar 2000 | A |
| 6064814 | Capriles et al. | May 2000 | A |
| 6073206 | Piwonka et al. | Jun 2000 | A |
| 6073214 | Fawcett | Jun 2000 | A |
| 6088759 | Hasbun et al. | Jul 2000 | A |
| 6105063 | Hayes, Jr. | Aug 2000 | A |
| 6112024 | Almond et al. | Aug 2000 | A |
| 6112197 | Chatterjee et al. | Aug 2000 | A |
| 6126327 | Bi et al. | Oct 2000 | A |
| 6128695 | Estakhri et al. | Oct 2000 | A |
| 6138249 | Nolet | Oct 2000 | A |
| 6157559 | Yoo | Dec 2000 | A |
| 6163274 | Lindgren | Dec 2000 | A |
| 6198946 | Shin et al. | Mar 2001 | B1 |
| 6209127 | Mori et al. | Mar 2001 | B1 |
| 6279153 | Bi et al. | Aug 2001 | B1 |
| 6301710 | Fujiwara | Oct 2001 | B1 |
| 6311322 | Ikeda et al. | Oct 2001 | B1 |
| 6343379 | Ozawa et al. | Jan 2002 | B1 |
| 6381740 | Miller et al. | Apr 2002 | B1 |
| 6408434 | Fujiwara | Jun 2002 | B1 |
| 6438585 | Mousseau et al. | Aug 2002 | B2 |
| 6526574 | Jones | Feb 2003 | B1 |
| 6615038 | Moles et al. | Sep 2003 | B1 |
| 6615404 | Garfunkel et al. | Sep 2003 | B1 |
| 6668336 | Lasser | Dec 2003 | B2 |
| 6725056 | Moles et al. | Apr 2004 | B1 |
| 6725392 | Frey et al. | Apr 2004 | B1 |
| 6832373 | O'Neill | Dec 2004 | B2 |
| 6836657 | Ji et al. | Dec 2004 | B2 |
| 6915452 | Froehlich et al. | Jul 2005 | B2 |
| 6925467 | Gu et al. | Aug 2005 | B2 |
| 6928108 | Nelson et al. | Aug 2005 | B2 |
| 20010029178 | Criss et al. | Oct 2001 | A1 |
| 20010047363 | Peng | Nov 2001 | A1 |
| 20010048728 | Peng | Dec 2001 | A1 |
| 20020072359 | Moles et al. | Jun 2002 | A1 |
| 20020078209 | Peng | Jun 2002 | A1 |
| 20020116261 | Moskowitz et al. | Aug 2002 | A1 |
| 20020131404 | Mehta et al. | Sep 2002 | A1 |
| 20020152005 | Bagnordi | Oct 2002 | A1 |
| 20020156863 | Peng | Oct 2002 | A1 |
| 20020157090 | Anton, Jr. | Oct 2002 | A1 |
| 20030023964 | Rajaram et al. | Jan 2003 | A1 |
| 20030027563 | Herle et al. | Feb 2003 | A1 |
| 20030033599 | Rajaram et al. | Feb 2003 | A1 |
| 20030037075 | Hannigan et al. | Feb 2003 | A1 |
| 20030061384 | Nakatani | Mar 2003 | A1 |
| 20030074658 | Kim | Apr 2003 | A1 |
| 20030084435 | Messer et al. | May 2003 | A1 |
| 20030121032 | Cho et al. | Jun 2003 | A1 |
| 20030162533 | Moles et al. | Aug 2003 | A1 |
| 20030163508 | Goodman | Aug 2003 | A1 |
| 20030186689 | Herle et al. | Oct 2003 | A1 |
| 20040015952 | Lajoie et al. | Jan 2004 | A1 |
| 20040031031 | Rudelic | Feb 2004 | A1 |
| 20040034853 | Gibbons et al. | Feb 2004 | A1 |
| 20040054995 | Lee | Mar 2004 | A1 |
| 20040111723 | Moles et al. | Jun 2004 | A1 |
| 20040117785 | Kincaid | Jun 2004 | A1 |
| 20040133887 | Herle et al. | Jul 2004 | A1 |
| 20040152455 | Herle | Aug 2004 | A1 |
| 20040261072 | Herle | Dec 2004 | A1 |
| 20040261073 | Herle et al. | Dec 2004 | A1 |
| 20050060699 | Kim et al. | Mar 2005 | A1 |
| 20050097544 | Kim | May 2005 | A1 |
| 20050144609 | Rothman et al. | Jun 2005 | A1 |
| 20050144612 | Wang et al. | Jun 2005 | A1 |
| 20050160195 | Bruner et al. | Jul 2005 | A1 |
| 20050216902 | Schafer | Sep 2005 | A1 |
| 20050216903 | Schafer | Sep 2005 | A1 |
| Number | Date | Country |
|---|---|---|
| 2339923 | Mar 2000 | CA |
| 8202626 | Aug 1996 | JP |
| 2001-0100328 | Nov 2001 | KR |
| 2002-0034228 | May 2002 | KR |
| Number | Date | Country | |
|---|---|---|---|
| 60405253 | Aug 2002 | US | |
| 60415620 | Oct 2002 | US | |
| 60441867 | Jan 2003 | US | |
| 60447977 | Feb 2003 | US |