Dynamic partitioning burning method and device, chip, chip module, and storage medium

By obtaining the total size information of the system image file of the dynamic partition and writing it into the header information, and only burning the data of the sub-logical partitions, the problem of low download and burning efficiency in the existing technology is solved, and a more efficient burning process is achieved.

CN114461235BActive Publication Date: 2026-04-10SPREADTRUM SEMICON (NANJING) CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-26
Publication Date
2026-04-10

AI Technical Summary

Technical Problem

Existing technologies suffer from low download and burning efficiency and long processing time when converting dynamically partitioned system image files to uncompressed formats, especially since the presence of reserved space affects burning efficiency.

Method used

By obtaining the total size information of the system image file to be burned to the dynamic partition and writing it into the header information, only the system image data of each sub-logical partition is burned, without burning the reserved space. The bootloader is used to fill the reserved space with all zeros, thereby improving the download and burning efficiency.

Benefits of technology

During the burning process, only the system image data of each sub-logical partition needs to be downloaded and burned, saving the burning time of the reserved space and significantly improving the download and burning efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114461235B_ABST
    Figure CN114461235B_ABST
Patent Text Reader

Abstract

The application discloses a dynamic partition burning method and device, a chip, a chip module and a storage medium. The total size of at least one system image data in a first system image file to be burned to a dynamic partition is acquired, the format of the first system image file is a non-sparse matrix format, and the dynamic partition comprises at least one sub-logical partition; information of the total size is written into header information of a second system image file, the second system image file is a sparse matrix format file of the first system image file; and at least one system image data in the first system image file is burned to at least one sub-logical partition respectively according to the header information, so that only system image data needs to be downloaded and burned during burning, and a reserved space does not need to be burned, and the downloading and burning efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computers, and in particular to a dynamic partition burning method and device, a chip, a chip module, and a storage medium. BACKGROUND

[0002] Dynamic partitioning refers to dividing a physical partition into multiple logical partitions, and the physical partition also contains a certain reserved space. The reserved space is filled with 0-byte data. Burning a dynamic partition refers to burning a system image file of the dynamic partition to each logical partition and the reserved space. The system image file of the dynamic partition is compiled into a sparse matrix storage format by default, that is, a compressed format. When burning, the system image file in the sparse format needs to be converted into a non-compressed format for burning, or the system image file in the compressed format is burned and converted during burning. Regardless of which method is used, the system image file burned onto the physical device is always in the non-compressed format.

[0003] When the system image file of the dynamic partition is converted into the non-compressed format, the prior art converts according to the partition size configured by the system. Assuming that the dynamic partition includes the following logical partitions: system, system extension, product, and vendor, the actual size of the dynamic partition is the total size of system, system extension, product, vendor, and the reserved space. For example, the size of the dynamic partition configured by the current system is 6G, the actual size of system, system extension, product, and vendor is 4G, and the reserved space is 2G. The actual size of the dynamic partition converted into the non-compressed format is 6G. When burning, the system image file is downloaded according to the actual size of the dynamic partition, which is relatively low in download and burn efficiency and time-consuming. SUMMARY

[0004] The present application provides a dynamic partition burning method and device, a chip, a chip module, and a storage medium to improve the download and burn efficiency.

[0005] In a first aspect, a dynamic partition burning method is provided, and the method includes:

[0006] obtaining the total size of at least one system image data in a first system image file to be burned to a dynamic partition, the format of the first system image file being a non-sparse matrix format, and the dynamic partition including at least one sub-logical partition;

[0007] write the total size information into header information of a second system image file, the second system image file being a sparse matrix format file of the first system image file;

[0008] According to the header information, burn at least one system image data in the first system image file into at least one sub-logical partition respectively.

[0009] In a possible implementation, the total size of at least one system image data in the first system image file to be burned into the dynamic partition comprises:

[0010] Obtain the second system image file;

[0011] According to the second system image file, obtain the first system image file;

[0012] Obtain the size of at least one system image data in the first system image file;

[0013] According to the size of at least one system image data in the first system image file, obtain the total size of at least one system image data in the first system image file.

[0014] In another possible implementation, the method further comprises:

[0015] Obtain configuration information, the configuration information comprising the size of the dynamic partition;

[0016] According to the configuration information, create a physical partition of the dynamic partition.

[0017] In another possible implementation, the dynamic partition further comprises a reserved space, and after the at least one system image data in the first system image file is burned into the at least one sub-logical partition according to the header information, the method further comprises:

[0018] Stop transmitting and filling all 0 data into the reserved space;

[0019] Fill the all 0 data into the reserved space by starting a boot program.

[0020] The second aspect provides a dynamic partition burning method, the method comprising:

[0021] Obtain a first system image file;

[0022] According to the first system image file, obtain a second system image file, the format of the second system image file being a non-sparse matrix format, and the first system image file being a sparse matrix format file of the second system image file;

[0023] obtaining system image data of at least one sub-logical partition in the second system image file;

[0024] burning the at least one system image data into the at least one sub-logical partition of the dynamic partition respectively.

[0025] In a possible implementation, the method further includes:

[0026] obtaining a sub-logical partition information table, the sub-logical partition information table including address ranges of the at least one sub-logical partition;

[0027] The obtaining of the at least one system image data in the second system image file includes:

[0028] According to the sub-logical partition information table, obtaining at least one system image data corresponding to the address ranges of the at least one sub-logical partition in the second system image file.

