CN114691180A - Software upgrading method and device for processor chip, processor and processor system - Google Patents

Software upgrading method and device for processor chip, processor and processor system Download PDF

Info

Publication number
CN114691180A
CN114691180A CN202210296327.2A CN202210296327A CN114691180A CN 114691180 A CN114691180 A CN 114691180A CN 202210296327 A CN202210296327 A CN 202210296327A CN 114691180 A CN114691180 A CN 114691180A
Authority
CN
China
Prior art keywords
type system
upgrading
type
software package
target
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.)
Pending
Application number
CN202210296327.2A
Other languages
Chinese (zh)
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.)
Luoyang Heat Sense Technology Co ltd
Original Assignee
Luoyang Heat Sense Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Luoyang Heat Sense Technology Co ltd filed Critical Luoyang Heat Sense Technology Co ltd
Priority to CN202210296327.2A priority Critical patent/CN114691180A/en
Publication of CN114691180A publication Critical patent/CN114691180A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • G06F8/654Updates using techniques specially adapted for alterable solid state memories, e.g. for EEPROM or flash memories

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The application provides a software upgrading method and device for a processor chip, a processor and a processor system. Transferring the upgrading software package to a storage space of a second type system; upgrading the second type system by adopting an upgrading software package; and if the power failure occurs in the process of upgrading the second type system, under the condition that the second type system needs to be upgraded again, the first type system is controlled again to transfer the upgrading software package to the storage space of the second type system. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the processor chip is powered on again.

Description

