[Not Applicable]
[Not Applicable]
Electronic devices, such as mobile phones and personal digital assistants (PDA's), often contain firmware and application software that are either provided by the manufacturers of the electronic devices, by telecommunication carriers, or by third parties. Electronic devices, such as high-end mobile phones, often contain a flash memory card, sometimes called an MMC card. The electronic devices may contain a flash memory card reader that is employed to read information on the flash memory cards that are inserted by end users.
Quite often, flash memory cards are used to store content such as digital photographs or audio files by the end user.
If firmware or firmware components are to be changed, it is often very tricky to update the firmware components in an electronic device. The electronic device must have sufficient memory available to download an update package and to execute an update process. Changes to firmware or firmware components of the electronic device must be performed in a fault tolerant mode and fault tolerant code are not easy to implement.
Typically, attempts to upgrade firmware and/or software in electronic devices, such as GSM mobile phones, are often hampered by the long update times required to update flash in a fault tolerant mode. Typically two writes per block of updated code is necessary. In addition, various types of flash exist such as, for example, NAND and NOR flash memory. Addressing firmware updates across various types of flash memory devices is a big challenge and is currently not easily solved. In addition, some electronic devices may not have sufficient memory to store a large update package or to conduct updates. Some devices with an update agent are not capable of updating in a fault tolerant mode.
Further limitations and disadvantages of conventional and traditional approaches will become apparent to one of skill in the art, through comparison of such systems with some aspects of the present invention as set forth in the remainder of the present application with reference to the drawings.
A method and/or device supporting firmware and/or software update using an update agent in a mobile electronic device, substantially as shown in and/or described in connection with at least one of the figures, as set forth more completely in the claims.
These and other advantages, aspects and novel features of the present invention, as well as details of an illustrated embodiment thereof, will be more fully understood from the following description and drawings.
Aspects of the present invention relate generally to the process of conducting device management tasks, such as updating software/firmware in electronic devices, and more specifically, to the use of a memory management unit (MMU) in an electronic device to conduct efficient fault tolerant firmware updates in the electronic device. The following discussion makes reference to the term “electronic device” that is used herein to refer to mobile electronic devices such as, for example, a mobile handset, a cellular phone, a personal digital assistant (PDA), a pager, and a personal computer, to name just a few. Although the listed example electronic devices are mobile devices, application of the present invention is not limited in this manner, as representative embodiments of the present invention may be employed in a wide variety of electronic devices, both fixed and mobile.
Electronic devices may be adapted to access servers to retrieve update information for updating memory in the electronic devices. An electronic device may be, for example, a mobile electronic device having firmware/software such as mobile cellular phone handsets, personal digital assistants (PDAs), pagers, MP-3 players, digital cameras, to name just a few. Update information may comprise information that modifies or changes firmware/software and/or software components installed in the electronic device. In a representative embodiment of the present invention, update information may comprise a set of executable instructions for converting a first version of code to an updated/second version of code. The update information may add new services to the electronic device, as desired by a service provider, device manufacturer, or an end-user, and/or may fix bugs (e.g., errors) in the operating code of the electronic device. In a representative embodiment of the present invention, update information may comprise an update package.
Typical fault tolerant updates require two flash memory writes and two flash memory erases per block of flash memory being updated. A representative embodiment of the present invention makes it possible to update the same blocks of flash memory employing only one flash erase and one flash write, thereby reducing the update time considerably.
A representative embodiment of the present invention may be employed not only with mobile devices such as those discussed above, but also with other types of electronic devices that comprise non-volatile memory with resident software that is updateable by an update agent in the electronic device.
As shown in the illustration of
In a representative embodiment of the present invention, a memory management unit (MMU) that is employed by some central processing units (CPUs) in electronic devices such as, for example, mobile handsets, may also be employed in the update of firmware and/or software that resides in non-volatile memory of the electronic devices. An MMU such as, for example, the MMU 124 may be used in an efficient way, to reduce update time to the time needed for one write per block, while also conducting the update in a fault-tolerant mode.
Existing fault tolerant updates may require two flash memory writes and two flash memory erases per block of flash memory to be updated. A representative embodiment of the present invention is able to perform the same update of memory using only one flash memory erase and one flash memory write per block of flash memory to be updated, thereby reducing the update time considerably.
In previous update approaches that were not based on the use of an MMU, every block (in some order) was shifted to a next block location during pre-processing, and shifted again to its previous block location during an update phase. This approach to update of memory is inefficient in that it involves two flash memory writes and two flash memory erases per block of memory that is updated.
It is a function of an MMU to translate logical or virtual memory references used by a controller/processor (e.g., a CPU) into physical memory addresses. Thus, an MMU may facilitate mapping between a user memory space used by a program to a physical memory address managed by an operating system or firmware. Thus, an MMU may be responsible for virtual or logical to physical address mapping. The MMU may be located between the controller/processor (e.g., a CPU) and a cache that operates on physical addresses. In one representative embodiment of the present invention, an MMU may, for example, employ page tables that are managed by a master MMU table. In another representative embodiment of the present invention, the MMU may, for example, employ inverted page tables.
In a representative embodiment of the present invention, an MMU table such as, for example, the MMU table 127 of
A representative embodiment of the present invention achieves improved update performance by employing a memory management unit (MMU) such as the MMU 124 of
In a representative embodiment of the present invention, a generator such as the generator 111 of
Employment of a representative embodiment of the present invention results in a dramatic update time improvement for MMU environments. A representative embodiment of the present invention may realize a 50 percent reduction in update time. Prior fault tolerant update approaches may take two memory writes per block of memory to be updated, which is not as efficient as the methods described above with respect to a representative embodiment of the present invention. Use of an MMU mechanism as described above reduces the number of memory writes to one memory write per block of memory updated, and maintains fault tolerance. In some representative embodiments of the present invention, a hardware MMU may not be employed. For example, for NAND flash based devices, the MMU may not be used, and a loader that loads code from NAND flash memory into RAM may be employed to achieve the same results and efficiencies.
In a representative embodiment of the present invention, during an update of memory in an electronic device such as, for example, the mobile device 109 of
In a representative embodiment of the present invention, an update agent such as the update agent 129 of
In one representative embodiment of the present invention, the logical to physical memory mapping represented in an MMU table such as the MMU table 127 of
In another representative embodiment of the present invention, an operating system (OS) such as the OS 133 may not employ an MMU that comes with a controller/CPU, and may not use an MMU table such as the MMU table 127. In such a representative embodiment of the present invention, non-volatile memory such as the non-volatile memory 123 may be a NOR-type flash memory. MMU table entries in an MMU table such as the MMU table 127 may be employed by an MMU like MMU 124, after the update process, in the computation of physical addresses from logical addresses, for example.
In one representative embodiment of the present invention, a generator such as the generator 111 may, for example, create update information (e.g., an update package) and may place within the update package MMU table information that an update agent such as the update agent 129 may employ.
In another representative embodiment of the present invention, a generator such as the generator 111 may create an update information (e.g., an update package), and may embed MMU table information into the new memory image to be updated by the update information (e.g., an update package). In such an arrangement, an update agent such as the update agent 129, for example, may be oblivious to the fact that part of the memory image being updated is MMU information, an MMU table, or a portion thereof.
In a representative embodiment of the present invention, a generator such as the generator 111 of
In a representative embodiment of the present invention, an update agent such as, for example, the update agent 129 of
In a representative embodiment of the present invention, a boot loader such as, for example, the boot loader 127 of
In a representative embodiment of the present invention, a loader such as the loader 241 of
In a representative embodiment of the present invention, the update process may use a free block as the first block to be written with updated content. Thus, the initial block layout 307 for the memory image may include a free block 319 that is used during update 343 to create an updated block D 329 in updated block layout 309, from an original block d 317. Similarly, after updated block D 329 is created, the free block 319 may move to occupy original block 317, into which an original block c 315 may be updated and saved as the updated block C 327, and so on. Thus, starting with the initial block layout 307, an update agent such as, for example, the update agent 229 of
Thus, a representative embodiment of the present invention may employ an MMU in an electronic device (e.g., sometimes provided as part of a chipset) and MMU information provided by a generator along with update information (e.g., an update package), such that an initial block layout 307 is modified or changed by the MMU after an update process to achieve a view that it is effectively experienced as the memory block layout 341.
In the illustration of
In a representative embodiment of the present invention, the update 343 shown in the illustration of
Aspects of the present invention as shown in
In such a representative embodiment of the present invention, a hardware MMU may not be employed. A generator such as the generator 111 of
By employing a representative embodiment of the present invention, update information (e.g., an update package) usable by an electronic device to achieve the updated block layout 409, starting with the initial memory image block layout 407 may thus be created by a generator such as the generator 111 of
In a representative embodiment of the present invention, a stealth engine tool used by a generator such as the generator 111 of
Next, the electronic device may update the first version of code to the second version of code, in the electronic device, using the update information (block 614). The update may be performed by update agent code such as the update agent 129 shown in the non-volatile memory 123 of
Following completion of the update, the electronic device may modify a memory management unit (MMU) table in the electronic device in order to reduce a number of writes to memory during the updating, using the memory management information (block 616). The memory management unit (MMU) may, for example, map logical memory references to corresponding physical memory addresses in the non-volatile memory of the mobile electronic device, in order to arrange the updated memory to be consistent with the second code version. The electronic device may then be rebooted (block 618).
Aspects of the present invention may be found in a generator capable of generating an update package for a mobile electronic device by processing a first binary code version and a second binary code version. Such a generator may comprise a server comprising machine-readable storage, and predictor software resident in the machine-readable storage. The predictor software may be executable to cause the server to perform on-the-fly prediction of at least one shift of code components in the second binary code version with respect to the first binary code version. The predictor software may generate code shift information, and the generator may produce difference information based on the first binary code version, the second binary code version, and the code shift information. The generator may produce memory mapping information for use during an update of the first binary code version to the second binary code version, in the mobile electronic device. The memory mapping information may comprise a mapping between physical memory addresses and logical memory references associated with code components in the second binary code version. The generator may package the difference information and the memory mapping information into an update package for use by the mobile electronic device in updating the first binary code version to the second binary code version.
In a representative embodiment of the present invention, the update package may comprise a set of executable instructions for converting the first binary code version to the second binary code version. A representative embodiment of the present invention may also comprise analysis software executable by the server for automatically acquiring first build information for the first binary code version and second build information for the second binary code version. The analysis software may process the first build information and the second build information to gather delta information for changes in code between the first binary code version and the second binary code version, and may optimize the size of an update package based upon on the delta information.
Other aspects of the present invention may be seen in a mobile electronic device having a memory management unit (MMU). The mobile electronic device may be capable of updating at least one of the following: firmware and software in memory of the mobile electronic device, using resident update agent code. The mobile electronic device may comprise a controller capable of accessing machine-readable storage containing the update agent code, and update information comprising memory mapping information. The update agent code may update a first code version to a second code version, using the update information, and may provide memory mapping information to a memory management unit (MMU) following an updating activity. In addition, the memory management unit (MMU) may employ the memory management information to conduct normal operation of the mobile electronic device.
The memory mapping information may comprise a mapping of logical memory references to corresponding physical memory addresses in non-volatile memory of the mobile electronic device, for a plurality of code components. The memory mapping information may map logical memory references to corresponding physical memory addresses for only those of the plurality of code components having different physical memory addresses in the first code version and the second code version. The memory mapping information may comprise a memory management unit (MMU) update table that maps the logical memory references to corresponding physical memory addresses for only those of the plurality of firmware components having different physical memory addresses in the first code version and the second code version. The update agent may incorporate the memory management unit (MMU) update table into an updatable master memory management unit (MMU) table associated with the memory management unit (MMU) in the mobile electronic device.
In a representative embodiment of the present invention, the mobile electronic device may also comprise a master memory management unit (MMU) table used and maintained by the mobile electronic device. The memory mapping information provided by the update agent to the memory management unit (MMU) may comprise a replacement memory management unit (MMU) table that in turn comprises a mapping of logical memory references to corresponding physical memory addresses for a plurality of code components. The update agent code may replace the master memory management unit (MMU) table with the replacement memory management unit (MMU) table after updating, using the update information. The update agent code may replace at least a portion of the master memory management unit (MMU) table with the replacement memory management unit (MMU) table after updating, using the update information. The update information may comprise an update package.
Additional aspects of the present invention may be observed in a method of upgrading an electronic device comprising update agent code. Such a method may comprise receiving update information for updating a first code version to a second code version in the electronic device. The update information may comprise memory management information. A representative embodiment of the present invention may also comprise updating the first code version to the second code version, in the electronic device. In addition, the method may comprise modifying a memory management unit (MMU) table in the electronic device in order to reduce a number of writes to memory during the updating, using the memory management information, and rebooting the electronic device. Other representative embodiments of the present invention may comprise generating update information based upon the first code version and the second code version, and communicating the update information to the electronic device.
Memory management information in a representative embodiment in accordance with the present invention may comprise a mapping of logical memory references to corresponding physical memory addresses. Update information may comprise a set of executable instructions for converting the first code version to the second code version, and update information may comprise an update package. Memory management information may comprise replacement information for at least a portion of the contents of the memory management unit (MMU) table. Updating the first code version to the second code version may comprise a single pass update, and the single pass update may comprise a single write operation per updated memory location.
Accordingly, the present invention may be realized in hardware, software, or a combination of hardware and software. The present invention may be realized in a centralized fashion in at least one computer system, or in a distributed fashion where different elements are spread across several interconnected computer systems. Any kind of computer system or other apparatus adapted for carrying out the methods described herein is suited. A typical combination of hardware and software may be a general-purpose computer system with a computer program that, when being loaded and executed, controls the computer system such that it carries out the methods described herein.
The present invention may also be embedded in a computer program product, which comprises all the features enabling the implementation of the methods described herein, and which when loaded in a computer system is able to carry out these methods. Computer program in the present context means any expression, in any language, code or notation, of a set of instructions intended to cause a system having an information processing capability to perform a particular function either directly or after either or both of the following: a) conversion to another language, code or notation; b) reproduction in a different material form.
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.
The present application makes reference to, claims priority to, and claims benefit of U.S. Provisional Patent Application Ser. No. 60/577,347, entitled “MOBILE DEVICE WITH A MMU FOR FASTER FIRMWARE UPDATES IN A WIRELESS NETWORK”, filed Jun. 3, 2004, the complete subject matter of which is hereby incorporated herein by reference, in its entirety. The present application makes reference to PCT Application having publication number WO/02/41147 A1 and PCT Application No. PCT/US01/44034, entitled “System and Method for Updating and Distributing Information”, filed Nov. 19, 2001, the complete subject matter of which is hereby incorporated herein by reference, in its entirety. The present application also 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, the complete subject matter of which is hereby incorporated herein by reference, in its entirety.
Number | Name | Date | Kind |
---|---|---|---|
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 |
5802554 | Caceres et al. | Sep 1998 | A |
5878256 | Bealkowski et al. | Mar 1999 | A |
5960445 | Tamori et al. | Sep 1999 | A |
6009497 | Wells et al. | Dec 1999 | 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 |
6157559 | Yoo | Dec 2000 | A |
6163274 | Lindgren | Dec 2000 | A |
6198946 | Shin et al. | Mar 2001 | B1 |
6279153 | Bi et al. | Aug 2001 | B1 |
6311322 | Ikeda et al. | Oct 2001 | B1 |
6438585 | Mousseau et al. | Aug 2002 | B2 |
7096311 | Chiang | Aug 2006 | B2 |
7149508 | Herle | Dec 2006 | B2 |
20010029178 | Criss et al. | Oct 2001 | A1 |
20010047363 | Peng | Nov 2001 | A1 |
20010048728 | Peng | Dec 2001 | 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 |
20030033599 | Rajaram et al. | Feb 2003 | A1 |
20030037075 | Hannigan et al. | Feb 2003 | A1 |
20030061384 | Nakatani | Mar 2003 | A1 |
20030182414 | O'Neill | Sep 2003 | A1 |
20040107416 | Buban et al. | Jun 2004 | A1 |
20040133887 | Herle et al. | Jul 2004 | A1 |
Number | Date | Country |
---|---|---|
2339923 | Mar 2000 | CA |
8202626 | Aug 1996 | JP |
2002-0034228 | May 2000 | KR |
2001-0100328 | Nov 2001 | KR |
WO 0241147 | May 2002 | WO |
Number | Date | Country | |
---|---|---|---|
60577347 | Jun 2004 | US |