[0029] In another possible implementation, the dynamic partition further includes a reserved space, and after the at least one system image data is burned into the at least one sub-logical partition respectively, the method further includes:

[0030] stopping transmission of all-0 data and filling the all-0 data into the reserved space;

[0031] filling the all-0 data into the reserved space by starting a boot program.

[0032] In a third aspect, a dynamic partition burning device is provided, which can implement the dynamic partition burning method in the first aspect. For example, the dynamic partition burning device can be a chip, a chip module, or a burning device. The above method can be implemented by software, hardware, or by hardware executing corresponding software.

[0033] In a possible implementation, the device includes a first obtaining unit configured to obtain a total size of at least one system image data in a first system image file to be burned into a dynamic partition, the first system image file being in a non-sparse matrix format, and the dynamic partition including at least one sub-logical partition;

[0034] a writing unit configured to write information of the total size into header information of a second system image file, the second system image file being a sparse matrix format file of the first system image file;

[0035] a burning unit configured to burn the at least one system image data in the first system image file into the at least one sub-logical partition respectively according to the header information.

[0036] Optionally, the first obtaining unit comprises:

[0037] a second obtaining unit, configured to obtain the second system image file;

[0038] a third obtaining unit, configured to obtain the first system image file according to the second system image file;

[0039] a fourth obtaining unit, configured to obtain the size of at least one system image data in the first system image file;

[0040] a fifth obtaining unit, configured to obtain the total size of at least one system image data in the first system image file according to the size of at least one system image data in the first system image file.

[0041] Optionally, the apparatus further comprises:

[0042] a sixth obtaining unit, configured to obtain configuration information, wherein the configuration information comprises the size of the dynamic partition;

[0043] a creating unit, configured to create a physical partition of the dynamic partition according to the configuration information.

[0044] Optionally, the dynamic partition further comprises a reserved space, and the apparatus further comprises:

[0045] a transmitting unit, configured to stop transmitting all-0 data;

[0046] a filling unit, configured to stop filling the all-0 data into the reserved space;

[0047] The filling unit is further configured to fill the all-0 data into the reserved space by starting a boot program.

[0048] In yet another possible implementation, the dynamic partition burning apparatus in the third aspect above comprises a processor coupled with a memory; the processor is configured to support the apparatus to perform corresponding functions in the dynamic partition burning method above. The memory is coupled with the processor, and stores programs (instructions) and / or data necessary for the apparatus. Optionally, the dynamic partition burning apparatus can further comprise a communication interface to support communication between the apparatus and other devices. Optionally, the memory can be located inside the dynamic partition burning apparatus, or located outside the dynamic partition burning apparatus.

[0049] The fourth aspect provides a dynamic partition burning apparatus, which can implement the dynamic partition burning method in the second aspect above. For example, the dynamic partition burning apparatus can be a chip, a chip module, or a burning device. The method above can be implemented by software, hardware, or by hardware executing corresponding software.

[0050] In a possible implementation, the apparatus comprises:

[0051] a first obtaining unit, configured to obtain a first system image file;

[0052] a second obtaining unit, configured to obtain a second system image file according to the first system image file, the second system image file being in a non-sparse matrix format, and the first system image file being a sparse matrix format file of the second system image file;

[0053] a third obtaining unit, configured to obtain at least one system image data in the second system image file;

[0054] a burning unit, configured to burn the at least one system image data to at least one sub-logical partition of a dynamic partition respectively.

[0055] Optionally, the apparatus further comprises:

[0056] a fourth obtaining unit, configured to obtain a sub-logical partition information table, the sub-logical partition information table comprising an address range of the at least one sub-logical partition;

[0057] the third obtaining unit, configured to obtain at least one system image data corresponding to the address range of the at least one sub-logical partition in the second system image file according to the sub-logical partition information table.

[0058] Optionally, the dynamic partition further comprises a reserved space, and the apparatus further comprises:

[0059] a transmission unit, configured to stop transmitting all-0 data;

[0060] a filling unit, configured to stop filling the all-0 data to the reserved space;

[0061] the filling unit, further configured to fill the all-0 data to the reserved space by starting a boot program.

[0062] In another possible implementation, the apparatus for burning the dynamic partition in the fourth aspect comprises a processor coupled with a memory; the processor is configured to support the apparatus to perform corresponding functions in the method for burning the dynamic partition. The memory is coupled with the processor, and stores programs (instructions) and / or data necessary for the apparatus. Optionally, the apparatus for burning the dynamic partition can further comprise a communication interface for supporting communication between the apparatus and other devices. Optionally, the memory can be located inside the apparatus for burning the dynamic partition, or located outside the apparatus for burning the dynamic partition.

[0063] In a fifth aspect, a computer readable storage medium is provided, in which a computer program or instructions are stored, and when the computer program or instructions are executed, the method of the first aspect, the second aspect, or any implementation of the first aspect or the second aspect is implemented.

[0064] In a sixth aspect, a computer program product is provided, which comprises instructions, and when the instructions are run on a dynamic partitioning burning device, the device that shares a single camera by multiple applications is caused to execute the method of the first aspect, the second aspect, or any implementation of the first aspect or the second aspect.

[0065] The dynamic partitioning burning scheme provided in the present application has the following beneficial effects:

[0066] During burning, only the system image data of each sub-logical partition needs to be downloaded and burned, and no reserved space needs to be burned, thereby improving the downloading and burning efficiency. BRIEF DESCRIPTION OF DRAWINGS