Software upgrading method and device for processor chip, processor and processor system
Technical Field
The present application relates to the field of processor chips, and in particular, to a method and an apparatus for upgrading software of a processor chip, a computer-readable storage medium, a processor, and a processor system.
Background
In the operation stage after the product is released, the software program of the processor chip is often required to be upgraded, and the software program of the processor chip is often upgraded by adopting a remote upgrading method, however, if the power failure occurs in the upgrading process, only a part of the program is upgraded, the original stored program is also damaged, and if the power is re-electrified, the program still cannot be restarted, and the program cannot be upgraded again.
Disclosure of Invention
The present application mainly aims to provide a method and an apparatus for upgrading software of a processor chip, a computer-readable storage medium, a processor, and a processor system, so as to solve the problem that in the prior art, upgrading cannot be completed when power is cut off during a process of remotely upgrading a software program of a processor chip.
According to an aspect of an embodiment of the present invention, there is provided a software upgrade method of a processor chip including a first type system and a second type system, including: acquiring an upgrading software package, controlling the first type system to transfer the upgrading software package to a storage space of the second type system, and under the condition that the processor chip is powered off, not changing data in the first type system; upgrading the second type system by adopting the upgrading software package; and if the situation of power failure occurs in the process of upgrading the second type system, determining whether the second type system needs to be upgraded again, and under the situation that the second type system needs to be upgraded again, controlling the first type system again to transfer the upgrading software package to the storage space of the second type system.
Optionally, before upgrading the second type system using the upgrade software package, the method further includes: and acquiring the system version number of each second type system.
Optionally, there are a plurality of second-type systems, and upgrading the second-type system by using the upgrade software package includes: determining the second type system with the lowest system version number as a target second type system; and transferring the upgrading software package from the first type system to the target second type system, and upgrading the target second type system.
Optionally, after the second type system is upgraded by using the upgrade software package, the method further includes: and determining the second type system which is actually operated according to whether the target second type system is upgraded to the highest version successfully or not.
Optionally, determining the second type system that is actually operated according to whether the target second type system is successfully upgraded to the highest version, includes: running the target second-type system if the target second-type system has been successfully upgraded to the highest version; running a highest version of the second-type system of the plurality of second-type systems without successfully upgrading the target second-type system to the highest version.
Optionally, before obtaining the upgrade software package and controlling the first type system to dump the upgrade software package into the storage space of the second type system, the method further includes: sending determination information to a target system, wherein the target system generates feedback information based on the determination information, the determination information is used for determining the type of the target system, and the feedback information is used for identifying the type of the target system; and determining whether the target system is the first type system or not according to the feedback information.
Optionally, the processor chip includes a first storage area and a second storage area, the first storage area is used for storing the first type system, the second storage area is used for storing the second type system, a start address of the first storage area is 0, and a start address of the second storage area is greater than an end address of the first storage area.
According to another aspect of the embodiments of the present invention, there is also provided a software upgrading apparatus for a processor chip, the processor chip including a first type system and a second type system, including: the first acquisition unit is used for acquiring an upgrading software package and controlling the first type system to transfer the upgrading software package to the storage space of the second type system, and under the condition that the processor chip is powered off, data in the first type system are not changed; the upgrading unit is used for upgrading the second type system by adopting the upgrading software package; the first determining unit is used for determining whether the second type system needs to be upgraded again if power failure occurs in the process of upgrading the second type system, and controlling the first type system to transfer the upgrading software package to the storage space of the second type system again under the condition that the second type system needs to be upgraded again.
According to still another aspect of embodiments of the present invention, there is also provided a computer-readable storage medium including a stored program, wherein the program executes any one of the methods.
According to still another aspect of the embodiments of the present invention, there is further provided a processor, configured to execute a program, where the program executes any one of the methods.
According to another aspect of the embodiments of the present invention, there is also provided a processor system, including a processor chip and a control unit, the control unit being configured to perform any one of the methods.
In the embodiment of the present invention, an upgrade software package is first obtained, the first type system is controlled to transfer the upgrade software package to a storage space of the second type system, data in the first type system is not changed when the processor chip is powered off, then the second type system is upgraded by using the upgrade software package, and finally, if the power off occurs during upgrading the second type system, it is determined whether the second type system needs to be upgraded again, and when the second type system needs to be upgraded again, the first type system is controlled to transfer the upgrade software package to the storage space of the second type system again. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the power is turned on again.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this application, are included to provide a further understanding of the application, and the description of the exemplary embodiments and illustrations of the application are intended to explain the application and are not intended to limit the application. In the drawings:
FIG. 1 shows a schematic diagram of a power-up configuration process for a processor chip;
FIG. 2 shows a schematic diagram of the principle of using a simulator cure program;
FIG. 3 shows a schematic diagram of another scheme for remote upgrade;
FIG. 4 shows a schematic diagram of yet another scheme for remote upgrade;
FIG. 5 shows a flow diagram of a method for software upgrade of a processor chip according to an embodiment of the present application;
FIG. 6 is a schematic diagram showing a normal boot process after a processor chip is powered on;
FIG. 7 is a schematic diagram showing a process for processor chip upgrade;
FIG. 8 is a schematic diagram showing another process of processor chip upgrade;
FIG. 9 is a schematic diagram illustrating a software upgrade of yet another processor chip;
FIG. 10 shows a schematic diagram of a storage in a processor chip;
fig. 11 is a schematic structural diagram of a software upgrading apparatus of a processor chip according to an embodiment of the present application.
Detailed Description
It should be noted that, in the present application, the embodiments and features of the embodiments may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only partial embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used may be interchanged under appropriate circumstances such that embodiments of the application described herein may be used. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
It will be understood that when an element such as a layer, film, region, or substrate is referred to as being "on" another element, it can be directly on the other element or intervening elements may also be present. Also, in the specification and claims, when an element is described as being "connected" to another element, the element may be "directly connected" to the other element or "connected" to the other element through a third element.
For the field of chips, such as FPGA chips, most of the FPGA chips are based on an SRAM (Static Random-Access memory) structure, and data in the SRAM is lost when power is off, so after the FPGA is powered on, configuration data must be loaded into the SRAM of the FPGA by an external configuration circuit, the FPGA can normally operate, and the configuration chips are generally Flash chips, that is, the configuration data operating in the FPGA is stored in the Flash chips. As shown in fig. 1, an external circuit includes a configuration device, which forms an external configuration circuit, the external configuration circuit loads configuration data into an SRAM of the FPGA, the configuration data in the SRAM is configured to control an internal programmable logic, an internal register, and an input/output register of the FPGA to initialize, drive enable the input/output register, and the like, of the FPGA, and then the FPGA enters a user mode.
Fig. 2 shows a principle of adopting a simulator to solidify a program, after compiling is completed by using a compiler, logic data for downloading may be generated, the logic data may be directly downloaded to an internal SRAM of an FPGA by using the simulator for online operation (data in the SRAM is lost when power is down), the logic data may also be solidified in a hardware circuit (data in the hardware circuit is not lost when power is down), and when the logic data needs to be solidified in the hardware circuit, the logic data needs to be loaded into a Flash chip. When the simulator is used for solidifying logic data, the simulator downloads a section of logic data (data for receiving the simulator and reading and writing a Flash chip) containing an upgrading module into an SRAM (static random access memory) of an FPGA (field programmable gate array), and then the logic data can be indirectly written into the Flash chip through the section of logic data simulator, and the remote online upgrading realized in the practical application process cannot be necessarily upgraded by using the simulator, so that the upgraded logic data can be written into the Flash chip by using a serial port, an Ethernet port or other communication interfaces with reference to the process of solidifying the logic data by the simulator.
Referring to the principle in fig. 2, an upgrade module may also be added in the FPGA to receive upgraded data, and then write the upgraded data into the Flash chip, as shown in fig. 3, the principle in fig. 2 is used in fig. 3 to improve the method in fig. 1, an external device sends an upgrade software package to the FPGA, and then the FPGA sends the upgrade software package to the Flash chip, however, the method of remote upgrade of the FPGA in fig. 3 has a large defect, if a power failure occurs during the upgrade process, the program is only upgraded partially, the original stored program is also damaged, and if the power is re-turned on, the program cannot be restarted, and the upgrade cannot be performed again.
In order to solve the above problems, as shown in fig. 4, it may also be tried to add an external memory (e.g., SRM or DDR (Double data Rate, Double-think synchronous dynamic random access memory)) to the FPGA on the hardware to temporarily store the upgraded data, and the like, when all the upgrade software packages are completely received and checked to be normal, and then write into the Flash chip.
As mentioned in the background, in order to solve the above problem, in the prior art, when a power failure occurs during a process of remotely upgrading a software program of a processor chip, the upgrading cannot be completed.
According to an embodiment of the present application, there is provided a software upgrade method of a processor chip including a first type system and a second type system.
FIG. 5 is a flow chart of a method for upgrading software of a processor chip according to an embodiment of the application. As shown in fig. 5, the method comprises the steps of:
step S101, obtaining an upgrade software package, controlling the first type system to transfer the upgrade software package to a storage space of the second type system, and under the condition that the processor chip is powered off, not changing data in the first type system;
step S102, upgrading the second type system by adopting the upgrading software package;
step S103, if the power failure occurs in the process of upgrading the second type system, determining whether the second type system needs to be upgraded again, and if the second type system needs to be upgraded again, controlling the first type system again to transfer the upgrade software package to the storage space of the second type system.
In the method, an upgrade software package is obtained first, the first type system is controlled to transfer the upgrade software package to a storage space of the second type system, data in the first type system is not changed under the condition that the processor chip is powered off, then the second type system is upgraded by the upgrade software package, and finally, if the power off condition occurs in the process of upgrading the second type system, whether the second type system needs to be upgraded again is determined, and the first type system is controlled again to transfer the upgrade software package to the storage space of the second type system under the condition that the second type system needs to be upgraded again. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the processor chip is powered on again.
Specifically, the software upgrading method provided by the application can simplify the upgrading process and facilitate operation, and then a user can operate the software upgrading method by himself to upgrade the software.
It should be noted that the steps illustrated in the flowcharts of the figures may be performed in a computer system such as a set of computer-executable instructions and that, although a logical order is illustrated in the flowcharts, in some cases, the steps illustrated or described may be performed in an order different than presented herein.
In one embodiment, the processor chip may be an FPGA chip, but is not limited to the FPGA chip, and any other feasible processor chip may be selected by one skilled in the art.
In a specific embodiment, a normal starting process after a processor chip is powered on is shown in fig. 6, a first type system and a second type system are both stored in a Flash chip, and in the power-on process, the first type system is loaded first, and then the second type system is loaded by the first type system.
In another specific embodiment, as shown in fig. 7, when the second type system receives an upgrade instruction, the first type system is loaded, the upgrade software package is obtained, a storage space corresponding to the second type system in the Flash chip is determined, the first type system is controlled to transfer the upgrade software package to the storage space of the second type system, the second type system is upgraded by using the upgrade software package, and if a power failure occurs during the process of upgrading the second type system and it is determined that the second type system needs to be upgraded again, the first type system receives the upgrade software package again and transfers the upgrade software package to the storage space of the second type system, so that the second type system can still be upgraded after being powered on again.
In an embodiment of the application, before the upgrading the second type system by using the upgrade software package, the method further includes: and acquiring the system version number of each second type system. In this embodiment, when there are a plurality of second-type systems, the system version number of each second-type system may be obtained, so that the second-type systems may be upgraded more efficiently in the following according to the system version number of each second-type system. The system version number is determined according to the release type and the release time of the system.
In another embodiment of the present application, there are a plurality of the second type systems, and the upgrading the second type system by using the upgrade software package includes: determining the second type system with the lowest system version number as a target second type system; and transferring the upgrading software package from the first type system to the target second type system, and upgrading the target second type system. In this embodiment, the second type system with the lowest system version number may be upgraded, so that only one second type system with the lowest system version may be upgraded at the same time, and other second type systems may also continue to operate, thereby further ensuring that the scheme has better reliability.
In one embodiment, there are 3 second type systems, which are respectively an a system, a B system, and a C system, the system version numbers are respectively 1.0, 2.0, and 3.0, the system version number of the upgrade software package is 4.0, the system version number with the lowest system version number is the a system, the a system is used as the target second type system, and the upgrade software package with the system version number of 4.0 is transferred from the first type system to the storage space of the a system, so as to upgrade the a system.
In another embodiment of the present application, after the upgrading the second type system by using the upgrade software package, the method further includes: and determining the second type system which is actually operated according to whether the target second type system is upgraded to the highest version successfully or not. In the embodiment, in the process of upgrading the second type system, if the power failure occurs, the upgrading of the second type system is not completed, or the power failure does not occur, the upgrading of the second type system is completed, so that the second type system which is actually operated can be determined more efficiently according to whether the target second type system is successfully upgraded to the highest version, and the effectiveness of the scheme is further ensured to be better.
In another embodiment of the present application, determining the second type system that is actually operating according to whether the target second type system is successfully upgraded to the highest version includes: running the target second type system if the target second type system has been successfully upgraded to the highest version; and running the highest version of the second-type system in the plurality of second-type systems under the condition that the target second-type system is not upgraded to the highest version successfully. In this embodiment, the target second-type system is operated when the target second-type system has been successfully upgraded to the highest version, that is, the version number of the system operated at this time is the highest; and under the condition that the target second-type system is successfully upgraded to the highest version, operating the second-type system with the highest version in the plurality of second-type systems, wherein the version of the operated system is not necessarily the highest, but the version of the operated system is the highest in the plurality of second-type systems, and the smooth operation of the system can also be ensured.
In one embodiment, there are 3 second type systems, which are an a system, a B system, and a C system, the system version numbers are 1.0, 2.0, and 3.0, respectively, the system version number of the upgrade software package is 4.0, the system version number with the lowest system version number is the a system, the a system is used as the target second type system, the upgrade software package with the system version number of 4.0 is transferred from the first type system to the storage space of the a system, the a system is upgraded, the a system is operated when the a system is successfully upgraded to the 4.0 version, and the C system is operated when the a system is not successfully upgraded to the 4.0 version.
In another specific embodiment, the processor chip includes a first type system, two second type systems, where the two second type systems are an a system and a B system, respectively, and the process of upgrading the processor chip is shown in fig. 8, when the second type system receives an upgrade instruction, the first type system is loaded, an upgrade software package is obtained, storage spaces corresponding to the a system and the B system in the Flash chip are determined, system version numbers of the a system and the B system are determined, the upgrade software package is transferred from the first type system to the storage space of the second type system with a lower version, and the second type system with a lower version is upgraded.
In a specific embodiment of the present application, before obtaining an upgrade software package and controlling the first type system to transfer the upgrade software package to the storage space of the second type system, the method further includes: sending determination information to a target system, wherein the target system generates feedback information based on the determination information, the determination information is used for determining the type of the target system, and the feedback information is used for identifying the type of the target system; and determining whether the target system is the first type system or not according to the feedback information. In this embodiment, the type of the target system may be determined first, and whether to acquire the upgrade software package may be determined according to the type of the target system, and for different types of system functions, the upgrade software package may be acquired only when the target system is the first type system, which may further ensure better processing capability of the processor chip.
In another embodiment, as shown in fig. 9, a software upgrading process of a processor chip includes, first, starting a program, then determining a type of a target system, determining whether the target system is a first type system, sending an upgrade start instruction if the target system is the first type system, transferring an upgrade software package in the first type system to a storage space of a second type system if the second type system is ready to receive an instruction of the upgrade software package, upgrading the second type system using the upgrade software package, sending an upgrade complete instruction, ending the upgrade, and sending an instruction to enter the first type system if the target system is not the first type system.
In yet another embodiment of the present application, the processor chip includes a first storage area and a second storage area, the first storage area is used for storing the first type system, the second storage area is used for storing the second type system, a start address of the first storage area is 0, and a start address of the second storage area is greater than an end address of the first storage area. In this embodiment, after the processor chip is powered on, the default is to load data from the address 0 first, so that the first type is stored in the first area, and the start address of the first area is 0, so that after the processor chip is powered on, the first type system is loaded first, and the spaces of the storage addresses of the first storage area and the second storage area cannot be overlapped, which can ensure that the function of the processor chip cannot be abnormal.
In one embodiment, the processor chip includes a first type system, two second type systems, the two second type systems are an a system and a B system, the storage manner is as shown in fig. 10, the processor chip includes a first storage area, a second storage area and a third storage area, the first storage area is used for storing the first type system, the second storage area is used for storing the a system, the third storage area is used for storing the B system, a start address of the first storage area is 0, a start address of the second storage area is greater than an end address of the first storage area, and a start address of the third storage area is greater than an end address of the second storage area.
In another embodiment, the first type system and the second type system can be combined into a download file for burning.
In yet another embodiment, the first type system may be a mobile phone system and the second type system may be an APP.
The embodiment of the present application further provides a software upgrading apparatus for a processor chip, where the processor chip includes a first type system and a second type system, and it should be noted that the software upgrading apparatus for a processor chip according to the embodiment of the present application may be used to execute the software upgrading method for a processor chip according to the embodiment of the present application. The following describes a software upgrading apparatus for a processor chip according to an embodiment of the present application.
Fig. 11 is a schematic diagram of a software upgrading apparatus of a processor chip according to an embodiment of the present application. As shown in fig. 11, the apparatus includes:
a first obtaining unit 10, configured to obtain an upgrade software package, and control the first type system to transfer the upgrade software package to a storage space of the second type system, where data in the first type system is not changed;
an upgrade unit 20, configured to upgrade the second type system by using the upgrade software package;
a first determining unit 30, configured to determine whether the second type system needs to be upgraded again if a power failure occurs during upgrading the second type system, and when the second type system needs to be upgraded again, control the first type system again to transfer the upgrade software package to a storage space of the second type system.
In the device, a first obtaining unit obtains an upgrade software package, and controls the first type system to transfer the upgrade software package to a storage space of the second type system, when the processor chip is powered off, data in the first type system is not changed, the upgrade unit upgrades the second type system by using the upgrade software package, if the power off occurs in the process of upgrading the second type system, a first determining unit determines whether the second type system needs to be upgraded again, and when the second type system needs to be upgraded again, the first type system is controlled again to transfer the upgrade software package to the storage space of the second type system. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the processor chip is powered on again.
In one embodiment, the processor chip may be an FPGA chip, but is not limited to the FPGA chip, and any other feasible processor chip may be selected by one skilled in the art.
In an embodiment of the application, the apparatus further includes a second obtaining unit, where the second obtaining unit is configured to obtain a system version number of each second-type system before the second-type system is upgraded by using the upgrade software package. In this embodiment, when there are a plurality of second type systems, the system version number of each second type system may be obtained, so that the second type systems may be upgraded more efficiently in the following process according to the system version number of each second type system. The system version number is determined according to the release type and the release time of the system.
In another embodiment of the present application, there are a plurality of the second-type systems, and the upgrade unit includes a determining module and an upgrade module, where the determining module is configured to determine that the second-type system with the lowest system version number is a target second-type system; the upgrading module is used for transferring the upgrading software package from the first type system to the target second type system and upgrading the target second type system. In this embodiment, the second type system with the lowest system version number may be upgraded, so that only one second type system with the lowest system version may be upgraded at the same time, and other second type systems may also continue to operate, thereby further ensuring that the scheme has better reliability.
In one embodiment, there are 3 second type systems, which are respectively an a system, a B system, and a C system, the system version numbers are respectively 1.0, 2.0, and 3.0, the system version number of the upgrade software package is 4.0, the system version number with the lowest system version number is the a system, the a system is used as the target second type system, and the upgrade software package with the system version number of 4.0 is transferred from the first type system to the storage space of the a system, so as to upgrade the a system.
In yet another embodiment of the present application, the apparatus further includes a second determining unit, where the second determining unit is configured to determine the second-type system that is actually operated according to whether the target second-type system is successfully upgraded to the highest version after the second-type system is upgraded by using the upgrade software package. In the embodiment, in the process of upgrading the second type system, if the power failure occurs, the upgrading of the second type system is not completed, or the power failure does not occur, the upgrading of the second type system is completed, so that the second type system which is actually operated can be determined more efficiently according to whether the target second type system is successfully upgraded to the highest version, and the effectiveness of the scheme is further ensured to be better.
In another embodiment of the present application, the second determining unit includes a first operating module and a second operating module, and the first operating module is configured to operate the target second type system when the target second type system has been successfully upgraded to the highest version; the second running module is used for running the second-type system with the highest version in the plurality of second-type systems under the condition that the target second-type system is not upgraded to the highest version successfully. In this embodiment, the target second type system is operated when the target second type system has been successfully upgraded to the highest version, that is, the version number of the system operated at this time is the highest; and under the condition that the target second-type system is successfully upgraded to the highest version, operating the second-type system with the highest version in the plurality of second-type systems, wherein the version of the operated system is not necessarily the highest, but the version of the operated system is the highest in the plurality of second-type systems, and the smooth operation of the system can also be ensured.
In one embodiment, there are 3 second type systems, which are an a system, a B system, and a C system, the system version numbers are 1.0, 2.0, and 3.0, respectively, the system version number of the upgrade software package is 4.0, the system version number with the lowest system version number is the a system, the a system is used as the target second type system, the upgrade software package with the system version number of 4.0 is transferred from the first type system to the storage space of the a system, the a system is upgraded, the a system is operated when the a system is successfully upgraded to the 4.0 version, and the C system is operated when the a system is not successfully upgraded to the 4.0 version.
In a specific embodiment of the present application, the apparatus further includes a sending unit and a third determining unit, where the sending unit is configured to send determination information to a target system before obtaining the upgrade software package and controlling the first type system to forward the upgrade software package to a storage space of the second type system, where the target system generates feedback information based on the determination information, where the determination information is information for determining a type of the target system, and the feedback information is used to identify the type of the target system; the third determining unit is configured to determine whether the target system is the first type system according to the feedback information. In this embodiment, the type of the target system may be determined first, and whether to acquire the upgrade software package may be determined according to the type of the target system, and for different types of system functions, the upgrade software package may be acquired only when the target system is the first type system, which may further ensure better processing capability of the processor chip.
In yet another embodiment of the present application, the processor chip includes a first storage area and a second storage area, the first storage area is used for storing the first type system, the second storage area is used for storing the second type system, a start address of the first storage area is 0, and a start address of the second storage area is greater than an end address of the first storage area. In this embodiment, after the processor chip is powered on, the default is to load data from the address 0 first, so that the first type is stored in the first area, and the start address of the first area is 0, so that after the processor chip is powered on, the first type system is loaded first, and the spaces of the storage addresses of the first storage area and the second storage area cannot be overlapped, which can ensure that the function of the processor chip cannot be abnormal.
In another embodiment, the first type system and the second type system can be combined into a download file for burning.
In yet another embodiment, the first type system may be a mobile phone system and the second type system may be an APP.
The software upgrading device of the processor chip comprises a processor and a memory, wherein the first acquiring unit, the upgrading unit, the first determining unit and the like are stored in the memory as program units, and the processor executes the program units stored in the memory to realize corresponding functions.
The processor comprises a kernel, and the kernel calls the corresponding program unit from the memory. The kernel can be set to be one or more, and the kernel can be upgraded again under the condition that the power failure occurs in the process of remotely upgrading the software program of the processor chip by adjusting the kernel parameters.
The memory may include volatile memory in a computer readable medium, Random Access Memory (RAM) and/or nonvolatile memory such as Read Only Memory (ROM) or flash memory (flash RAM), and the memory includes at least one memory chip.
An embodiment of the present invention provides a computer-readable storage medium, on which a program is stored, where the program, when executed by a processor, implements a software upgrading method for the processor chip.
The embodiment of the invention provides a processor, which is used for running a program, wherein the software upgrading method of the processor chip is executed when the program runs.
An embodiment of the present application further provides a processor system, which includes a processor chip and a control unit, where the control unit is configured to execute any one of the above methods.
In the system, because the software upgrading method comprises any processor chip, the method firstly obtains an upgrading software package, controls the first type system to transfer the upgrading software package to the storage space of the second type system, under the condition that the processor chip is powered off, data in the first type system is not changed, then adopts the upgrading software package to upgrade the second type system, and finally determines whether the second type system needs to be upgraded again if the power off condition occurs in the process of upgrading the second type system, and under the condition that the second type system needs to be upgraded again, controls the first type system again to transfer the upgrading software package to the storage space of the second type system. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the power is turned on again.
The embodiment of the invention provides equipment, which comprises a processor, a memory and a program which is stored on the memory and can run on the processor, wherein when the processor executes the program, at least the following steps are realized:
step S101, obtaining an upgrade software package, controlling the first type system to transfer the upgrade software package to a storage space of the second type system, and under the condition that the processor chip is powered off, not changing data in the first type system;
step S102, upgrading the second type system by adopting the upgrading software package;
step S103, if the power failure occurs in the process of upgrading the second type system, determining whether the second type system needs to be upgraded again, and if the second type system needs to be upgraded again, controlling the first type system again to transfer the upgrade software package to the storage space of the second type system.
The device herein may be a server, a PC, a PAD, a mobile phone, etc.
The present application further provides a computer program product adapted to perform a program of initializing at least the following method steps when executed on a data processing device:
step S101, obtaining an upgrade software package, controlling the first type system to transfer the upgrade software package to a storage space of the second type system, and under the condition that the processor chip is powered off, not changing data in the first type system;
step S102, upgrading the second type system by adopting the upgrading software package;
step S103, if the power failure occurs in the process of upgrading the second type system, determining whether the second type system needs to be upgraded again, and if the second type system needs to be upgraded again, controlling the first type system again to transfer the upgrade software package to the storage space of the second type system.
In the above embodiments of the present invention, the description of each embodiment has its own emphasis, and reference may be made to the related description of other embodiments for parts that are not described in detail in a certain embodiment.
In the embodiments provided in the present application, it should be understood that the disclosed technology can be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, the above-described division of the units may be a logical division, and in actual implementation, there may be another division, for example, multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, units or modules, and may be in an electrical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit may be stored in a computer-readable storage medium if it is implemented in the form of a software functional unit and sold or used as a separate product. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the above methods according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic or optical disk, and other various media capable of storing program codes.
From the above description, it can be seen that the above-described embodiments of the present application achieve the following technical effects:
1) the software upgrading method of the processor chip comprises the steps of firstly obtaining an upgrading software package, controlling a first type system to transfer the upgrading software package to a storage space of a second type system, under the condition that the processor chip is powered off, data in the first type system are not changed, then adopting the upgrading software package to upgrade the second type system, finally determining whether the second type system needs to be upgraded again or not if the power off condition occurs in the process of upgrading the second type system, and under the condition that the second type system needs to be upgraded again, controlling the first type system again to transfer the upgrading software package to the storage space of the second type system. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the processor chip is powered on again.
2) According to the software upgrading device of the processor chip, the first obtaining unit obtains the upgrading software package, the first type system is controlled to transfer the upgrading software package to the storage space of the second type system, under the condition that the processor chip is powered off, data in the first type system are not changed, the upgrading unit adopts the upgrading software package to upgrade the second type system, if the first determining unit is powered off in the process of upgrading the second type system, whether the second type system needs to be upgraded again is determined, and under the condition that the second type system needs to be upgraded again, the first type system is controlled to transfer the upgrading software package to the storage space of the second type system again. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the processor chip is powered on again.
3) The processor system comprises any software upgrading method of the processor chip, the method comprises acquiring upgrade software package, controlling the first type system to transfer the upgrade software package to the storage space of the second type system, under the condition that the processor chip is powered off, the data in the first type system is not changed, then the second type system is upgraded by adopting the upgrading software package, and finally, if the power off condition occurs in the process of upgrading the second type system, whether the second type system needs to be upgraded again is determined, and under the condition that the second type system needs to be upgraded again, the first type system is controlled again to transfer the upgrading software package to the storage space of the second type system. In the scheme, the upgrading software package is transferred from the first type system to the storage space of the second type system, the data in the first type system cannot be changed, when the processor chip is powered off, the damaged data is the data in the second type system, the first type system receives the upgrading software package again, and then the upgrading software package is transferred to the storage space of the second type system, so that the second type data can be upgraded after the processor chip is powered on again.
The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (11)

