WO2020223950A1 - Method, apparatus and device for preventing data loss and system damage of usb flash disk - Google Patents
Method, apparatus and device for preventing data loss and system damage of usb flash disk Download PDFInfo
- Publication number
- WO2020223950A1 WO2020223950A1 PCT/CN2019/086145 CN2019086145W WO2020223950A1 WO 2020223950 A1 WO2020223950 A1 WO 2020223950A1 CN 2019086145 W CN2019086145 W CN 2019086145W WO 2020223950 A1 WO2020223950 A1 WO 2020223950A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- data
- read
- storage space
- time programmable
- management table
- Prior art date
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
Definitions
- the present invention relates to the field of storage technology, in particular to a method, device and equipment for preventing data loss and system damage of a U disk.
- USB flash disk (USB flash disk) is composed of main control chip and NF (NAND Flash, NAND flash memory) memory.
- the main control chip passes through the Boot solidified in ROM (Read-Only Memory) Loader (boot loading) code loads the running code and algorithm management table data stored in NAND Flash into RAM (Random Access Memory, random access memory), and then run the code to execute in RAM random access memory.
- ROM Read-Only Memory
- Loader boot loading
- NAND Flash flash memory Due to the storage characteristics of NAND Flash flash memory, data errors may occur due to the storage environment, excessive storage time or abnormal power failure, Boot Loader boot loading may fail to load the running code or the algorithm management table data load fails. At this time, the U disk will lose the user's original data, or the U disk system may be damaged and unable to run.
- the purpose of the present invention is to provide a method, device and equipment for preventing data loss and system damage of a U disk, which can prevent the U disk from losing the user's original data or the U disk system is damaged and unable to run.
- a method for preventing data loss and system damage of a U disk which includes:
- the stored running code data is read from the one-time programmable storage space, and the running code data is restored based on the read running code data.
- Run code data read the stored original algorithm management table data from the one-time programmable storage space, and restore the original algorithm management table data according to the read original algorithm management table data Tabular data.
- the reading the stored running code data from the one-time programmable storage space and restoring the running code data according to the read running code data includes:
- the stored original algorithm management table data is read from the one-time programmable storage space, and the original algorithm management table data is restored according to the read original algorithm management table data.
- Data including:
- the read temporary mark is the mark of the loading table in the one-time programmable storage space, and after judging that the read temporary mark is the loading in the one-time programmable storage space
- the start address and data length of the associated original algorithm management table data in the one-time programmable storage space are read from the address corresponding to the temporary mark;
- the stored running code data is read from the one-time programmable storage space, and the running code data is read according to the read Code data, restore running code data, read the stored original algorithm management table data from the one-time programmable storage space, and manage the table data according to the read original algorithm, restore After the original algorithm management table data is released, it also includes:
- the boot load jumps to the restored running code data for execution, so that the U disk is successfully loaded.
- a device for preventing data loss and system damage of a U disk including:
- the memory is used to store running code and original algorithm management table data in the one-time programmable storage space
- the restorer is used to read the stored running code data from the one-time programmable storage space when the boot load normally loads the running code or the algorithm management table data fails, and reads out the running code data according to the read
- the operating code data is restored, the operating code data is restored, and the stored original algorithm management table data is read from the one-time programmable storage space, and the original algorithm management table data is read out according to the original algorithm , Restore the original algorithm management table data.
- the restorer is specifically used for:
- the restorer is specifically used for:
- the read temporary mark is the mark of the loading table in the one-time programmable storage space, and after judging that the read temporary mark is the loading in the one-time programmable storage space
- the start address and data length of the associated original algorithm management table data in the one-time programmable storage space are read from the address corresponding to the temporary mark;
- the device for preventing data loss and system damage of U disk further includes:
- the executor is used to make the boot loading jump to the restored running code data for execution, so that the U disk is successfully loaded.
- a device for preventing data loss and system damage of a U disk including:
- At least one processor and,
- a memory communicatively connected with the at least one processor; wherein,
- the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute any of the above-mentioned prevention of U disk data Methods of loss and system damage.
- a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the method for preventing data loss and system damage of a U disk as described in any one of the above items.
- one-time programmable OTP storage space can be added to the main control chip of the U disk, and the running code and original algorithm management table data can be stored in the one-time programmable OTP storage space.
- the boot loader fails to load the running code or the algorithm management table data normally, the stored running code data is read from the one-time programmable OTP storage space, and the running code data is restored based on the read running code data Code data, and read the stored original algorithm management table data from the one-time programmable OTP storage space, and restore the original algorithm management table data according to the read original algorithm management table data, It can prevent the U disk from losing the user's original data or the U disk system being damaged and unable to run.
- the stored running code data can be loaded from the one-time programmable OTP storage space
- the temporary flag TempFlag can be read from the first fixed offset address in the one-time programmable storage space
- the judgment Whether the read temporary flag TempFlag is equal to the flag TableFlg of the loading table in the one-time programmable OTP storage space, after judging that the read temporary flag TempFlag is equal to the loading in the one-time programmable OTP storage space When the table is marked with TableFlg, the start address Code_Add and the data length Code_Len of the associated running code in the one-time programmable OTP storage space are read from the address corresponding to the temporary mark TempFlag, and the start address Code_Add and the data length Code_Len are read from the address corresponding to the temporary mark TempFlag.
- Start address Code_Add and data length Code_Len read the running code data associated with the start address Code_Add and data length Code_Len from the one-time programmable OTP storage space, and until all fixed offsets in the one-time programmable storage space The running code data pointed to by the address is read out, and the running code data is restored based on the read running code data.
- the advantage of this is that the running code data can be restored to prevent the user's original data from appearing on the U disk. Lost or damaged U disk system cannot run, etc.
- the stored original algorithm management table data can be loaded from the one-time programmable OTP storage space, and the temporary flag TempFlag can be read from the first fixed offset address in the one-time programmable storage space. , And determine whether the read temporary flag TempFlag is equal to the tag TableFlg of the loading table in the one-time programmable OTP storage space, and determine whether the read temporary flag TempFlag is equal to the one-time programmable OTP storage space
- TableFlg When loading the table flag TableFlg in the table, read the associated original algorithm management table data starting address TableData_Add and data length TableData_Len in the one-time programmable OTP storage space from the address corresponding to the temporary flag TempFlag, and According to the read start address TableData_Add and data length TableData_Len, the original algorithm management table data associated with the start address TableData_Add and the data length TableData_Len is read from the one-time programmable OTP storage space, and until one time The original algorithm management table data pointed to by
- the above scheme can make the boot loader jump to the restored running code data and execute it, so that the U disk can be successfully loaded.
- This has the advantage of being able to load the Boot
- the Boot Loader can jump to the restored running code data to execute, so that the USB flash drive can be successfully loaded, and the USB flash drive can be restored to the normal state of use , To ensure the service life of the U disk.
- FIG. 1 is a schematic flowchart of an embodiment of a method for preventing U disk data loss and system damage according to the present invention
- FIG. 2 is a schematic diagram of an example of a one-time programmable OTP storage space in an embodiment of the method for preventing data loss and system damage in a U disk of the present invention
- FIG. 3 is a schematic diagram of another example of a one-time programmable OTP storage space in an embodiment of the method for preventing data loss and system damage in a U disk of the present invention
- FIG. 4 is a schematic diagram of another example of a one-time programmable OTP storage space in an embodiment of the method for preventing data loss and system damage in a U disk of the present invention
- FIG. 5 is a schematic flowchart of another embodiment of a method for preventing data loss and system damage in a U disk according to the present invention.
- FIG. 6 is a schematic structural diagram of an embodiment of a device for preventing U disk data loss and system damage according to the present invention.
- FIG. 7 is a schematic structural diagram of another embodiment of the device for preventing U disk data loss and system damage according to the present invention.
- Fig. 8 is a schematic structural diagram of another embodiment of the system for controlling the installation authority of application programs of the present invention.
- the invention provides a method for preventing U disk data loss and system damage, which can prevent the U disk from losing the user's original data or the U disk system is damaged and unable to run.
- FIG. 1 is a schematic flowchart of an embodiment of a method for preventing data loss and system damage of a U disk according to the present invention. It should be noted that, if there is substantially the same result, the method of the present invention is not limited to the sequence of the process shown in FIG. 1. As shown in Figure 1, the method includes the following steps:
- S102 Store the running code and the original algorithm management table data in the one-time programmable OTP storage space.
- reading the stored running code data from the one-time programmable OTP storage space, and restoring the running code data according to the read running code data may include:
- the advantage is that the running code can be restored by The data method can prevent the U disk from losing the user's original data or the U disk system is damaged and unable to run.
- the stored original algorithm management table data is read from the one-time programmable OTP storage space, and the original algorithm management table data read out is used to restore the original algorithm management table data.
- the stored running code data is read from the one-time programmable OTP storage space, and the running code read out is Data
- the running code data is restored
- the stored original algorithm management table data is read from the one-time programmable OTP storage space, and the original algorithm management table data read is restored to restore the original
- the algorithm manages the table data it can also include:
- a 1bit (binary digit, bit) data bus and an OTP with a total capacity of 16KB (Kilobyte) can be preferably used.
- a 1bit (binary digit, bit) data bus and an OTP with a total capacity of 16KB (Kilobyte) can be preferably used.
- the selection of the OTP type The present invention is not limited.
- the reading speed is slow.
- OTP data all 16KB OTP data will not be read out, but corresponding data will be loaded according to the range given by the OTP loading table.
- the OTP loading table format can be as follows:
- TableFlg represents the mark of the OTP loading table.
- the OTP loading table can be stored at the address aligned with 1KB of the OTP address.
- the Boot Loader code can read the length of 4Bytes from all 1KB aligned addresses of the OTP to determine whether there is a valid OTP loading table. If the correct TableFlg is read, the entire OTP loading table will continue to be read.
- Code_Add and Code_Len respectively represent the starting address and data length of the running code in the OTP. It should be noted that in the OTP loading table, TableData_Add and TableData_Len respectively represent the starting address and data length of the original algorithm management table in the OTP.
- OTP backup data can be composed of OTP loading table (OTP_TABLE), running code (Code) and original algorithm management table data (TableData).
- the running code and the original algorithm management table data can be updated multiple times in the 16KB OTP space, and the running code and the original algorithm management table data can be updated multiple times in the OTP.
- the running code and the original algorithm management table data can be updated multiple times in the OTP space through the OTP loading table, which can realize multiple updates of the running code and the original algorithm management table data in the OTP.
- the one-time programmable OTP storage space can be added to the main control chip of the U disk, and the running code and the original algorithm management table data can be stored in the one-time programmable OTP storage space , And when the boot loader fails to load the running code or the algorithm management table data normally, read the stored running code data from the one-time programmable OTP storage space, and according to the read running code data, Recover running code data, read the stored original algorithm management table data from the one-time programmable OTP storage space, and restore the original algorithm management table data according to the read original algorithm management table data
- the table data can prevent the U disk from losing the user's original data or the U disk system is damaged and unable to run.
- the stored running code data can be loaded from the one-time programmable OTP storage space, and the temporary flag TempFlag can be read from the first fixed offset address in the one-time programmable storage space.
- the temporary flag TempFlag can be read from the first fixed offset address in the one-time programmable storage space.
- determine whether the read temporary flag TempFlag is equal to the tag TableFlg of the loading table in the one-time programmable OTP storage space determine whether the read temporary flag TempFlag is equal to the one-time programmable OTP storage space
- the table flag TableFlg in the table read the start address Code_Add and the data length Code_Len of the associated running code in the one-time programmable OTP storage space from the address corresponding to the temporary flag TempFlag, and read according to the Start address Code_Add and data length Code_Len, read the running code data associated with the start address Code_Add and data length Code_Len from the one-time programmable OTP storage space, and until all the data in
- the stored original algorithm management table data can be loaded from the one-time programmable OTP storage space, and read from the first fixed offset address in the one-time programmable storage space Temporary flag TempFlag, and judging whether the read temporary flag TempFlag is equal to the label TableFlg of the loading table in the one-time programmable OTP storage space, after judging that the read temporary flag TempFlag is equal to the one-time programmable
- the stored original algorithm management table data can be loaded from the one-time programmable OTP storage space, and read from the first fixed offset address in the one-time programmable storage space Temporary flag TempFlag, and judging whether the read temporary flag TempFlag is equal to the label TableFlg of the loading table in the one-time programmable OTP storage space, after judging that the read temporary flag TempFlag is equal to the one-time programmable
- TableData_Add the starting address TableData_Add and the data length in the one-time programmable OTP storage space
- FIG. 2 is a schematic diagram of an example of a one-time programmable OTP storage space in an embodiment of a method for preventing data loss and system damage of a U disk according to the present invention.
- OTP_TABLE (1, 1) indicates that the OTP_TABLE points to Code (1) and TableData (1).
- FIG. 3 is a schematic diagram of another example of a one-time programmable OTP storage space in an embodiment of a method for preventing data loss and system damage in a U disk of the present invention.
- the current running code Code (1) needs to be updated to Code (2)
- the 1KB aligned address in OTP here is the nKB address.
- FIG. 4 is a schematic diagram of another example of a one-time programmable OTP storage space in an embodiment of the method for preventing data loss and system damage of a U disk according to the present invention.
- TableData(1) needs to be updated to TableData(2)
- FIG. 5 is a schematic flowchart of another embodiment of a method for preventing data loss and system damage of a U disk according to the present invention.
- the method includes the following steps:
- S501 Add one-time programmable OTP storage space to the main control chip of the U disk.
- S502 Store the running code and the original algorithm management table data in the one-time programmable OTP storage space.
- the boot loader can be made to jump to the restored running code data for execution, so that the U disk can be successfully loaded.
- This has the advantage of being able to load the Boot loader during the boot
- the Boot Loader can jump to the restored running code data to execute, so that the USB flash drive can be successfully loaded, and the USB flash drive can be restored to the normal state of use , To ensure the service life of the U disk.
- the invention also provides a device for preventing U disk data loss and system damage, which can prevent the U disk from losing the user's original data or the U disk system is damaged and unable to run.
- FIG. 6 is a schematic structural diagram of an embodiment of a device for preventing U disk data loss and system damage according to the present invention.
- the device 60 for preventing U disk data loss and system damage includes a memory 61 and a restorer 62.
- the memory 61 is used to store the running code and the original algorithm management table data in the one-time programmable OTP storage space.
- the restorer 62 is used to read the stored operating code data from the one-time programmable OTP storage space when the boot loader normally loads the operating code or the algorithm management table data fails, and reads the stored operating code data according to the read.
- the operating code data is restored, and the stored original algorithm management table data is read from the one-time programmable OTP storage space, and the original algorithm management table data is restored according to the read original algorithm.
- the original algorithm is used to manage tabular data.
- the restorer 62 may be specifically used for:
- the restorer 62 may be specifically used for:
- FIG. 7 is a schematic structural diagram of another embodiment of a device for preventing data loss and system damage of a U disk according to the present invention.
- the device 70 for preventing U disk data loss and system damage described in this embodiment further includes an actuator 71.
- the executor 71 is used to make the boot loader jump to the restored running code data for execution, so that the U disk is successfully loaded.
- Each unit module of the device 60/70 for preventing U disk data loss and system damage can execute the corresponding steps in the above method embodiment, so each unit module will not be repeated here.
- each unit module will not be repeated here.
- the present invention also provides a device for preventing U disk data loss and system damage, as shown in FIG. 8, comprising: at least one processor 81; and a memory 82 communicatively connected with the at least one processor 81; wherein the memory 82 stores There are instructions that can be executed by at least one processor 81, and the instructions are executed by at least one processor 81, so that at least one processor 81 can execute the above-mentioned method for preventing U disk data loss and system damage.
- the memory 82 and the processor 81 are connected in a bus manner.
- the bus may include any number of interconnected buses and bridges, and the bus connects one or more various circuits of the processor 81 and the memory 82 together.
- the bus can also connect various other circuits such as peripheral devices, voltage regulators, power management circuits, etc., which are all well-known in the art, and therefore, no further description will be given herein.
- the bus interface provides an interface between the bus and the transceiver.
- the transceiver may be one element or multiple elements, such as multiple receivers and transmitters, providing a unit for communicating with various other devices on the transmission medium.
- the data processed by the processor 81 is transmitted on the wireless medium through the antenna, and further, the antenna also receives the data and transmits the data to the processor 81.
- the processor 81 is responsible for managing the bus and general processing, and can also provide various functions, including timing, peripheral interfaces, voltage regulation, power management, and other control functions.
- the memory 82 may be used to store data used by the processor 81 when performing operations.
- the present invention further provides a computer-readable storage medium storing a computer program.
- the computer program is executed by the processor, the above method embodiment is realized.
- one-time programmable OTP storage space can be added to the main control chip of the U disk, and the running code and original algorithm management table data can be stored in the one-time programmable OTP storage space.
- the boot loader fails to load the running code or the algorithm management table data normally, the stored running code data is read from the one-time programmable OTP storage space, and the running code data is restored based on the read running code data Code data, and read the stored original algorithm management table data from the one-time programmable OTP storage space, and restore the original algorithm management table data according to the read original algorithm management table data, It can prevent the U disk from losing the user's original data or the U disk system being damaged and unable to run.
- the stored running code data can be loaded from the one-time programmable OTP storage space
- the temporary flag TempFlag can be read from the first fixed offset address in the one-time programmable storage space
- the judgment Whether the read temporary flag TempFlag is equal to the flag TableFlg of the loading table in the one-time programmable OTP storage space, after judging that the read temporary flag TempFlag is equal to the loading in the one-time programmable OTP storage space When the table is marked with TableFlg, the start address Code_Add and the data length Code_Len of the associated running code in the one-time programmable OTP storage space are read from the address corresponding to the temporary mark TempFlag, and the start address Code_Add and the data length Code_Len are read from the address corresponding to the temporary mark TempFlag.
- Start address Code_Add and data length Code_Len read the running code data associated with the start address Code_Add and data length Code_Len from the one-time programmable OTP storage space, and until all fixed offsets in the one-time programmable storage space The running code data pointed to by the address is read out, and the running code data is restored based on the read running code data.
- the advantage of this is that the running code data can be restored to prevent the user's original data from appearing on the U disk. Lost or damaged U disk system cannot run, etc.
- the stored original algorithm management table data can be loaded from the one-time programmable OTP storage space, and the temporary flag TempFlag can be read from the first fixed offset address in the one-time programmable storage space. , And determine whether the read temporary flag TempFlag is equal to the tag TableFlg of the loading table in the one-time programmable OTP storage space, and determine whether the read temporary flag TempFlag is equal to the one-time programmable OTP storage space
- TableFlg When loading the table flag TableFlg in the table, read the associated original algorithm management table data starting address TableData_Add and data length TableData_Len in the one-time programmable OTP storage space from the address corresponding to the temporary flag TempFlag, and According to the read start address TableData_Add and data length TableData_Len, the original algorithm management table data associated with the start address TableData_Add and the data length TableData_Len is read from the one-time programmable OTP storage space, and until one time The original algorithm management table data pointed to by
- the above scheme can make the boot loader jump to the restored running code data and execute it, so that the U disk can be successfully loaded.
- This has the advantage of being able to load the Boot
- the Boot Loader can jump to the restored running code data to execute, so that the USB flash drive can be successfully loaded, and the USB flash drive can be restored to the normal state of use , To ensure the service life of the U disk.
- the disclosed system, device, and method may be implemented in other ways.
- the device implementation described above is merely illustrative, for example, the division of modules or units is only a logical function division, and there may be other divisions in actual implementation, for example, multiple units or components can be combined or It can be integrated into another system, or some features can be ignored or not implemented.
- the displayed or discussed mutual coupling or direct coupling or communication connection may be indirect coupling or communication connection through some interfaces, devices or units, and may be in electrical, mechanical or other forms.
- the units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the objectives of the solutions of this embodiment.
- the functional units in the various embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units may be integrated into one unit.
- the above-mentioned integrated unit can be implemented in the form of hardware or software functional unit.
- the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer readable storage medium.
- the technical solution of the present invention essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium , Including several instructions to make a computer device (which can be a personal computer, a server, or a network device, etc.) or a processor execute all or part of the steps of the methods of the various embodiments of the present invention.
- the aforementioned storage media include: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disk or optical disk and other media that can store program code .
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Techniques For Improving Reliability Of Storages (AREA)
Abstract
Description
Claims (10)
- 一种防止U盘数据丢失和系统损坏的方法,其特征在于,包括:A method for preventing U disk data loss and system damage, characterized in that it includes:在U盘的主控芯片中加入一次性可编程存储空间;Add one-time programmable storage space to the main control chip of the U disk;将运行代码和原始的算法管理表格数据存储在所述一次性可编程存储空间中;Storing running code and original algorithm management table data in the one-time programmable storage space;在引导加载正常加载运行代码或算法管理表格数据失败时,从所述一次性可编程存储空间中读取出所述存储的运行代码数据,并根据所述读取出的运行代码数据,恢复出运行代码数据,和从所述一次性可编程存储空间中读取出所述存储的原始的算法管理表格数据,并根据所述读取出的原始的算法管理表格数据,恢复出原始的算法管理表格数据。When the boot load fails to load the running code or the algorithm management table data normally, the stored running code data is read from the one-time programmable storage space, and the running code data is restored based on the read running code data. Run code data, read the stored original algorithm management table data from the one-time programmable storage space, and restore the original algorithm management table data according to the read original algorithm management table data Tabular data.
- 如权利要求1所述的防止U盘数据丢失和系统损坏的方法,其特征在于,所述从所述一次性可编程存储空间中读取出所述存储的运行代码数据,并根据所述读取出的运行代码数据,恢复出运行代码数据,包括:The method for preventing U disk data loss and system damage according to claim 1, characterized in that, the stored running code data is read from the one-time programmable storage space, and according to the read The running code data taken out, the running code data is restored, including:从所述一次性可编程存储空间中加载所述存储的运行代码数据;Loading the stored running code data from the one-time programmable storage space;从所述一次性可编程存储空间中的第一个固定偏移地址读出临时标记;Reading out the temporary mark from the first fixed offset address in the one-time programmable storage space;判断所述读取出的临时标记是否于所述一次性可编程存储空间中的加载表格的标记,在判断出所述读取出的临时标记是于所述一次性可编程存储空间中的加载表格的标记时,从对应所述临时标记的地址处读取出关联的运行代码在所述一次性可编程存储空间中的起始地址和数据长度;It is judged whether the read temporary mark is the mark of the loading table in the one-time programmable storage space, and after judging that the read temporary mark is the loading in the one-time programmable storage space When the table is marked, the start address and data length of the associated running code in the one-time programmable storage space are read from the address corresponding to the temporary mark;根据所述读取出的起始地址和数据长度,从所述一次性可编程存储空间中读取出关联所述起始地址和数据长度的运行代码数据;Read out the running code data associated with the start address and the data length from the one-time programmable storage space according to the read start address and data length;直到在一次性可编程存储空间中所有固定偏移地址指向的运行代码数据被读出,并根据所述读取出的运行代码数据,恢复出运行代码数据。Until all the running code data pointed to by the fixed offset address in the one-time programmable storage space are read, and the running code data is restored according to the read running code data.
- 如权利要求1所述的防止U盘数据丢失和系统损坏的方法,其特征在于,所述从所述一次性可编程存储空间中读取出所述存储的原始的算法管理表格数据,并根据所述读取出的原始的算法管理表格数据,恢复出原始的算法管理表格数据,包括:The method for preventing U disk data loss and system damage according to claim 1, wherein the stored original algorithm management table data is read from the one-time programmable storage space, and the data is managed according to The original algorithm management table data read out and the original algorithm management table data are restored, including:从所述一次性可编程存储空间中加载所述存储的原始的算法管理表格数据;Loading the stored original algorithm management table data from the one-time programmable storage space;从所述一次性可编程存储空间中的第一个固定偏移地址读出临时标记;Reading out the temporary mark from the first fixed offset address in the one-time programmable storage space;判断所述读取出的临时标记是否于所述一次性可编程存储空间中的加载表格的标记,在判断出所述读取出的临时标记是于所述一次性可编程存储空间中的加载表格的标记时,从对应所述临时标记的地址处读取出关联的原始的算法管理表格数据在所述一次性可编程存储空间中的起始地址和数据长度;It is judged whether the read temporary mark is the mark of the loading table in the one-time programmable storage space, and after judging that the read temporary mark is the loading in the one-time programmable storage space When the table is marked, the start address and data length of the associated original algorithm management table data in the one-time programmable storage space are read from the address corresponding to the temporary mark;根据所述读取出的起始地址和数据长度,从所述一次性可编程存储空间中读取出关联所述起始地址和数据长度的原始的算法管理表格数据;According to the read start address and data length, read out the original algorithm management table data associated with the start address and data length from the one-time programmable storage space;直到在一次性可编程存储空间中所有固定偏移地址指向的原始的算法管理表格数据被读出,并根据所述读取出的原始的算法管理表格数据,恢复出原始的算法管理表格数据。Until all the original algorithm management table data pointed to by the fixed offset address in the one-time programmable storage space are read, and the original algorithm management table data is restored according to the read original algorithm management table data.
- 如权利要求1所述的防止U盘数据丢失和系统损坏的方法,其特征在于,在所述在引导加载正常加载运行代码或算法管理表格数据失败时,从所述一次性可编程存储空间中读取出所述存储的运行代码数据,并根据所述读取出的运行代码数据,恢复出运行代码数据,和从所述一次性可编程存储空间中读取出所述存储的原始的算法管理表格数据,并根据所述读取出的原始的算法管理表格数据,恢复出原始的算法管理表格数据之后,还包括:The method for preventing U disk data loss and system damage according to claim 1, wherein when the boot loading fails to load the running code or the algorithm management table data normally, the one-time programmable storage space Read the stored operating code data, restore the operating code data based on the read operating code data, and read the stored original algorithm from the one-time programmable storage space Manage the table data, and manage the table data according to the read original algorithm management table data. After the original algorithm management table data is restored, it also includes:使引导加载跳转到所述恢复出的运行代码数据中执行,让U盘上盘成功。The boot load jumps to the restored running code data for execution, so that the U disk is successfully loaded.
- 一种防止U盘数据丢失和系统损坏的装置,其特征在于,包括:A device for preventing U disk data loss and system damage is characterized in that it includes:存储器和恢复器;Storage and restorer;所述存储器,用于将运行代码和原始的算法管理表格数据存储在所述一次性可编程存储空间中;The memory is used to store running code and original algorithm management table data in the one-time programmable storage space;所述恢复器,用于在引导加载正常加载运行代码或算法管理表格数据失败时,从所述一次性可编程存储空间中读取出所述存储的运行代码数据,并根据所述读取出的运行代码数据,恢复出运行代码数据,和从所述一次性可编程存储空间中读取出所述存储的原始的算法管理表格数据,并根据所述读取出的原始的算法管理表格数据,恢复出原始的算法管理表格数据。The restorer is used to read the stored running code data from the one-time programmable storage space when the boot load normally loads the running code or the algorithm management table data fails, and reads out the running code data according to the read The operating code data is restored, the operating code data is restored, and the stored original algorithm management table data is read from the one-time programmable storage space, and the original algorithm management table data is read out according to the original algorithm , Restore the original algorithm management table data.
- 如权利要求5所述的防止U盘数据丢失和系统损坏的装置,其特征在于,所述恢复器,具体用于:The device for preventing U disk data loss and system damage according to claim 5, wherein the restorer is specifically used for:从所述一次性可编程存储空间中加载所述存储的运行代码数据;Loading the stored running code data from the one-time programmable storage space;从所述一次性可编程存储空间中的第一个固定偏移地址读出临时标记;Reading out the temporary mark from the first fixed offset address in the one-time programmable storage space;判断所述读取出的临时标记是否于所述一次性可编程存储空间中的加载表格的标记,在判断出所述读取出的临时标记是于所述一次性可编程存储空间中的加载表格的标记时,从对应所述临时标记的地址处读取出关联的运行代码在所述一次性可编程存储空间中的起始地址和数据长度;It is judged whether the read temporary mark is the mark of the loading table in the one-time programmable storage space, and after judging that the read temporary mark is the loading in the one-time programmable storage space When the table is marked, the start address and data length of the associated running code in the one-time programmable storage space are read from the address corresponding to the temporary mark;根据所述读取出的起始地址和数据长度,从所述一次性可编程存储空间中读取出关联所述起始地址和数据长度的运行代码数据;Read out the running code data associated with the start address and the data length from the one-time programmable storage space according to the read start address and data length;直到在一次性可编程存储空间中所有固定偏移地址指向的运行代码数据被读出,并根据所述读取出的运行代码数据,恢复出运行代码数据。Until all the running code data pointed to by the fixed offset address in the one-time programmable storage space are read, and the running code data is restored according to the read running code data.
- 如权利要求5所述的防止U盘数据丢失和系统损坏的装置,其特征在于,所述恢复器,具体用于:The device for preventing U disk data loss and system damage according to claim 5, wherein the restorer is specifically used for:从所述一次性可编程存储空间中加载所述存储的原始的算法管理表格数据;Loading the stored original algorithm management table data from the one-time programmable storage space;从所述一次性可编程存储空间中的第一个固定偏移地址读出临时标记;Reading out the temporary mark from the first fixed offset address in the one-time programmable storage space;判断所述读取出的临时标记是否于所述一次性可编程存储空间中的加载表格的标记,在判断出所述读取出的临时标记是于所述一次性可编程存储空间中的加载表格的标记时,从对应所述临时标记的地址处读取出关联的原始的算法管理表格数据在所述一次性可编程存储空间中的起始地址和数据长度;It is judged whether the read temporary mark is the mark of the loading table in the one-time programmable storage space, and after judging that the read temporary mark is the loading in the one-time programmable storage space When the table is marked, the start address and data length of the associated original algorithm management table data in the one-time programmable storage space are read from the address corresponding to the temporary mark;根据所述读取出的起始地址和数据长度,从所述一次性可编程存储空间中读取出关联所述起始地址和数据长度的原始的算法管理表格数据;According to the read start address and data length, read out the original algorithm management table data associated with the start address and data length from the one-time programmable storage space;直到在一次性可编程存储空间中所有固定偏移地址指向的原始的算法管理表格数据被读出,并根据所述读取出的原始的算法管理表格数据,恢复出原始的算法管理表格数据。Until all the original algorithm management table data pointed to by the fixed offset address in the one-time programmable storage space are read, and the original algorithm management table data is restored according to the read original algorithm management table data.
- 如权利要求5所述的防止U盘数据丢失和系统损坏的装置,其特征在于,所述防止U盘数据丢失和系统损坏的装置,还包括:The device for preventing data loss and system damage of a U disk according to claim 5, wherein the device for preventing data loss and system damage of a U disk further comprises:执行器,用于使引导加载跳转到所述恢复出的运行代码数据中执行,让U盘上盘成功。The executor is used to make the boot loading jump to the restored running code data for execution, so that the U disk is successfully loaded.
- 一种防止U盘数据丢失和系统损坏的设备,其特征在于,包括:A device for preventing U disk data loss and system damage is characterized in that it includes:至少一个处理器;以及,At least one processor; and,与所述至少一个处理器通信连接的存储器;其中,A memory communicatively connected with the at least one processor; wherein,所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行如权利要求1至4中任一项所述的防止U盘数据丢失和系统损坏的方法。The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute any one of claims 1 to 4 The method described to prevent data loss and system damage of U disk.
- 一种计算机可读存储介质,存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现权利要求1至4中任一项所述的防止U盘数据丢失和系统损坏的方法。A computer-readable storage medium storing a computer program, wherein the computer program implements the method for preventing data loss and system damage of a U disk according to any one of claims 1 to 4 when the computer program is executed by a processor.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/CN2019/086145 WO2020223950A1 (en) | 2019-05-09 | 2019-05-09 | Method, apparatus and device for preventing data loss and system damage of usb flash disk |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/CN2019/086145 WO2020223950A1 (en) | 2019-05-09 | 2019-05-09 | Method, apparatus and device for preventing data loss and system damage of usb flash disk |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2020223950A1 true WO2020223950A1 (en) | 2020-11-12 |
Family
ID=73051274
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2019/086145 WO2020223950A1 (en) | 2019-05-09 | 2019-05-09 | Method, apparatus and device for preventing data loss and system damage of usb flash disk |
Country Status (1)
Country | Link |
---|---|
WO (1) | WO2020223950A1 (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103279705A (en) * | 2013-05-14 | 2013-09-04 | 上海华为技术有限公司 | Validation method and validation device of chip with secure booting function |
US20150067313A1 (en) * | 2013-08-30 | 2015-03-05 | Asim A. Zaidi | Systems and methods for secure boot rom patch |
CN104981778A (en) * | 2013-02-22 | 2015-10-14 | 马维尔国际贸易有限公司 | Patching boot code of read-only memory |
-
2019
- 2019-05-09 WO PCT/CN2019/086145 patent/WO2020223950A1/en active Application Filing
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104981778A (en) * | 2013-02-22 | 2015-10-14 | 马维尔国际贸易有限公司 | Patching boot code of read-only memory |
CN103279705A (en) * | 2013-05-14 | 2013-09-04 | 上海华为技术有限公司 | Validation method and validation device of chip with secure booting function |
US20150067313A1 (en) * | 2013-08-30 | 2015-03-05 | Asim A. Zaidi | Systems and methods for secure boot rom patch |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP3233079B2 (en) | Data processing system and data processing method | |
US20070055969A1 (en) | System and method for updating firmware | |
US8812910B2 (en) | Pilot process method for system boot and associated apparatus | |
CN109032632B (en) | FOTA upgrading method, wireless communication terminal and storage medium | |
WO2011024688A1 (en) | Firmware update system, and information apparatus, as well as program | |
US20090094450A1 (en) | Firmware image update and management | |
CN113626256B (en) | Virtual machine disk data backup method, device, terminal and storage medium | |
CN109062600B (en) | Method and system for realizing online upgrade of firmware in solid state disk | |
JP2004234052A (en) | Storage device | |
US10235048B2 (en) | Data processing method and smart device | |
CN101373433A (en) | Method for updating BIOS and computer and system using the same | |
CN107566169A (en) | A kind of firmware upgrade method and router based on openwrt | |
US7257030B2 (en) | Operating a storage component | |
WO2020223950A1 (en) | Method, apparatus and device for preventing data loss and system damage of usb flash disk | |
CN110333967B (en) | Method, device and equipment for preventing USB flash disk data loss and system damage | |
CN107422987B (en) | Method and device for storing data in nonvolatile memory | |
JP7004033B1 (en) | Storage equipment, storage systems, control methods and programs | |
JP3620478B2 (en) | Storage device, data processing system using the storage device, and data read method | |
JP3376331B2 (en) | Storage method using flash memory and storage medium storing storage control program | |
CN115562593A (en) | Abnormal RAID member disk processing method, device and medium | |
JP4127307B2 (en) | Data storage device, data processing system, data processing method, and data processing device | |
CN112905112B (en) | Data processing method and system of embedded equipment | |
CN110554934B (en) | Embedded equipment and system partitioning and upgrading method thereof | |
CN110321073B (en) | Data storage method, device and equipment of flash memory | |
CN102023906A (en) | Microprocessor of portable terminal as well as portable terminal and repair method thereof |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 19927621 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 19927621 Country of ref document: EP Kind code of ref document: A1 |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 19927621 Country of ref document: EP Kind code of ref document: A1 |
|
32PN | Ep: public notification in the ep bulletin as address of the adressee cannot be established |
Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 200722) |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 19927621 Country of ref document: EP Kind code of ref document: A1 |