[0067] Figure 1 FIG. 1 is a schematic diagram of a burning system framework structure for a device before leaving the factory in an application scenario;

[0068] Figure 2 FIG. 2 is a schematic diagram of a data storage structure of an Android system on a terminal;

[0069] Figure 3 FIG. 3 is a schematic diagram of a flow of a dynamic partitioning burning method provided in an embodiment of the present application;

[0070] Figure 4 FIG. 4 is a schematic diagram of a dynamic partitioning structure of a current actual burning;

[0071] Figure 5 FIG. 5 is a schematic diagram of a dynamic partitioning structure of an actual burning of an example of the present application;

[0072] Figure 6 FIG. 6 is a schematic diagram of a flow of another dynamic partitioning burning method provided in an embodiment of the present application;

[0073] Figure 7 FIG. 7 is a schematic diagram of a flow of still another dynamic partitioning burning method provided in an embodiment of the present application;

[0074] Figure 8 FIG. 8 is a schematic diagram of a structure of a dynamic partitioning burning device provided in an embodiment of the present application;

[0075] Figure 9 FIG. 9 is a schematic diagram of a structure of another dynamic partitioning burning device provided in an embodiment of the present application;

[0076] Figure 10Another dynamic partitioning burning device structure diagram provided by an embodiment of the present application. DETAILED DESCRIPTION

[0077] In order to better understand the technical solutions of the present application, the embodiments of the present application are described in detail below with reference to the drawings.

[0078] It should be clear that the described embodiments are only part of the embodiments of the present application, not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative labor are within the scope of protection of the present application.

[0079] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application. The singular forms "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include the plural forms, unless the context clearly indicates otherwise.

[0080] It should be understood that the term "and / or" used herein is only to describe the association relationship of the associated objects, which means that there can be three relationships, for example, A and / or B, which can represent the three cases of A alone, A and B together, and B alone. In addition, the character " / " in this paper generally represents that the front and rear associated objects are a "or" relationship.

[0081] Terminals, such as mobile phones, computers, tablets, wearable devices, etc., need to install an operating system before they can be used by users. For example, a mobile phone needs to install a mobile phone operating system (such as an Android system) before it can be used by a user. Since the installation process of the operating system is relatively cumbersome, and the operating system of some terminals needs special equipment to install, in order to facilitate the user to use the terminal, the terminal usually has a basic operating system installed before the terminal is sold. In this way, the user does not need to perform complex operating system installation operations after purchasing the terminal, and can use the terminal. For example, before the mobile phone is sold to the user, the mobile phone has installed a basic mobile phone operating system. The user can directly use the basic functions of the mobile phone (such as connecting to a mobile network, making a call) after purchasing the mobile phone.

[0082] In actual application scenarios, a common pre-delivery basic operating system installation method is to directly burn a basic operating system (such as a basic Android system provided by Google) to the device by a burning device. Figure 1 The burning system framework structure diagram of the system burning of the device before delivery in an application scenario is shown, as shown in Figure 1As shown, after the terminal 100 completes hardware assembly, it is connected to the burning device 110, and the memory 120 is connected to the burning device 110. The memory 120 stores the basic system installation package of the basic operating system, which contains the image file of the basic operating system. The burning device 110 reads the basic system installation package from the memory 120, parses the package to obtain the image file of the basic operating system, and performs data burning based on the image file of the basic operating system. The operating system data corresponding to the image file of the basic operating system is burned onto the memory of the terminal 100, thereby realizing the installation of the basic operating system on the terminal 100.

[0083] The terminal 100 in this application embodiment includes, but is not limited to, smartphones, smart headphones, tablets, smart refrigerators, smart speakers, etc., that can install an operating system. The terminal 100 can also be a control board internally installed with an operating system. Exemplary embodiments of the operating system include, but are not limited to, Android or other operating systems.

[0084] Taking Android systems that use the virtual A / B upgrade method as an example, Figure 2 The diagram shows the data storage structure of the Android system on a terminal. Figure 2 As shown, the Android system data storage area includes a basic partition (common), a static partition (A), a static partition (B), a dynamic partition (super), and a user data partition (userdata). Userdata stores user personal data, such as apps installed by the user, saved pictures, documents, and videos. The basic partition stores system data that does not participate in operating system upgrades. The structures of static partitions (A) and (B) correspond to each other, and sub-partitions are distinguished by the suffixes _a and _b. Static partition (A) includes bootloader_a, boot_a, vendor_boot_a, dtbo_a, and vbmmeta_a; static partition (B) includes bootloader_b, boot_b, vendor_boot_b, dtbo_b, and vbmmeta_b. The dynamic partition contains multiple sub-logical partitions (system, system_ext, product, vendor, cust, odm). For software upgrade needs, the dynamic partition may also include reserved space.

[0085] The dynamic partition means that the content of the whole partition dynamically changes, and is widely applied in the Android platform at present. The dynamic partition is essentially composed of sub-logical partition images, and exists to improve the utilization of space. If each sub-logical partition is an actual physical partition, each partition needs to reserve space required for upgrading, and the reserved space cannot be shared between the physical partitions. The dynamic partition is a mechanism introduced to solve this problem.

[0086] At the device startup, a static partition is started. For example, the device is started from the static partition (A): the base partition, the static partition (A) and the dynamic partition are loaded in sequence; the device is started from the static partition (B): the base partition, the static partition (B) and the dynamic partition are loaded in sequence.