1. A method for upgrading software of a processor chip, wherein the processor chip includes a first type system and a second type system, comprising:
acquiring an upgrading software package, controlling the first type system to transfer the upgrading software package to a storage space of the second type system, and under the condition that the processor chip is powered off, data in the first type system is not changed;
upgrading the second type system by adopting the upgrading software package;
and if the situation of power failure occurs in the process of upgrading the second type system, determining whether the second type system needs to be upgraded again, and under the situation that the second type system needs to be upgraded again, controlling the first type system again to transfer the upgrading software package to the storage space of the second type system.
2. The method of claim 1, wherein prior to upgrading the second type system with the upgrade software package, the method further comprises:
and acquiring the system version number of each second type system.
3. The method of claim 2, wherein there are a plurality of said second type systems, and wherein upgrading said second type system using said upgrade software package comprises:
determining the second type system with the lowest system version number as a target second type system;
and transferring the upgrading software package from the first type system to the target second type system, and upgrading the target second type system.
4. The method of claim 3, wherein after upgrading the second type system using the upgrade software package, the method further comprises:
and determining the second type system which is actually operated according to whether the target second type system is successfully upgraded to the highest version.
5. The method of claim 4, wherein determining the second-type system that is actually running based on whether the target second-type system was successfully upgraded to the highest version comprises:
running the target second-type system if the target second-type system has been successfully upgraded to the highest version;
running a highest version of the second-type system of the plurality of second-type systems without successfully upgrading the target second-type system to the highest version.
6. The method according to any one of claims 1 to 5, wherein before obtaining an upgrade software package and controlling the first type system to dump the upgrade software package into the storage space of the second type system, the method further comprises:
sending determination information to a target system, wherein the target system generates feedback information based on the determination information, the determination information is used for determining the type of the target system, and the feedback information is used for identifying the type of the target system;
and determining whether the target system is the first type system or not according to the feedback information.
7. The method of any one of claims 1 to 5, wherein the processor chip comprises a first storage area and a second storage area, the first storage area is used for storing the first type system, the second storage area is used for storing the second type system, wherein a start address of the first storage area is 0, and a start address of the second storage area is larger than an end address of the first storage area.
8. A software upgrading apparatus for a processor chip, the processor chip including a first type system and a second type system, comprising:
the first acquisition unit is used for acquiring an upgrading software package and controlling the first type system to transfer the upgrading software package to the storage space of the second type system, and under the condition that the processor chip is powered off, data in the first type system are not changed;
the upgrading unit is used for upgrading the second type system by adopting the upgrading software package;
the first determining unit is used for determining whether the second type system needs to be upgraded again if power failure occurs in the process of upgrading the second type system, and controlling the first type system to transfer the upgrading software package to the storage space of the second type system again under the condition that the second type system needs to be upgraded again.
9. A computer-readable storage medium, characterized in that the computer-readable storage medium comprises a stored program, wherein the program performs the method of any one of claims 1 to 7.
10. A processor, characterized in that the processor is configured to run a program, wherein the program when running performs the method of any of claims 1 to 7.
11. A processor system, characterized in that the processor system comprises a processor chip and a control unit for performing the method of any of claims 1 to 7.
CN202210296327.2A 2022-03-24 2022-03-24 Software upgrading method and device for processor chip, processor and processor system Pending CN114691180A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210296327.2A CN114691180A (en) 2022-03-24 2022-03-24 Software upgrading method and device for processor chip, processor and processor system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210296327.2A CN114691180A (en) 2022-03-24 2022-03-24 Software upgrading method and device for processor chip, processor and processor system

Publications (1)

Publication Number Publication Date
CN114691180A true CN114691180A (en) 2022-07-01

Family

ID=82139515

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210296327.2A Pending CN114691180A (en) 2022-03-24 2022-03-24 Software upgrading method and device for processor chip, processor and processor system

Country Status (1)

Country Link
CN (1) CN114691180A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118118728A (en) * 2024-04-30 2024-05-31 四川天邑康和通信股份有限公司 IPTV set top box data processing method and device, set top box and medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113157303A (en) * 2021-05-27 2021-07-23 盈合(深圳)机器人与自动化科技有限公司 Upgrading method, embedded system, terminal and computer storage medium
CN113641390A (en) * 2021-10-18 2021-11-12 苏州万店掌软件技术有限公司 System upgrading method, device, equipment and storage medium
WO2021244143A1 (en) * 2020-05-30 2021-12-09 展讯通信(上海)有限公司 Software upgrading method and device
CN114035828A (en) * 2021-12-14 2022-02-11 北京天融信网络安全技术有限公司 Program upgrading method and device, electronic equipment and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021244143A1 (en) * 2020-05-30 2021-12-09 展讯通信(上海)有限公司 Software upgrading method and device
CN113157303A (en) * 2021-05-27 2021-07-23 盈合(深圳)机器人与自动化科技有限公司 Upgrading method, embedded system, terminal and computer storage medium
CN113641390A (en) * 2021-10-18 2021-11-12 苏州万店掌软件技术有限公司 System upgrading method, device, equipment and storage medium
CN114035828A (en) * 2021-12-14 2022-02-11 北京天融信网络安全技术有限公司 Program upgrading method and device, electronic equipment and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118118728A (en) * 2024-04-30 2024-05-31 四川天邑康和通信股份有限公司 IPTV set top box data processing method and device, set top box and medium