[0087] In view of the low download and burning efficiency in the background art, the application provides a burning scheme of a dynamic partition. The total size of at least one system image data in a first system image file to be burned to the dynamic partition is acquired. The format of the first system image file is a non-sparse matrix format, and the dynamic partition includes at least one sub-logical partition. The information of the total size is written into the header information of a second system image file. The second system image file is a sparse matrix format file of the first system image file. According to the header information, the at least one system image data in the first system image file is burned to the at least one sub-logical partition respectively. Thus, only the system image data of each sub-logical partition needs to be downloaded and burned, and the reserved space does not need to be burned, thereby improving the download and burning efficiency.

[0088] As shown in FIG. 1, a flowchart of a burning method of a dynamic partition provided by an embodiment of the application is shown. The method can include the following steps: Figure 3

[0089] S301. The total size of at least one system image data in a first system image file to be burned to the dynamic partition is acquired. The format of the first system image file is a non-sparse matrix format, and the dynamic partition includes at least one sub-logical partition.

[0090] As shown in FIG. 1, a flowchart of a burning method of a dynamic partition provided by an embodiment of the application is shown. The method can include the following steps: Figure 4 ​The diagram shows the structure of a dynamic partition in a current actual flashing process. For example, the system creates a dynamic partition, which includes sub-logical partitions such as system, system_ext, product, and vendor, and may also include reserved space. The size of the dynamic partition configured by the system is the size of the aforementioned sub-logical partitions and the reserved space. If the reserved space is too large, it will affect the flashing efficiency. For example, in common mobile Android devices, flashing the dynamic partition accounts for 90% of the entire flashing time. Optimizing the download efficiency of the dynamic partition can greatly improve the overall software download and flashing efficiency of the flashing device.

[0091] Store to Figure 1 The system image files of the dynamically partitioned memory 120 shown are all compiled into a sparse matrix format by default, which is a compressed format. During programming, the sparse matrix format needs to be converted to a non-sparse matrix format. Currently, common programming methods include converting a second system image file downloaded from memory 120 in sparse matrix format into a first system image file in non-sparse matrix format for programming, or programming the second system image file and converting it during the programming process. Regardless of the programming method, the final file programmed to the terminal will always be the first system image file in non-sparse matrix format.

[0092] In this embodiment, to improve the software download and burning efficiency of the burning device 110, a second system image file is downloaded from the memory 120. This second system image file is in sparse matrix format as the first system image file. The total size of at least one system image data in the first system image file to be burned to the dynamic partition is obtained. This first system image file is in non-sparse matrix format.

[0093] like Figure 5 The diagram shown illustrates the structure of the dynamic partition actually burned in this application example. The actual dynamic partition includes the following sub-logical partitions: system, system_ext, product, and vendor, excluding reserved space. The total size of at least one system image data in the first system image file to be burned into the dynamic partition is obtained.

[0094] S302. Write the total size information into the header information of the second system image file.

[0095] The programming device 110 downloads a second system image file from the memory 120 and performs programming based on the second system image file. After obtaining the total size information of at least one system image data in the first system image file to be programmed into the dynamic partition, the programming device 110 can write the total size information into the header information of the second system image file.

[0096] S303. According to the header information, at least one system image data in the first system image file is respectively burned into at least one sub-logical partition.

[0097] The whole dynamic partition image is composed of sub-logical partition images, and when burned, a fixed-size block is read from the large dynamic partition and written one by one for downloading, and after obtaining the information of the total size of at least one system image data in the first system image file to be burned into the dynamic partition, because the content in the reserved space is all 0-byte data filled, which has no actual meaning, therefore, the block in the dynamic partition reserved space does not need to be burned, so as to improve the downloading and burning efficiency.

[0098] In a specific implementation, when burned, the burning device 110 converts the second system image file into the first system image file in the non-sparse matrix format, and according to the information of the total size of at least one system image data in the first system image file to be burned into the dynamic partition, at least one system image data in the first system image file is respectively burned into at least one sub-logical partition. That is, the actual size of the sub-logical partition is taken as the end address, and after burning each sub-logical partition, the burning and writing are completed. Wherein, the first system image file includes at least one system image data.

[0099] According to the dynamic partition burning method provided by the embodiment of the application, when burned, according to the total size of at least one system image data in the first system image file, only at least one system image data needs to be downloaded and burned, and the reserved space does not need to be burned, so as to improve the downloading and burning efficiency.

[0100] As shown in FIG. 6, the method provided by the embodiment of the application can include the following steps: Figure 6

[0101] S601. Obtain configuration information.

[0102] Obtain the configuration information of the system. The configuration information includes the size of the dynamic partition. For example, the system creates a dynamic partition, which includes each sub-logical partition of system, system_ext, product, vendor and the reserved space. The size of the dynamic partition configured by the system is the size of each sub-logical partition and the reserved space.

[0103] S602. According to the configuration information, create a physical partition of the dynamic partition.

[0104] ​Before burning the dynamic partition, the physical partition of the dynamic partition is created according to the configuration information. As described above, the total reserved space for upgrading each sub-logical partition is a total reserved space. Each sub-logical partition, the reserved space and the physical partition of the dynamic partition have a certain correspondence in address. When burning, the first system image file in the non-sparse matrix format needs to be burned into the physical partition of the dynamic partition. Specifically, at least one system image data in the first system image file needs to be burned into the physical partition corresponding to at least one sub-logical partition.

[0105] S603. Obtain a second system image file.

[0106] The burning device 110 downloads the second system image file from the storage 120, and the burning will be performed according to the second system image file. The second system image file is a sparse matrix format file of the first system image file.

[0107] S604. Obtain the first system image file according to the second system image file.

[0108] After the burning device 110 obtains the second system image file, the first system image file can be obtained according to the second system image file. The first system image file is in a non-sparse matrix format. That is, the second system image file is converted into the first system image file.

[0109] S605. Obtain the size of at least one system image data in the first system image file.

[0110] After the burning device 110 obtains the first system image file, the first system image file includes at least one system image data, and therefore, the size of at least one system image data in the first system image file can be obtained according to the first system image file.

[0111] S606. Obtain the total size of at least one system image data in the first system image file according to the size of at least one system image data in the first system image file.

[0112] The total size of at least one system image data in the first system image file can be the sum of the sizes of each system image data in the first system image file.

[0113] S607. Write the information of the total size into the header information of the second system image file. The second system image file is a sparse matrix format file of the first system image file.

[0114] After the burning device 110 obtains the information of the total size of at least one system image data in the first system image file to be burned into the dynamic partition, the information of the total size can be written into the header information of the second system image file.

[0115] S608. According to the header information, the at least one system image data in the first system image file is respectively burned into the at least one sub-logical partition.

[0116] The burning device 110 converts the second system image file into the first system image file in the non-sparse matrix format during the burning, and according to the information of the total size of the at least one system image data in the first system image file to be burned into the dynamic partition, the at least one system image data in the first system image file is respectively burned into the at least one sub-logical partition. That is, the burning is completed after the sub-logical partition is burned to the actual size of the sub-logical partition as the end address. The first system image file includes at least one system image data.

[0117] S609. Stop transmitting and filling the all-0 data into the reserved space.

[0118] After the burning of each sub-logical partition is completed, the burning device 110 stops transmitting and filling the all-0 data into the reserved space. Thus, the burning of the dynamic partition is completed.

[0119] As described above, the burning of the dynamic partition occupies ninety percent of the time of the entire mobile Android device burning. Since the burning of the reserved space is saved, the burning time of the dynamic partition is saved, and thus the time of the entire terminal burning is saved.

[0120] S610. The all-0 data is filled into the reserved space by the start-up boot program.

[0121] Further, after the burning of the terminal is completed, the all-0 data can be filled into the reserved space by the start-up boot program when the terminal is started.

[0122] According to the burning method of the dynamic partition provided in the embodiment of the present application, during the burning, according to the total size of the at least one system image data in the first system image file, only the at least one system image data needs to be downloaded and burned, and the reserved space does not need to be burned, thereby improving the downloading and burning efficiency.

[0123] In view of the low downloading and burning efficiency in the background art, the present application provides another burning scheme of the dynamic partition. By obtaining the at least one system image data in the second system image file in the non-sparse matrix format, the at least one system image data is respectively burned into the at least one sub-logical partition of the dynamic partition, so that during the burning, only the at least one system image data needs to be downloaded and burned, and the reserved space does not need to be burned, thereby improving the downloading and burning efficiency.

[0124] As Figure 7As shown, a flowchart of another dynamic partitioning burning method provided by the embodiments of the present application is shown, which can include the following steps:

[0125] S701. Obtain a first system image file.

[0126] The burning device 110 downloads the first system image file of the dynamic partitioning from the storage 120. The first system image file is a sparse matrix format file. Exemplarily, the dynamic partitioning includes each sub-logical partition of system, system_ext, product, vendor, and can also include a reserved space.

[0127] S702. Obtain a second system image file according to the first system image file.

[0128] The burning device 110 converts the first system image file into the second system image file. The second system image file is in a non-sparse matrix format, and the first system image file is a sparse matrix format file of the second system image file. The second system image file includes system image data of each sub-logical partition.

[0129] S703. Obtain at least one system image data in the second system image file.

[0130] After the burning device 110 obtains the second system image file, at least one system image data in the second system image file can be obtained.

[0131] Specifically, first, a sub-logical partition information table is obtained, which includes address ranges of at least one sub-logical partition. Then, according to the sub-logical partition information table, at least one system image data corresponding to the address range of at least one sub-logical partition in the second system image file is obtained.

[0132] S704. Burn at least one system image data to at least one sub-logical partition of the dynamic partitioning, respectively.

[0133] After the burning device 110 obtains at least one system image data, at least one system image data is burned to the corresponding sub-logical partition, respectively. After burning each sub-logical partition, the burning is completed.

[0134] Further, the method can also include the following steps (shown by dashed lines in the figure):

[0135] S705. Stop transmitting and filling all 0 data to the reserved space.

[0136] After completing the burning of each sub-logical partition, the burning device 110 stops transmitting and filling all 0 data to the reserved space. Thus, the burning of the dynamic partitioning is completed.

[0137] As described above, the dynamic partition burning occupies 90% of the time of the entire mobile Android device burning. The reserved space burning is saved, and the dynamic partition burning time is saved, and the entire terminal burning time is saved.

[0138] S706. The all-0 data is filled into the reserved space by the starting boot program.

[0139] Further, after the burning of the terminal is completed, the all-0 data is filled into the reserved space by the starting boot program when the terminal is started.

[0140] According to the dynamic partition burning method provided by the embodiment of the application, at least one system image data in a second system image file in a non-sparse matrix format is obtained, and the at least one system image data is burned into at least one sub-logical partition of a dynamic partition, so that, during burning, only the at least one system image data needs to be downloaded and burned, and the reserved space does not need to be burned, and the downloading and burning efficiency is improved.

[0141] It can be understood that, in order to implement the functions in the above-described embodiments, the dynamic partition burning device includes corresponding hardware structures and / or software modules for implementing various functions. Those skilled in the art should easily realize that, in combination with the units and method steps of the examples described in the embodiments disclosed in the application, the application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is implemented in the form of hardware or computer software driving hardware depends on the specific application scenario and design constraints of the technical solution.

[0142] Figure 8 、 Figure 9 and Figure 10 The structure schematic diagram of the possible dynamic partition burning device provided by the embodiment of the application is shown. The dynamic partition burning device can be used to implement the functions of the dynamic partition burning device in the above-described method embodiments, and thus the beneficial effects possessed by the above-described method embodiments can also be achieved. In the embodiments of the application, the dynamic partition burning device can be a burning device, and can also be a module (such as a chip or a chip module) applied to the burning device.

[0143] Please refer to Figure 8 The device 8000 includes:

[0144] A first obtaining unit 801 is configured to obtain a total size of at least one system image data in a first system image file to be burned into a dynamic partition, the format of the first system image file being a non-sparse matrix format, and the dynamic partition including at least one sub-logical partition.

[0145] The writing unit 802 is configured to write the total size information into the header information of a second system image file, the second system image file being a sparse matrix format file of the first system image file.

[0146] The burning unit 803 is configured to burn at least one system image data in the first system image file into at least one sub-logical partition according to the header information.

[0147] Optionally, the first obtaining unit 801 includes (shown by a dashed line in the figure):

[0148] The second obtaining unit 8011 is configured to obtain the second system image file.

[0149] The third obtaining unit 8012 is configured to obtain the first system image file according to the second system image file.

[0150] The fourth obtaining unit 8013 is configured to obtain the size of at least one system image data in the first system image file.

[0151] The fifth obtaining unit 8014 is configured to obtain the total size of at least one system image data in the first system image file according to the size of at least one system image data in the first system image file.

[0152] Optionally, the apparatus further includes (shown by a dashed line in the figure):

[0153] The sixth obtaining unit 804 is configured to obtain configuration information, the configuration information including the size of the dynamic partition.

[0154] The creating unit 805 is configured to create a physical partition of the dynamic partition according to the configuration information.

[0155] Optionally, the dynamic partition further includes a reserved space, and the apparatus further includes (shown by a dashed line in the figure):

[0156] The transmitting unit 806 is configured to stop transmitting all-0 data.

[0157] The filling unit 807 is configured to stop filling the all-0 data into the reserved space.

[0158] The filling unit 807 is further configured to fill the all-0 data into the reserved space by starting a boot program.

[0159] The specific implementation of each unit described above can refer to the description of the foregoing Figure 3 or Figure 6 embodiments, which will not be described herein again.

[0160] Please refer to Figure 9The apparatus 9000 comprises:

[0161] A first obtaining unit 901 is configured to obtain a first system image file.

[0162] A second obtaining unit 902 is configured to obtain a second system image file according to the first system image file, wherein the second system image file is in a non-sparse matrix format, and the first system image file is a sparse matrix format file of the second system image file.

[0163] A third obtaining unit 903 is configured to obtain at least one system image data in the second system image file.

[0164] A burning unit 904 is configured to burn the at least one system image data into at least one sub-logical partition of a dynamic partition respectively.

[0165] Optionally, the apparatus further comprises (indicated by a dashed line in the figure):

[0166] A fourth obtaining unit 905 is configured to obtain a sub-logical partition information table, wherein the sub-logical partition information table comprises address ranges of at least one sub-logical partition.

[0167] The third obtaining unit 903 is configured to obtain at least one system image data corresponding to the address ranges of the at least one sub-logical partition in the second system image file according to the sub-logical partition information table.

[0168] Optionally, the dynamic partition further comprises a reserved space, and the apparatus further comprises (indicated by a dashed line in the figure):

[0169] A transmission unit 906 is configured to stop transmitting all-0 data.

[0170] A filling unit 907 is configured to stop filling the all-0 data into the reserved space.

[0171] The filling unit 907 is further configured to fill the all-0 data into the reserved space by starting a boot program.

[0172] The specific implementation of each unit described above can refer to the description of the foregoing embodiments, which will not be repeated here. Figure 7

[0173] Please refer to Figure 10 The apparatus 1000 at least includes a processor 1001, an input device 1002, an output device 1003, and a computer storage medium 1004. Wherein, the processor 1001, the input device 1002, the output device 1003, and the computer storage medium 1004 in the apparatus can be connected through a bus or other means.

[0174] ​The computer storage medium 1004 can be stored in the memory of the device, which is used to store the computer program including program instructions, and the processor 1001 is used to execute the program instructions stored by the computer storage medium 1004. The processor 1001 is the computing core and control core of the device, which is suitable for implementing one or more instructions, and is particularly suitable for loading and executing one or more instructions to implement a corresponding method flow or a corresponding function.

[0175] In one embodiment, the processor 1001 described in the embodiments of the present application can be used to load and execute the method steps in the embodiments shown in Figure 3 , Figure 6 or Figure 7 .

[0176] It should be noted that one or more of the above units or units can be realized by software, hardware or a combination of both. When any of the above units or units is realized by software, the software exists in the form of computer program instructions and is stored in the memory, and the processor can be used to execute the program instructions and realize the above method flow. The processor can be built in the system on chip (SoC) or application specific integrated circuit (ASIC), or be a separate semiconductor chip. In addition to the core for executing software instructions to perform operations or processing, the processor can further include necessary hardware accelerators, such as field programmable gate array (FPGA), programmable logic device (PLD), or logic circuit for implementing special logic operations.

[0177] When any of the above units or units is realized by hardware, the hardware can be any one or any combination of CPU, microprocessor, digital signal processing (DSP) chip, microcontroller unit (MCU), artificial intelligence processor, ASIC, SoC, FPGA, PLD, special purpose digital circuit, hardware accelerator or non-integrated discrete device, which can run necessary software or not rely on software to execute the above method flow.

[0178] The various modules / units included in the various apparatuses and products described in the above embodiments can be software modules / units or hardware modules / units, or partially software modules / units and partially hardware modules / units. For example, for the various apparatuses and products applied to or integrated in a chip, the various modules / units included therein can all be implemented in the form of hardware such as circuitry, or at least some of the modules / units can be implemented in the form of software program running on a processor integrated in the chip, and the rest (if any) of the modules / units can be implemented in the form of hardware such as circuitry; for the various apparatuses and products applied to or integrated in a chip module, the various modules / units included therein can all be implemented in the form of hardware such as circuitry, and different modules / units can be located in the same component (e.g., a chip, a circuit module, etc.) or different components of the chip module, or at least some of the modules / units can be implemented in the form of software program running on a processor integrated in the chip module, and the rest (if any) of the modules / units can be implemented in the form of hardware such as circuitry; for the various apparatuses and products applied to or integrated in a terminal, the various modules / units included therein can all be implemented in the form of hardware such as circuitry, and different modules / units can be located in the same component (e.g., a chip, a circuit module, etc.) or different components of the terminal, or at least some of the modules / units can be implemented in the form of software program running on a processor integrated in the terminal, and the rest (if any) of the modules / units can be implemented in the form of hardware such as circuitry.

[0179] The method steps in the embodiments of the present application can be implemented by hardware, or by a processor executing software instructions. The software instructions can be composed of corresponding software modules, which can be stored in a Random Access Memory (RAM), a flash memory, a Read-Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Programmable Read-Only Memory (EPROM), an Electrically Erasable Programmable Read-Only Memory (EEPROM), a register, a hard disk, a mobile hard disk, a CD-ROM, or any other form of storage medium well known in the art. An exemplary storage medium is coupled to the processor, such that the processor can read information from, and write information to, the storage medium. Of course, the storage medium can be a component of the processor. The processor and the storage medium can be located in an ASIC. The ASIC can be located in an access network device or a terminal. Of course, the processor and the storage medium can also be located in a discrete component in the access network device or the terminal.

[0180] In the above embodiments, all or part of the embodiments can be implemented by software, hardware, firmware or any combination thereof. When implemented by software, all or part of the embodiments can be implemented in the form of a computer program product. The computer program product includes one or more computer programs or instructions. When the computer programs or instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments are performed. The computer can be a general purpose computer, a special purpose computer, a computer network, an access network device, a user equipment or other programmable apparatus. The computer programs or instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer programs or instructions can be transferred from one website site, computer, server or data center to another website site, computer, server or data center through wired or wireless manner. The computer readable storage medium can be any available medium accessible by a computer or a data storage device such as a server, data center and the like integrated with one or more available media. The available media can be a magnetic medium, for example, a floppy disk, a hard disk, a magnetic tape; an optical medium, for example, a digital video disc; and a semiconductor medium, for example, a solid state disk.

[0181] In various embodiments of the present application, the terms and / or descriptions of different embodiments are consistent and can be referred to each other if there is no special description and logical conflict, and the technical features in different embodiments can be combined to form new embodiments according to their inherent logical relationship.

[0182] In the present application, "at least one" means one or more, and "multiple" means two or more. The "and / or" describes the association relationship between the associated objects, which means that there can be three kinds of relationships, for example, A and / or B, which can represent the following three cases: A exists alone, A and B exist together, and B exists alone, where A and B can be singular or plural. In the textual description of the present application, the character " / ", generally represents that the associated objects before and after are in an "or" relationship; in the formula of the present application, the character " / ", represents that the associated objects before and after are in a "division" relationship.

[0183] It can be understood that various numbers involved in the embodiments of the present application are only distinguished for convenience of description, and are not used to limit the scope of the embodiments of the present application. The size of the serial number of the above processes does not mean the order of execution, and the execution order of the processes should be determined according to its function and inherent logic.

Claims

1. A dynamic partitioned burn-in method, characterized in that, The method comprises: obtaining the total size of at least one system image data to be burned into a first system image file of at least one sub-logical partition of a dynamic partition, the format of the first system image file being a non-sparse matrix format, and the dynamic partition comprising a reserved space and the at least one sub-logical partition; writing information of the total size into header information of a second system image file, the second system image file being a sparse matrix format file of the first system image file; burning the at least one system image data in the first system image file into the at least one sub-logical partition according to the header information.

2. The method of claim 1, wherein, The method further comprises: obtaining the second system image file; obtaining the first system image file according to the second system image file; obtaining the size of the at least one system image data in the first system image file; obtaining the total size of the at least one system image data in the first system image file according to the size of the at least one system image data in the first system image file.

3. The method according to claim 1 or 2, characterized in that, The method further comprises: obtaining configuration information, the configuration information comprising the size of the dynamic partition; creating a physical partition of the dynamic partition according to the configuration information.

4. The method of claim 3, wherein, After the at least one system image data in the first system image file is burned into the at least one sub-logical partition according to the header information, the method further comprises: stopping transmission of all 0 data and filling the all 0 data into the reserved space; filling the all 0 data into the reserved space by a start-up program.

5. A dynamic partitioning method of burning, characterized by, The method comprises: obtaining a first system image file; obtaining a second system image file according to the first system image file, the format of the second system image file being a non-sparse matrix format, and the first system image file being a sparse matrix format file of the second system image file; obtaining at least one system image data in the second system image file; burning the at least one system image data into at least one sub-logical partition of a dynamic partition, the dynamic partition comprising a reserved space and the at least one sub-logical partition.

6. The method of claim 5, wherein, The method further comprises: obtaining a sub-logical partition information table, the sub-logical partition information table comprising address ranges of the at least one sub-logical partition; The method further comprises: obtaining at least one system image data corresponding to the address ranges of the at least one sub-logical partition in the second system image file according to the sub-logical partition information table.

7. The method according to claim 5 or 6, characterized in that, After the at least one system image data is burned into the at least one sub-logical partition, the method further comprises: stopping transmission of all 0 data and filling the all 0 data into the reserved space; filling the all 0 data into the reserved space by a start-up program.

8. A dynamic partitioned burning device, characterized by, The device comprises: The first obtaining unit is configured to obtain a total size of at least one system image data in a first system image file to be burned into at least one sub-logical partition of a dynamic partition, wherein the first system image file is in a non-sparse matrix format, and the dynamic partition comprises a reserved space and the at least one sub-logical partition; The writing unit is configured to write information of the total size into header information of a second system image file, wherein the second system image file is a sparse matrix format file of the first system image file; The burning unit is configured to burn the at least one system image data in the first system image file into the at least one sub-logical partition according to the header information.

9. The apparatus of claim 8, wherein, The first obtaining unit comprises: The second obtaining unit is configured to obtain the second system image file; The third obtaining unit is configured to obtain the first system image file according to the second system image file; The fourth obtaining unit is configured to obtain a size of the at least one system image data in the first system image file; The fifth obtaining unit is configured to obtain the total size of the at least one system image data in the first system image file according to the size of the at least one system image data in the first system image file.

10. The apparatus of claim 8 or 9, wherein, The device further comprises: The sixth obtaining unit is configured to obtain configuration information, wherein the configuration information comprises a size of the dynamic partition; The creating unit is configured to create a physical partition of the dynamic partition according to the configuration information.

11. The apparatus of claim 10, wherein, The device further comprises: The transmission unit is configured to stop transmitting all-0 data; The filling unit is configured to stop filling the all-0 data into the reserved space; The filling unit is further configured to fill the all-0 data into the reserved space by starting a boot program.

12. A dynamic partitioned burning device, characterized by, The device comprises: The first obtaining unit is configured to obtain a first system image file; The second obtaining unit is configured to obtain a second system image file according to the first system image file, wherein the second system image file is in a non-sparse matrix format, and the first system image file is a sparse matrix format file of the second system image file; The third obtaining unit is configured to obtain at least one system image data in the second system image file; The burning unit is configured to burn the at least one system image data into at least one sub-logical partition of a dynamic partition, wherein the dynamic partition comprises a reserved space and the at least one sub-logical partition.

13. The apparatus of claim 12, wherein, The device further comprises: The fourth obtaining unit is configured to obtain a sub-logical partition information table, wherein the sub-logical partition information table comprises an address range of the at least one sub-logical partition; The third obtaining unit is configured to obtain at least one system image data corresponding to the address range of the at least one sub-logical partition in the second system image file according to the sub-logical partition information table.

14. The apparatus of claim 12 or 13, wherein, The device further comprises: The transmission unit is configured to stop transmitting all-0 data; The filling unit is configured to stop filling the all-0 data into the reserved space; The filling unit is further configured to fill the all-0 data into the reserved space by starting a boot program.

15. A dynamic partitioned burning device, characterized by, A computer program product comprising a memory, a processor, and a computer program stored on the memory and loadable on the processor, characterized in that the processor implements the method of any one of claims 1-4 or the method of any one of claims 5-7 when executing the computer program.

16. A chip for use in a terminal, characterized in that The chip for implementing the method of any one of claims 1-4 or the method of any one of claims 5-7.

17. A chip module applied to a terminal, characterized by comprising: a chip module according to any one of claims 1 to 16; and a terminal body to which the chip module is attached. The transceiver assembly and the chip for implementing the method of any one of claims 1-4 or the method of any one of claims 5-7.

18. A computer-readable storage medium, characterized in that, The storage medium stores a computer program or instructions, and when the computer program or instructions are scheduled to be executed by the delay determination apparatus, the method of any one of claims 1-4 or the method of any one of claims 5-7 is implemented.

Citation Information

Patent Citations

  • Manufacturing and burning method and device of mirror image file, equipment and medium

    CN113377391A