Similar Documents

Publication Publication Date Title
US6055632A (en) Method and apparatus for transferring firmware to a non-volatile memory of a programmable controller system
US9507604B2 (en) Boot method and boot system
US6668261B1 (en) Method of upgrading a program using associated configuration data
CN101431441B (en) Method for on-line updating FPGA system embedded with CPU
US20100325622A1 (en) Updating Firmware of an Electronic Device
EP3518097B1 (en) Firmware updating method and electronic device using the same
CN109558160A (en) Upgrade method, embedded system
US20070180223A1 (en) Computer system and method of booting the system
CN101770383B (en) Method and device for on-line upgrade of cross-platform version
CN104123153A (en) Apparatus and method for firmware upgrade using USB
CN104915226A (en) Network device software starting method, device and network device
CN107870769A (en) The installation method and device of operating system
CN109753299A (en) A kind of method for upgrading system, device and computer storage medium
CN110597533A (en) FPGA board card program updating system and method
US5940627A (en) User selectable feature set for a flash ROM based peripheral
WO2022105595A1 (en) Method and apparatus for upgrading system of embedded device, and embedded device
CN107690630A (en) Bridge configuration in computing device
CN112231005A (en) Method for managing FPGA (field programmable Gate array) version based on UBOOT (Universal boot on Board)
CN116009921A (en) Method, device and medium for upgrading embedded operating system
CN114691180A (en) Software upgrading method and device for processor chip, processor and processor system
EP2372565A1 (en) Method for managing USB devices
CN113934445A (en) Equipment firmware upgrading system, method and device, computer equipment and storage medium
CN108664275A (en) Method, system and the storage medium of backup configuration parameter
WO2017173924A1 (en) Method and device for switching between file systems
CN116954752A (en) Differentiated system configuration and loading method and device and computer equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination