Data storage method and device, data reading method and device and electronic equipment

By using storage mapping information to directly read data from logical units when storing and reading data in a computer system, the problem of insufficient data reading flexibility and convenience in the existing technology is solved, and the security and safety of the system are improved. performance.

CN118535229APending Publication Date: 2024-08-23BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410612551.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-16
Publication Date
2024-08-23

AI Technical Summary

Technical Problem

Existing computer systems lack flexibility and convenience when reading data and need to operate through the file system or abstraction layer, which limits the directness and speed of data reading.

Method used

By obtaining multiple key data of the target device and storing it in the logical unit, storage mapping information is generated, so that after the operating system is started, the data can be read directly from the logical unit based on the storage mapping information, avoiding going through the file system or abstraction layer. .

Benefits of technology

It improves the flexibility and convenience of data access, increases data security by indirectly storing mapping information, and improves the security performance of the target device.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118535229A
    Figure CN118535229A
Patent Text Reader

Abstract

The invention relates to the technical field of computers, in particular to the technical fields of data management, information technologies and the like, and particularly relates to a data storage method, a data reading method, a data storage device, a data reading device and electronic equipment. According to the specific implementation scheme, multiple pieces of key data of target equipment are acquired; storing the plurality of pieces of key data in a logic unit; based on the storage mode of each piece of key data in the multiple pieces of key data in the logic unit, storage mapping information is generated; wherein the storage mapping information is used for enabling the target equipment to read the first target data from the multiple pieces of key data stored in the logic unit based on the storage mapping information after the operation system is started. According to the invention, the flexibility and convenience of data reading can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of computer technology, in particular to technical fields such as data management and information technology, and specifically to a data storage method, a data reading method, a device and an electronic device. Background Art

[0002] In existing computer systems, file contents are usually stored in the non-volatile memory of electronic devices and loaded into the memory of electronic devices after the operating system of the electronic devices is started. However, the traditional way of reading data is to read file contents through the file system or other abstract layers. Although this design ensures the stability and security of the computer system, it lacks flexibility and convenience in data reading. Summary of the invention

[0003] The present disclosure provides a data storage method, a data reading method, a device and an electronic device.

[0004] According to a first aspect of the present disclosure, a data storage method is provided, which is applied to a target device, wherein the target device includes a programmable device having a logic unit; the data storage method includes:

[0005] Obtain multiple key data of the target device;

[0006] Store multiple pieces of critical data in logical units;

[0007] Based on the storage method of each key data in the logical unit, storage mapping information is generated; wherein the storage mapping information is used to enable the target device to read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started.

[0008] According to a second aspect of the present disclosure, a data reading method is provided, which is applied to a target device, wherein the target device includes a programmable device having a logic unit, wherein the logic unit stores multiple key data of the target device, and the target device is used to generate storage mapping information based on the storage mode of each key data in the multiple key data in the logic unit; the data reading method includes:

[0009] When the operating system of the target device is started, the first target data is read from the plurality of key data stored in the logical unit based on the storage mapping information.

[0010] According to a third aspect of the present disclosure, a data storage device is provided for use in a target device, the target device comprising a programmable device having a logic unit; the data storage device comprises:

[0011] A data acquisition unit, used to acquire multiple key data of a target device;

[0012] A data storage unit, used to store multiple key data in a logical unit;

[0013] An information generation unit is used to generate storage mapping information based on the storage method of each key data in the logical unit among the multiple key data; wherein the storage mapping information is used to enable the target device to read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started.

[0014] According to a fourth aspect of the present disclosure, a data reading device is provided, which is applied to a target device, wherein the target device includes a programmable device having a logic unit, wherein the logic unit stores a plurality of key data of the target device, and the target device is used to generate storage mapping information based on a storage method of each of the plurality of key data in the logic unit; the data reading device includes:

[0015] The data reading unit is used to read the first target data from the multiple key data stored in the logic unit based on the storage mapping information when the operating system of the target device is started.

[0016] According to a fifth aspect of the present disclosure, there is provided an electronic device, including:

[0017] at least one processor;

[0018] a memory communicatively coupled to the at least one processor;

[0019] 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 to enable the at least one processor to execute any method provided by the embodiments of the present disclosure.

[0020] According to a sixth aspect of the present disclosure, a non-transitory computer-readable storage medium storing computer instructions is provided, wherein the computer instructions are used to enable the computer to execute any method provided by the embodiments of the present disclosure.

[0021] According to a seventh aspect of the present disclosure, a computer program product is provided, including a computer program, which implements any method provided by the embodiments of the present disclosure when executed by a processor.

[0022] The present disclosure can improve the flexibility and convenience of data access.

[0023] It should be understood that the content described in this section is not intended to identify the key or important features of the embodiments of the present disclosure, nor is it intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] The accompanying drawings are used to better understand the present solution and do not constitute a limitation of the present disclosure.

[0025] Figure 1 A schematic diagram of a flow chart of a first data storage method provided in an embodiment of the present disclosure;

[0026] Figure 2A A schematic diagram of the structure of a target device provided by an embodiment of the present disclosure;

[0027] Figure 2B An auxiliary illustration of a process of reading first target data provided by an embodiment of the present disclosure;

[0028] Figure 3 A schematic diagram of a flow chart of a second data storage method provided in an embodiment of the present disclosure;

[0029] Figure 4 A schematic diagram of a flow chart of a third data storage method provided in an embodiment of the present disclosure;

[0030] Figure 5 A flowchart of a data reading method provided by an embodiment of the present disclosure;

[0031] Figure 6 A complete flow chart of a data storage method provided by an embodiment of the present disclosure;

[0032] Figure 7 A complete flow chart of a data reading method provided by an embodiment of the present disclosure;

[0033] Fig. 8A A schematic diagram of a scenario of a data storage method provided by an embodiment of the present disclosure;

[0034] Figure 8B A schematic diagram of a scenario of a data reading method provided by an embodiment of the present disclosure;

[0035] Fig. 9 A structural schematic diagram of a data storage device provided in an embodiment of the present disclosure;

[0036] Fig.10 A structural schematic diagram of a data reading device provided in an embodiment of the present disclosure;

[0037] Fig.11 A schematic structural block diagram of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0038] The following is a description of exemplary embodiments of the present disclosure in conjunction with the accompanying drawings, including various details of the embodiments of the present disclosure to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope of the present disclosure. Similarly, for the sake of clarity and conciseness, the description of well-known functions and structures is omitted in the following description.

[0039] As mentioned above, in existing computer systems, file contents are usually stored in a non-volatile memory of an electronic device and loaded into a memory of the electronic device after the operating system of the electronic device is started.

[0040] Exemplarily, the electronic device includes a programmable device, which is a field programmable gate array (FPGA) developed based on Xilinx's fully programmable system on chip (Zynq-7000 All Programmable SoC, ZYNQ) or multi-processor system (Multi-Processor System on Chip, MPSOC), and the programmable device includes a logic unit (FPGA Logic) and a system unit (FPGA System). Among them, the logic unit is used to complete data operations, such as camera data decompression, global positioning system (Global Positioning System, GPS) related data processing, peripheral component interconnect Express (Peripheral Component Interconnect Express, PCIE) related data processing, etc.; the system unit is used to complete the loading and operation of the operating system, and conventional applications are run in the system unit.

[0041] Furthermore, the system unit includes the following three parts:

[0042] (1) Bootloader, used to boot the system;

[0043] (2) The kernel of the operating system;

[0044] (3) File System

[0045] The system firmware of the operating system is stored in a non-volatile memory, such as a memory device (Flash memory), an embedded flash memory (Embedded Multi-Media Card, EMMC), etc.

[0046] At present, after the operating system of an electronic device is started, the file system is initialized, the file content is read from the non-volatile memory to the memory, and then the file content is read through the file system or other abstract layers. In this process, on the one hand, the physical addresses of the file content stored in the memory are not continuous; on the other hand, it is also because the traditional data reading method itself limits the application program (for example, system software and user-installed applications) to read the file content directly through the physical address. Ultimately, the operating system can only read the file content through the file system or other abstract layers. Although this design ensures the stability and security of the computer system, it lacks flexibility and convenience in data reading.

[0047] Based on the above background, the embodiments of the present disclosure provide a first data storage method, which can be applied to electronic devices, for example, the target device mentioned in the embodiments of the present disclosure. Among them, the target device can be various forms of terminal devices, and the terminal device can be a conventional computer (for example, a desktop computer, a laptop computer, a car computer, etc.), a personal digital processing, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing devices. Further, in the embodiments of the present disclosure, the target device includes a programmable device with a logic unit, for example, an FPGA developed based on Xilinx's ZYNQ or MPSOC.

[0048] The following will be combined Figure 1 The flowchart diagram shown is used to illustrate the first data storage method provided by the embodiment of the present disclosure. It should be noted that although the logical order is shown in the flowchart diagram, in some cases, the steps shown or described may also be performed in other orders.

[0049] Step S101, obtaining multiple key data of the target device.

[0050] The plurality of key data may include key system software data and / or key additional application data. Here, the system software data may be data related to the system software; and the additional application data may be data related to an application program installed by the user.

[0051] In addition, in the embodiments of the present disclosure, multiple key data of the target device can be obtained when the target device is first enabled, initialized or powered on.

[0052] Step S102: storing multiple key data in a logical unit.

[0053] In the disclosed embodiment, multiple pieces of key data may be stored in a plurality of data storage spaces in a logical unit in a one-to-one correspondence.

[0054] Please combine Figure 2A, the target device includes a programmable device having a logic unit and a system unit, and the system unit may include a boot loader part, a kernel of an operating system, and a file system. Exemplarily, the plurality of key data include key data A1, key data A2, and key data A3, then, the key data A1 may be stored in a data storage space B1 in the logic unit, the key data A2 may be stored in a data storage space B2 in the logic unit, and the key data A3 may be stored in a data storage space B3 in the logic unit.

[0055] Step S103: Generate storage mapping information based on the storage method of each key data in the logic unit among the multiple key data.

[0056] The storage mapping information may be used to characterize the storage mapping relationship between each of the multiple key data and the logical unit; or, to characterize the storage mapping relationship between each of the multiple key data and the logical unit, as well as the basic data characteristics of each of the multiple key data. Based on this, it can be understood that in the embodiments of the present disclosure, the storage mapping information is used to enable the target device to read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started. In addition, please refer to Figure 2B In the disclosed embodiment, before the operating system of the target device is started, the storage mapping information can be stored in the non-volatile memory of the target device; after the operating system of the target device is started, the storage mapping information can be read from the non-volatile storage to the file system; thereafter, the kernel of the operating system can read the storage mapping information from the file system, and based on the storage mapping information, read the first target data from the multiple key data stored in the logical unit.

[0057] By adopting the data storage method provided by the embodiment of the present disclosure, after acquiring multiple key data of the target device, the multiple key data can be stored in the logical unit, and storage mapping information can be generated based on the storage method of each of the multiple key data in the logical unit. In this way, compared with the solution in the prior art that all file contents (for example, file contents including multiple key data of the target device) are stored in the non-volatile memory of the target device, and are loaded into the memory of the target device after the operating system is started, and then the file contents are read through the file system or other abstract layers, the target device can directly read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started, without having to read the first target data from the multiple key data through the file system or other abstract layers, thereby improving the flexibility and convenience of data reading.

[0058] Furthermore, since the target device needs to obtain storage mapping information first after the operating system is started, it can read the first target data from the multiple key data stored in the logical unit based on the storage mapping information. This is equivalent to indirectly adding encryption attributes to the multiple key data, thereby increasing the difficulty for a third party to maliciously read the first target data from the multiple key data, thereby improving the security performance of the target device.

[0059] In addition, as mentioned above, multiple key data may include key system software data and / or key additional application data, and the system software data may be relevant data of the system software; the additional application data may be relevant data of the application installed by the user. More specifically, in the embodiment of the present disclosure, multiple key data may include a first number of key system software data and / or a second number of key additional application data. Among them, the specific values ​​of the first number and the second number can be set according to application requirements, and the embodiment of the present disclosure does not limit this. In one example, the system software includes device management software, and the first number of key system software data may include a device identity identifier, a device encryption key, a device calibration data, a device configuration information, etc.; in another example, the application installed by the user includes navigation software, and the second number of key additional application data may include user navigation account information, user navigation location data, user navigation behavior data, etc.

[0060] In the disclosed embodiment, the multiple key data include a first number of key system software data and / or a second number of key additional application data. Therefore, the multiple key data are strongly correlated with the system security of the target device and can further improve the security performance of the target device.

[0061] In some optional implementations, step S103 may include the following sub-steps:

[0062] Step S103 - 1 , for each key data in the plurality of key data, based on the storage mode of the key data in the logical unit, obtain a storage characteristic representation of the key data.

[0063] The stored feature representation may include multiple subclass representation information with different feature attributes.

[0064] In one example, the key data is actually encapsulated into a data file and stored in a logical unit. Based on this, in this example, multiple subclass representation information may include the storage location in the logical unit, and at least one of the file identifier, file type, file extension, file size, and file verification information. Specifically, it may include the storage location in the logical unit of the data file encapsulated with the key data, and at least one of the file identifier, file type, file extension, file size, and file verification information of the data file. In this way, the comprehensiveness of the storage feature representation can be improved, thereby improving the reliability of the storage mapping information, so that the target device can accurately read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started.

[0065] Among them, the file identifier can be a file name (File Name), which is used as the main identifier of the data file encapsulated by the key data to provide a unique identification record for the data file; the file type (File Type) is used to characterize the file nature of the data file encapsulated by the key data, such as ordinary files, target files, symbolic link files, etc.; the file extension (File Extension) is used to characterize the file type or file format of the data file encapsulated by the key data; the file size (File Size) is used to characterize the size of the data storage space that the data file encapsulated by the key data needs to occupy in the logical unit, usually expressed in bytes; the file verification information can be a hash value (Checksum or Hash Value), that is, a fixed-length value generated by a hash algorithm, which is used to verify the integrity of the data file encapsulated by the key data.

[0066] In addition, in this example, the length of the hash value usually depends on the selected hash algorithm. Different hash algorithms will generate hash values ​​of different lengths. For example:

[0067] Message-Digest Algorithm version 5 (MD5): Generates a 128-bit (16-byte) hash value;

[0068] Secure Hash Algorithm 1 (SHA-1): generates a 160-bit (20-byte) hash value;

[0069] Secure Hash Algorithm 256 (SHA-256): generates a 256-bit (32-byte) hash value;

[0070] Secure Hash Algorithm 512 (SHA-512): Generates a 512-bit (64-byte) hash value.

[0071] Step S103-2, generating storage mapping information.

[0072] Among them, the storage mapping information may include multiple storage feature representations corresponding to multiple key data one by one. That is to say, in the embodiment of the present disclosure, after obtaining multiple storage feature representations corresponding to multiple key data one by one, the multiple storage feature representations corresponding to multiple key data one by one can be used together as storage mapping information. In this way, when the storage mapping information is used to characterize the storage mapping relationship between each key data in the multiple key data and the logical unit, and the basic data characteristics of each key data in the multiple key data, and the multiple subclass representation information includes the storage position in the logical unit, as well as the file identifier, file type, file extension, file size and file verification information, for each key data in the multiple key data, the storage location and file identifier corresponding to the key data can be extracted from the storage feature representation corresponding to the key data, and a storage mapping relationship is established based on the storage location and file identifier corresponding to the key data, and at the same time, the file identifier, file type, file extension, file size and file verification information corresponding to the key data are extracted from the storage feature representation corresponding to the key data as the basic data characteristics of the key data.

[0073] Exemplarily, the storage mapping information may be as shown in Table 1 below:

[0074] Table 1

[0075]

[0076] For example, for key data A1 among multiple key data, the storage location (base address: 0X00_8800_0000; high address: 0X00_8800_0FFF) and file identifier ( / FileName / S_AXI) corresponding to the key data A1 can be extracted from the storage feature representation corresponding to the key data A1, and a storage mapping relationship is established based on the storage location (base address: 0X00_8800_0000; high address: 0X00_8800_0FFF) and file identifier ( / FileName / S_AXI) corresponding to the key data A1. At the same time, the file identifier ( / FileName / S_AXI), file size (4K), etc. corresponding to the key data A1 are extracted from the storage feature representation corresponding to the key data A1 as basic data features of the key data.

[0077] Through step S103-1 and step S103-2, in the embodiment of the present disclosure, for each key data in the multiple key data, the storage characteristic representation of the key data can be obtained based on the storage method of the key data in the logical unit, and the storage mapping information is generated based on the multiple storage characteristic representations corresponding to the multiple key data. In this process, on the one hand, generating an independent storage characteristic representation for each key data in the multiple key data can ensure the accuracy of the storage mapping information; on the other hand, since each key data in the multiple key data has its independent storage characteristic representation, when a key data in the multiple key data changes (for example, is newly added to the logical unit, deleted from the logical unit, or its data storage space in the logical unit is changed), the storage characteristic representation of the key data can be easily added, deleted or modified without changing the entire storage mapping information, thereby reducing the complexity of the data storage method.

[0078] The present disclosure also provides a second data storage method, which can be applied to electronic devices, such as the target device mentioned in the present disclosure. The target device can be a terminal device in various forms, and the terminal device can be a conventional computer (e.g., a desktop computer, a laptop computer, a vehicle-mounted computer, etc.), a personal digital assistant, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing devices. Furthermore, in the present disclosure, the target device includes a programmable device having a logic unit, such as an FPGA developed based on Xilinx's ZYNQ or MPSOC.

[0079] The following will be combined Figure 3 The flowchart diagram shown is used to illustrate the second data storage method provided by the embodiment of the present disclosure. It should be noted that although the logical order is shown in the flowchart diagram, in some cases, the steps shown or described may also be performed in other orders.

[0080] Step S301, obtaining multiple key data of the target device.

[0081] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S301 can refer to the relevant description of the same steps in the above method embodiment, and will not be repeated here.

[0082] Step S302: storing multiple key data in a logical unit.

[0083] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S302 can refer to the relevant description of the same steps in the above method embodiment, and will not be repeated here.

[0084] Step S303: Generate storage mapping information based on the storage method of each key data in the logic unit among the multiple key data.

[0085] The storage mapping information may include a plurality of storage feature representations corresponding one-to-one to the plurality of key data.

[0086] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S303 can be found in the related description of the same steps in the above method embodiment, and will not be repeated here.

[0087] Step S304, obtaining multiple mapping sub-information based on multiple storage feature representations.

[0088] In actual implementation, each of the multiple storage feature representations can be used as a mapping sub-information to obtain multiple mapping sub-information, or the multiple storage feature representations can be split and integrated to obtain multiple mapping sub-information. That is, in some optional implementations, step S304 may include one of the following sub-steps:

[0089] Step S304-1, taking each of the multiple storage feature representations as a mapping sub-information to obtain multiple mapping sub-information.

[0090] Exemplarily, the multiple storage feature representations include storage feature representation C1, storage feature representation C2 and storage feature representation C3. Then, the storage feature representation C1 can be regarded as a mapping sub-information, recorded as mapping sub-information D1, the storage feature representation C2 can be regarded as a mapping sub-information, recorded as mapping sub-information D2, and the storage feature representation C3 can be regarded as a mapping sub-information, recorded as mapping sub-information D3.

[0091] Finally, three mapping sub-information pieces can be obtained, namely mapping sub-information D1, mapping sub-information D2 and mapping sub-information D3.

[0092] Through step S304-1, in the embodiment of the present disclosure, each of the multiple storage feature representations can be directly used as a mapping sub-information to obtain multiple mapping sub-information. In this way, the acquisition process of the mapping sub-information can be simplified, thereby improving the execution efficiency of the data storage method.

[0093] Step S304-2: Take the subclass representation information with the same characteristic attribute in the multiple stored characteristic representations as one mapping sub-information to obtain multiple mapping sub-information.

[0094] As mentioned above, the storage feature representation may include multiple sub-class representation information with different feature attributes, wherein the multiple sub-class representation information may include a storage location in the logical unit, and at least one of a file identifier, a file type, a file extension, a file size, and a file verification information.

[0095] Exemplarily, the plurality of storage feature representations include storage feature representation C1, storage feature representation C2, and storage feature representation C3. Among them, storage feature representation C1 includes storage location E11, file identifier E12, and file size E13 in a logical unit; storage feature representation C2 includes storage location E21, file identifier E22, and file size E23 in a logical unit; storage feature representation C3 includes storage location E31, file identifier E32, and file size E33 in a logical unit. Then, storage location E11, storage location E12, and storage location E13 can be collectively regarded as a mapping sub-information, recorded as mapping sub-information F1, file identifier E12, file identifier E22, and file identifier E32 can be collectively regarded as a mapping sub-information, recorded as mapping sub-information F2, and file size E13, file size E23, and file size E33 can be collectively regarded as a mapping sub-information, recorded as mapping sub-information F3.

[0096] Finally, three mapping sub-information pieces can be obtained, namely mapping sub-information F1, mapping sub-information F2 and mapping sub-information F3.

[0097] Through step S304-2, in the embodiment of the present disclosure, the subclass representation information with the same characteristic attribute in the multiple storage characteristic representations can be taken as a mapping sub-information to obtain multiple mapping sub-information. In this way, it is possible to improve the difficulty of restoring the multiple storage characteristic representations included in the storage mapping information through the multiple mapping sub-information, and further read the first target data from the multiple key data stored in the logical unit, thereby further improving the security performance of the target device.

[0098] Step S305: storing the plurality of mapping sub-information in a non-volatile memory of the target device in a distributed storage manner.

[0099] Among them, the distributed storage method can be understood as: storing multiple mapping sub-information in different data storage spaces in a non-volatile memory; after the multiple mapping sub-information is used to enable the target device to operate the system, the multiple mapping sub-information is read from the non-volatile memory to the memory of the target device; based on the multiple mapping sub-information stored in the memory, a target feature representation is obtained; based on the target feature representation, the first target data corresponding to the target feature representation is read from the multiple key data stored in the logical unit.

[0100] In addition, in the embodiment of the present disclosure, when executing step S305, multiple mapping sub-information can be stored in multiple data storage spaces in the non-volatile memory in a one-to-one correspondence.

[0101] Exemplarily, the multiple mapping sub-information include mapping sub-information D1, mapping sub-information D2 and mapping sub-information D3. Then, the mapping sub-information D1 can be stored in the data storage space G1 in the non-volatile memory, the mapping sub-information D2 can be stored in the data storage space G2 in the non-volatile memory, and the mapping sub-information D3 can be stored in the data storage space G3 in the non-volatile memory.

[0102] Since multiple mapping sub-information is stored one-to-one in multiple data storage spaces in the non-volatile memory, when the mapping sub-information in a certain data storage space is damaged or lost, it will not affect the mapping sub-information in other data storage spaces. Therefore, the target device is allowed to continue running when part of the mapping sub-information is damaged, thereby improving the fault tolerance of the target device.

[0103] By adopting the data storage method provided by the embodiment of the present disclosure, after acquiring multiple key data of the target device, the multiple key data can be stored in the logical unit, and based on the storage method of each key data in the multiple key data in the logical unit, storage mapping information (including multiple storage feature representations corresponding to the multiple key data) is generated, and then based on the multiple storage feature representations, multiple mapping sub-information is obtained, and the multiple mapping sub-information is stored in the non-volatile memory of the target device in a distributed storage manner, that is, the multiple mapping sub-information is stored in different data storage spaces in the non-volatile memory. In this way, even if a third party maliciously reads a certain mapping sub-information from the multiple mapping sub-information stored in the non-volatile memory, and at least based on the mapping sub-information, reads a certain key data from the multiple key data stored in the logical unit, it is not necessarily possible to read other mapping sub-information from the multiple mapping sub-information stored in the non-volatile memory, and then read other key data from the multiple key data stored in the logical unit, so that the security performance of the target device can be further improved.

[0104] The present disclosure also provides a third data storage method, which can be applied to electronic devices, such as the target device mentioned in the present disclosure. The target device can be a terminal device in various forms, and the terminal device can be a conventional computer (e.g., a desktop computer, a laptop computer, a vehicle-mounted computer, etc.), a personal digital assistant, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing devices. Furthermore, in the present disclosure, the target device includes a programmable device having a logic unit, such as an FPGA developed based on Xilinx's ZYNQ or MPSOC.

[0105] The following will be combined Figure 4 The flowchart diagram shown is used to illustrate the third data storage method provided by the embodiment of the present disclosure. It should be noted that although the logical order is shown in the flowchart diagram, in some cases, the steps shown or described may also be performed in other orders.

[0106] Step S401, obtaining multiple key data of the target device.

[0107] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S401 can refer to the relevant description of the same steps in the above method embodiment, and will not be repeated here.

[0108] Step S402: storing multiple key data in a logical unit.

[0109] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S402 can refer to the relevant description of the same steps in the above method embodiment, and will not be repeated here.

[0110] Step S403: Generate storage mapping information based on the storage method of each key data in the logic unit among the multiple key data.

[0111] The storage mapping information may include a plurality of storage feature representations corresponding one-to-one to a plurality of key data.

[0112] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S403 can be found in the related description of the same steps in the above method embodiment, and will not be repeated here.

[0113] Step S404, obtaining multiple mapping sub-information based on multiple storage feature representations.

[0114] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S404 can refer to the relevant description of the same steps in the above method embodiment, and will not be repeated here.

[0115] Step S405: storing the plurality of mapping sub-information in a non-volatile memory of the target device in a distributed storage manner.

[0116] In the data storage method provided in the embodiment of the present disclosure, the specific description and example description of step S405 can refer to the relevant description of the same steps in the above method embodiment, and will not be repeated here.

[0117] Step S406: for each piece of mapping sub-information in the plurality of mapping sub-information, obtain a transfer frequency value corresponding to the mapping sub-information.

[0118] The transfer frequency value corresponding to the mapping sub-information can be obtained by real-time calculation or preset. For example, in the case where "based on multiple storage feature representations, multiple mapping sub-information is obtained" includes "based on multiple storage feature representations, multiple mapping sub-information is obtained including taking each storage feature representation in the multiple storage feature representations as a mapping sub-information to obtain the multiple mapping sub-information", the transfer frequency value corresponding to the mapping sub-information can be obtained by real-time calculation; for another example, in the case where "based on multiple storage feature representations, multiple mapping sub-information is obtained" includes "based on multiple storage feature representations, multiple mapping sub-information is obtained including taking subclass representation information with the same characteristic attributes in multiple storage feature representations as a mapping sub-information to obtain multiple mapping sub-information", the transfer frequency value corresponding to the mapping sub-information can be preset.

[0119] In some optional implementations, when “based on multiple storage feature representations, obtaining multiple mapping sub-information” includes “based on multiple storage feature representations, obtaining multiple mapping sub-information includes taking each storage feature representation in the multiple storage feature representations as a mapping sub-information to obtain the multiple mapping sub-information”, the “obtaining a transfer frequency value corresponding to the mapping sub-information” in step S406 may include the following sub-steps:

[0120] Step S406-1, obtaining a transfer frequency indication parameter of the mapping sub-information.

[0121] The transfer frequency indication parameter is used to control the frequency of changing the data storage space of the mapping sub-information in the non-volatile memory, and the transfer frequency indication parameter is positively correlated with the data security requirement of the second target data; the second target data is the key data corresponding to the mapping sub-information among the multiple key data. Here, the greater the data security requirement of the second target data, the greater the impact of the second target data on the security performance of the target device; on the contrary, the smaller the data security requirement of the second target data, the smaller the impact of the second target data on the security performance of the target device.

[0122] In one example, the transfer frequency indication parameter of the mapping sub-information may be obtained in the following manner:

[0123] (1) Obtaining the reading frequency of the second target data and / or the core degree index of the second target data.

[0124] The read frequency may be the frequency at which the second target data is read in the recent historical usage period of the target device; the core index may be used to characterize the importance of the second target data. Here, the higher the read frequency, the higher the usage frequency of the application (e.g., system software and user-installed application) related to the second target data; conversely, the lower the read frequency, the lower the usage frequency of the application related to the second target data; the length of the recent historical usage period may be set according to application requirements, and the embodiments of the present disclosure do not impose any restrictions on this; the importance may be pre-set, and the embodiments of the present disclosure do not impose any restrictions on this either.

[0125] (2) Based on the reading frequency of the second target data and / or the core degree index of the second target data, a transfer frequency indication parameter of the mapping sub-information is obtained.

[0126] In a specific example, when only the read frequency of the second target data is obtained but the core degree index of the second target data is not obtained, the read frequency of the second target data can be used as the transfer frequency indication parameter of the mapping sub-information; in another specific example, when the read frequency of the second target data is not obtained but only the core degree index of the second target data is obtained, the core degree index of the second target data can be used as the transfer frequency indication parameter of the mapping sub-information; in yet another specific example, when the read frequency of the second target data and the core degree index of the second target data are obtained, the transfer frequency indication parameter of the mapping sub-information can be obtained based on the read frequency of the second target data and the core degree index of the second target data.

[0127] Exemplarily, when the reading frequency of the second target data and the core degree index of the second target data are obtained, the transfer frequency indication parameter of the mapping sub-information can be obtained through the following calculation logic:

[0128] FP=X1×Y1+X2×Y3

[0129] Among them, FP is used to characterize the transfer frequency indication parameter of the mapping sub-information; X1 is the first weight value; Y1 is used to characterize the read frequency of the second target data; X2 is the second weight value; Y2 is used to characterize the core degree index of the second target data. Here, the first weight value X1 and the second weight value X2 can be set according to application requirements. For example, the first weight value X1 can be set to 0.4 and the second weight value X2 can be set to 0.6. The embodiments of the present disclosure are not limited to this.

[0130] Generally speaking, the reading frequency of the second target data and / or the core index of the second target data have an absolute positive correlation with the data security requirements of the second target data, and therefore can be used to accurately characterize the data security requirements of the second target data. Based on this, in the embodiment of the present disclosure, the second target data corresponding to the mapping sub-information is determined from multiple key data, and the reading frequency of the second target data and / or the core index of the second target data are obtained, and then based on the reading frequency of the second target data and / or the core index of the second target data, the transfer frequency indication parameter of the mapping sub-information can be accurately obtained, that is, the reliability of the transfer frequency indication parameter of the mapping sub-information can be improved.

[0131] Step S406-2, obtaining a transfer frequency value that is positively correlated with the transfer frequency indication parameter.

[0132] That is to say, the larger the transfer frequency indication parameter is, the larger the transfer frequency value can be obtained; conversely, the smaller the transfer frequency indication parameter is, the smaller the transfer frequency value can be obtained.

[0133] Through step S406-1 and step S406-2, in the embodiment of the present disclosure, the transfer frequency indication parameter of the mapping sub-information can be obtained (the transfer frequency indication parameter is used to control the frequency of change of the data storage space of the mapping sub-information in the non-volatile memory, and the transfer frequency indication parameter is positively correlated with the data security requirement of the second target data; the second target data is the key data corresponding to the mapping sub-information among the multiple key data), and the transfer frequency value positively correlated with the transfer frequency indication parameter is obtained. In other words, the higher the data security requirement of the second target data, the higher a relatively high transfer frequency indication parameter can be obtained; conversely, the lower the data security requirement of the second target data, the lower a relatively low transfer frequency indication parameter can be obtained. In this way, it is possible to avoid investing too much energy in data transfer in the mapping sub-information corresponding to the second target data with lower security requirements, thereby reducing resource consumption of the target device.

[0134] Step S407: changing the data storage space of the mapping sub-information in the non-volatile memory according to the transfer frequency value.

[0135] By adopting the data storage method provided by the embodiment of the present disclosure, after obtaining multiple key data of the target device, the multiple key data can be stored in the logical unit, and based on the storage method of each key data in the logical unit, the storage mapping information (including multiple storage feature representations corresponding to the multiple key data) is generated, and then based on the multiple storage feature representations, multiple mapping sub-information is obtained, and the multiple mapping sub-information is stored in the non-volatile memory of the target device in a distributed storage manner. Thereafter, for each mapping sub-information in the multiple mapping sub-information, the transfer frequency indication parameter of the mapping sub-information can also be obtained, and the transfer frequency value positively correlated with the transfer frequency indication parameter is obtained, and then the data storage space of the mapping sub-information in the non-volatile memory is changed according to the transfer frequency value. In this way, the difficulty of a third party maliciously reading a certain mapping sub-information from the multiple mapping sub-information stored in the non-volatile memory can be further improved, so as to further improve the security performance of the target device.

[0136] The disclosed embodiment also provides a data reading method, which can be applied to electronic devices, for example, the target device mentioned in the disclosed embodiment. Wherein, the target device can be a terminal device of various forms, and the terminal device can be a conventional computer (for example, a desktop computer, a laptop computer, a vehicle-mounted computer, etc.), a personal digital processing, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing devices. Further, in the disclosed embodiment, the target device includes a programmable device with a logic unit, for example, an FPGA developed based on Xilinx's ZYNQ or MPSOC. Wherein, a plurality of key data of the target device are stored in the logic unit, and the target device is used to generate storage mapping information based on the storage method of each key data in the plurality of key data in the logic unit. Here, the storage mapping information can be used to characterize the storage mapping relationship between each key data in the plurality of key data and the logic unit; or, to characterize the storage mapping relationship between each key data in the plurality of key data and the logic unit, and the basic data characteristics of each key data in the plurality of key data.

[0137] Furthermore, it can be understood that, in the embodiments of the present disclosure, the data reading method can be used to read the first target data from a plurality of key data stored in the logic unit by the above-mentioned data storage method.

[0138] The following will be combined Figure 5 The flowchart diagram is shown to illustrate the data reading method provided by the embodiment of the present disclosure. It should be noted that although the logical order is shown in the flowchart diagram, in some cases, the steps shown or described may also be performed in other orders.

[0139] Step S501 : when the operating system of the target device is started, first target data is read from a plurality of key data stored in a logical unit based on storage mapping information.

[0140] The storage mapping information may include a plurality of storage feature representations corresponding to the plurality of key data in a one-to-one manner. Here, the storage feature representation may include a plurality of subclass representation information having different feature attributes.

[0141] As mentioned above, in the data storage stage of multiple key data, the key data can be encapsulated into a data file and stored in the logical unit. Based on this, in this example, the multiple subclass representation information may include the storage location of the data file encapsulated with the key data in the logical unit, and at least one of the file identifier, file type, file extension, file size and file verification information of the data file encapsulated with the key data.

[0142] In the case where the storage mapping information is used to characterize the storage mapping relationship between each key data among multiple key data and the logical unit, as well as the basic data characteristics of each key data among the multiple key data, and multiple subclass representation information includes the storage location in the logical unit, as well as the file identifier, file type, file extension, file size and file verification information, for each key data among the multiple key data, the storage location and file identifier corresponding to the key data can be extracted from the storage feature representation corresponding to the key data, and a storage mapping relationship is established based on the storage location and file identifier corresponding to the key data, and at the same time, the file identifier, file type, file extension, file size and file verification information corresponding to the key data can be extracted from the storage feature representation corresponding to the key data as the basic data characteristics of the key data.

[0143] Based on this, in the embodiments of the present disclosure, a storage mapping relationship corresponding to the first target data to be read and basic data characteristics of the first target data to be read can be obtained based on the storage mapping information, and based on the storage mapping relationship corresponding to the first target data to be read and basic data characteristics of the first target data to be read, the first target data can be read from multiple key data stored in the logical unit.

[0144] By adopting the data reading method provided in the embodiment of the present disclosure, when the operating system of the target device is started, the first target data can be read from multiple key data stored in the logical unit based on the storage mapping information, without having to read the first target data from the multiple key data through the file system or other abstract layers. Therefore, the flexibility and convenience of data reading can be improved.

[0145] In addition, as mentioned above, the storage mapping information includes multiple storage feature representations corresponding to multiple key data one by one, and the target device is also used to obtain multiple mapping sub-information based on the multiple storage feature representations; the multiple mapping sub-information is stored in the non-volatile memory of the target device in a distributed storage manner. Based on this, in the embodiment of the present disclosure, the "reading the first target data from the multiple key data stored in the logical unit based on the storage mapping information" in step S501 may include the following sub-steps:

[0146] Step S501 - 1 , reading multiple mapping sub-information from the non-volatile memory into the memory of the target device.

[0147] Step S501 - 2 , obtaining a target feature representation based on the multiple mapping sub-information stored in the memory.

[0148] In one example, each mapping sub-information in the multiple mapping sub-information is a storage feature representation, then after obtaining a data read indication, the target feature representation can be determined from the multiple mapping sub-information according to the data read indication; in another example, each mapping sub-information in the multiple mapping sub-information is subclass representation information with the same feature attribute in the multiple storage feature representations, then the storage mapping information can be restored based on the multiple mapping sub-information, and then after obtaining the data read indication, the target feature representation can be determined from the storage mapping information according to the data read indication.

[0149] Step S501 - 3 , based on the target feature representation, read the first target data corresponding to the target feature representation from the multiple key data stored in the logic unit.

[0150] In one example, storage mapping information (including multiple storage feature representations corresponding one-to-one to multiple key data) is used to characterize the storage mapping relationship between each of the multiple key data and the logical unit, as well as the basic data features of each of the multiple key data. Then, based on the target feature representation, the storage mapping relationship between the first target data to be read and the logical unit, as well as the basic data features of the first target data to be read, can be obtained, and according to the storage mapping relationship between the first target data to be read and the logical unit, candidate data can be located from the logical unit. Then, when the basic data features of the candidate data are the same as the basic data features of the first target data to be read, the candidate data is used as the first target data, and the first target data is read.

[0151] Through step S501-1, step S501-2 and step S501-3, in the embodiment of the present disclosure, multiple mapping sub-information can be read from the non-volatile memory into the memory of the target device, and based on the multiple mapping sub-information stored in the memory, the target feature representation is obtained, and then based on the target feature representation, the first target data corresponding to the target feature representation is read from the multiple key data stored in the logic unit. In this way, the data reading efficiency can be improved based on the fast accessibility of the memory and the compatibility of complex algorithms.

[0152] The following will be combined Figure 6 , a complete process of a data storage method provided by an embodiment of the present disclosure is introduced in detail.

[0153] Step S601, obtaining multiple key data of the target device.

[0154] Step S602: storing multiple key data in a logical unit.

[0155] Step S603 , for each key data in the plurality of key data, based on the storage mode of the key data in the logical unit, obtain a storage characteristic representation of the key data.

[0156] The stored feature representation may include multiple subclass representation information with different feature attributes.

[0157] Step S604: Generate storage mapping information.

[0158] The storage mapping information may include multiple storage feature representations corresponding one-to-one to multiple key data, and the storage mapping information is used to enable the target device to read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started.

[0159] Step S605, taking each of the multiple storage feature representations as a mapping sub-information to obtain multiple mapping sub-information, or taking the subclass representation information with the same characteristic attributes in the multiple storage feature representations as a mapping sub-information to obtain multiple mapping sub-information.

[0160] Step S606: storing the plurality of mapping sub-information in a one-to-one correspondence in a plurality of data storage spaces in the non-volatile memory.

[0161] Among them, multiple mapping sub-information is used to enable the target device to read the multiple mapping sub-information from the non-volatile memory to the memory of the target device after the operating system is started; based on the multiple mapping sub-information stored in the memory, a target feature representation is obtained; based on the target feature representation, the first target data corresponding to the target feature representation is read from the multiple key data stored in the logical unit.

[0162] Step S607: for each piece of mapping sub-information in the plurality of mapping sub-information, obtain a transfer frequency value corresponding to the mapping sub-information.

[0163] When step S605 is executed in which "each storage feature representation in the plurality of storage feature representations is used as a mapping sub-information to obtain the plurality of mapping sub-information", the "obtaining the transfer frequency value corresponding to the mapping sub-information" in step S607 may include the following sub-steps:

[0164] Step S607-1, obtaining a transfer frequency indication parameter of the mapping sub-information.

[0165] Among them, the transfer frequency indication parameter is used to control the change frequency of the data storage space of the mapping sub-information in the non-volatile memory, and the transfer frequency indication parameter is positively correlated with the data security protection requirement of the second target data; the second target data is the key data corresponding to the mapping sub-information among multiple key data.

[0166] In one example, the reading frequency of the second target data and / or the core degree index of the second target data can be obtained, and based on the reading frequency of the second target data and / or the core degree index of the second target data, the transfer frequency indication parameter of the mapping sub-information can be obtained.

[0167] Step S607-2, obtaining a transfer frequency value that is positively correlated with the transfer frequency indication parameter.

[0168] Step S608: changing the data storage space of the mapping sub-information in the non-volatile memory according to the transfer frequency value.

[0169] The following will be combined Figure 7 , the complete process of a data reading method provided by the embodiment of the present disclosure will be described in detail. It can be understood that in the embodiment of the present disclosure, the data reading method can be used to read the first target data from multiple key data stored in the logical unit by the above data storage method.

[0170] Step S701, reading a plurality of mapping sub-information from a non-volatile memory into a memory of a target device.

[0171] Step S702, obtaining a target feature representation based on the plurality of mapping sub-information stored in the memory.

[0172] Step S703: based on the target feature representation, read the first target data corresponding to the target feature representation from the plurality of key data stored in the logic unit.

[0173] Furthermore, an embodiment of the present disclosure also provides a scenario diagram of a data storage method and / or a data reading method.

[0174] As mentioned above, the data storage method and / or data reading method provided in the embodiments of the present disclosure is applied to electronic devices, for example, the target device mentioned in the embodiments of the present disclosure. Fig. 8A and Figure 8B The target device may be a terminal device in various forms, and the terminal device may be a conventional computer (e.g., a desktop computer, a laptop computer, a car computer, etc.), a personal digital processing, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing devices. Further, in the embodiment of the present disclosure, the target device includes a programmable device having a logic unit, for example, an FPGA developed based on Xilinx's ZYNQ or MPSOC.

[0175] Target devices can be used for:

[0176] Obtain multiple key data of the target device;

[0177] Store multiple pieces of critical data in logical units;

[0178] Storage mapping information is generated based on the storage manner of each key data in the logic unit among the multiple key data.

[0179] The storage mapping information is used to enable the target device to read the first target data from the multiple key data stored in the logic unit based on the storage mapping information after the operating system is started.

[0180] Target devices can also be used to:

[0181] When the operating system of the target device is started, the first target data is read from the plurality of key data stored in the logical unit based on the storage mapping information.

[0182] It should be noted that in the embodiments of the present disclosure, Fig. 8A and Figure 8B The scene diagram shown is only illustrative and not restrictive. Those skilled in the art can Fig. 8A and Figure 8B Various obvious changes and / or substitutions are made to the examples, and the obtained technical solutions still fall within the scope of the disclosure of the embodiments of the present disclosure.

[0183] In order to better implement Figure 1 , Figure 3 , Figure 4 or Figure 6In addition to the data storage method shown, the embodiments of the present disclosure also provide a data storage device, which can be integrated into an electronic device, for example, the target device mentioned in the embodiments of the present disclosure. The target device can be a terminal device in various forms, and the terminal device can be a conventional computer (for example, a desktop computer, a laptop computer, a car computer, etc.), a personal digital processing, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing devices. Furthermore, in the embodiments of the present disclosure, the target device includes a programmable device with a logic unit, for example, an FPGA developed based on Xilinx's ZYNQ or MPSOC.

[0184] The following will be combined Fig. 9 The structural schematic diagram shown is used to illustrate the data storage device 900 provided in the disclosed embodiment.

[0185] The data storage device 900 includes:

[0186] A data acquisition unit 901 is used to acquire multiple key data of a target device;

[0187] A data storage unit 902, used to store multiple key data in a logical unit;

[0188] The information generation unit 903 is used to generate storage mapping information based on the storage method of each key data in the logical unit among the multiple key data; wherein the storage mapping information is used to enable the operating system of the target device to read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after startup.

[0189] In some optional implementations, the information generating unit 903 is configured to:

[0190] For each key data in the multiple key data, based on the storage method of the key data in the logical unit, a storage characteristic representation of the key data is obtained; wherein the storage characteristic representation includes multiple subclass representation information with different characteristic attributes;

[0191] Generate storage mapping information; wherein the storage mapping information includes a plurality of storage feature representations corresponding one-to-one to a plurality of key data.

[0192] In some optional embodiments, the plurality of subclass representation information includes a storage location in the logic unit, and at least one of a file identifier, a file type, a file extension, a file size, and file verification information.

[0193] In some optional implementations, the data storage device 900 further includes:

[0194] An information allocation unit, configured to obtain a plurality of mapping sub-information based on a plurality of storage feature representations;

[0195] A storage control unit is used to store multiple mapping sub-information in a non-volatile memory of a target device in a distributed storage manner; wherein the multiple mapping sub-information is used to enable the operating system of the target device to read the multiple mapping sub-information from the non-volatile memory to the memory of the target device after startup; based on the multiple mapping sub-information stored in the memory, a target feature representation is obtained; based on the target feature representation, first target data corresponding to the target feature representation is read from multiple key data stored in a logical unit.

[0196] In some optional implementations, the information distribution unit is used to:

[0197] Taking each of the plurality of storage feature representations as a mapping sub-information to obtain a plurality of mapping sub-information;

[0198] Alternatively, multiple pieces of subclass representation information having the same characteristic attribute in the stored characteristic representation are taken together as one piece of mapping sub-information to obtain multiple pieces of mapping sub-information.

[0199] In some optional implementations, the storage control unit is used to:

[0200] The plurality of mapping sub-information are stored in a plurality of data storage spaces in the non-volatile memory in a one-to-one correspondence.

[0201] In some optional implementations, the data storage device 900 further includes:

[0202] A frequency value acquisition unit, configured to acquire, for each mapping sub-information in the plurality of mapping sub-information, a transfer frequency value corresponding to the mapping sub-information;

[0203] The storage space control unit is used to change the data storage space of the mapping sub-information in the non-volatile memory according to the transfer frequency value.

[0204] In some optional implementations, the information allocation unit is used to use each of the multiple storage feature representations as a mapping sub-information to obtain multiple mapping sub-information; and the frequency value acquisition unit is used to:

[0205] Obtaining a transfer frequency indication parameter of the mapping sub-information; wherein the transfer frequency indication parameter is used to control the frequency of changing the data storage space of the mapping sub-information in the non-volatile memory, and the transfer frequency indication parameter is positively correlated with the data security requirement of the second target data; the second target data is the key data corresponding to the mapping sub-information among the multiple key data;

[0206] A transfer frequency value that is positively correlated with the transfer frequency indication parameter is obtained.

[0207] In some optional implementations, the frequency value acquiring unit is used to:

[0208] Obtaining a reading frequency of the second target data and / or a core degree index of the second target data;

[0209] Based on the reading frequency of the second target data and / or the core degree index of the second target data, a transfer frequency indication parameter of the mapping sub-information is obtained.

[0210] In some optional implementations, the plurality of critical data include a first number of critical system software data and / or a second number of critical additional application data.

[0211] For the specific functions and examples of each unit in the data storage device 900 provided in the embodiment of the present disclosure, reference can be made to the relevant descriptions of the corresponding steps in the above method embodiment, which will not be repeated here.

[0212] To better implement Figure 5 or Figure 7 In addition to the data reading method shown, the embodiment of the present disclosure also provides a data reading device, which can be integrated into an electronic device, for example, the target device mentioned in the embodiment of the present disclosure. Wherein, the target device can be a terminal device in various forms, and the terminal device can be a conventional computer (for example, a desktop computer, a laptop computer, a vehicle-mounted computer, etc.), a personal digital processing, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing devices. Further, in the embodiment of the present disclosure, the target device includes a programmable device with a logic unit, for example, an FPGA developed based on Xilinx's ZYNQ or MPSOC. Wherein, a plurality of key data of the target device are stored in the logic unit, and the target device is used to generate storage mapping information based on the storage method of each of the multiple key data in the logic unit.

[0213] The following will be combined Fig.10 The structural schematic diagram shown is used to illustrate the data reading device 1000 provided in the disclosed embodiment.

[0214] The data reading device 1000 includes:

[0215] The data reading unit 1001 is used to read first target data from a plurality of key data stored in a logic unit based on storage mapping information when the operating system of the target device is started.

[0216] In some optional implementations, the storage mapping information includes multiple storage feature representations corresponding to the multiple key data one by one, and the target device is further used to obtain multiple mapping sub-information based on the multiple storage feature representations; the multiple mapping sub-information is stored in a non-volatile memory of the target device in a distributed storage manner; the data reading unit 1001 is used to:

[0217] Reading a plurality of mapping sub-information from a non-volatile memory into a memory of a target device;

[0218] Based on the multiple mapping sub-information stored in the memory, a target feature representation is obtained;

[0219] Based on the target feature representation, first target data corresponding to the target feature representation is read from a plurality of key data stored in the logic unit.

[0220] For the specific functions and examples of each unit in the data reading device 1000 provided by the embodiment of the present disclosure, reference may be made to the relevant descriptions of the corresponding steps in the above method embodiment, which will not be repeated here.

[0221] In the technical solution disclosed herein, the acquisition, storage and application of user personal information involved are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.

[0222] According to an embodiment of the present disclosure, the present disclosure also provides an electronic device, a readable storage medium and a computer program product.

[0223] Fig.11 A schematic block diagram of an example electronic device 1100 that can be used to implement an embodiment of the present disclosure is shown. The electronic device is intended to represent a server, or various forms of terminal devices. The terminal device can be a conventional computer (e.g., a desktop computer, a laptop computer, etc.), a personal digital processing, a cellular phone, a smart phone, a tablet computer, an Internet of Things device, or other similar computing device. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.

[0224] like Fig.11As shown, the device 1100 includes a computing unit 1101, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 1102 or a computer program loaded from a storage unit 1109 to a random access memory (RAM) 1103. In the RAM 1103, various programs and data required for the operation of the device 1100 can also be stored. The computing unit 1101, the ROM 1102, and the RAM 1103 are connected to each other via a bus 1104. An input / output (I / O) interface 1105 is also connected to the bus 1104.

[0225] A number of components in the device 1100 are connected to the I / O interface 1105, including: an input unit 1106, such as a keyboard, a mouse, etc.; an output unit 1107, such as various types of displays, speakers, etc.; a storage unit 1109, such as a disk, an optical disk, etc.; and a communication unit 1109, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 1109 allows the device 1100 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0226] The computing unit 1101 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 1101 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSP), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 1101 performs the various methods and processes described above, such as data storage methods and / or data reading methods. For example, in some embodiments, the data storage method may be implemented as a computer software program, which is tangibly included in a machine-readable medium, such as a storage unit 1108; for another example, in some embodiments, the data reading method may be implemented as a computer software program, which is tangibly included in a machine-readable medium, such as a storage unit 1108. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 1100 via the ROM 1102 and / or the communication unit 1109. When the computer program is loaded into the RAM 1103 and executed by the computing unit 1101, at least one step of the data storage method and / or the data reading method described above may be performed. Alternatively, in other embodiments, the computing unit 1101 may be configured to perform the data storage method and / or the data reading method in any other appropriate manner (e.g., by means of firmware).

[0227] Various embodiments of the systems and techniques described above herein may be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include: being implemented in at least one computer program that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0228] The program code for implementing the method of the present disclosure may be written in any combination of at least one programming language. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine as a stand-alone software package and partially on a remote machine, or entirely on a remote machine or server.

[0229] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on at least one line, a portable computer disk, a hard disk, a RAM, a ROM, an erasable programmable read-only memory (EPROM) or a flash memory, an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0230] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a cathode ray tube (CRT) display or a liquid crystal display (LCD)) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0231] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: Local Area Network (LAN), Wide Area Network (WAN), and the Internet.

[0232] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship to each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.

[0233] The embodiments of the present disclosure also provide a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable the computer to execute a data storage method and / or a data reading method.

[0234] The embodiments of the present disclosure also provide a computer program product, including a computer program, which implements a data storage method and / or a data reading method when executed by a processor.

[0235] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in the present disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in the present disclosure can be achieved, and this document is not limited here. In addition, in the present disclosure, relational terms such as "first", "second", "third", etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. In addition, "multiple" in the present disclosure can be understood as at least two.

[0236] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the principles of the present disclosure shall be included in the protection scope of the present disclosure.

Claims

1. A data storage method, applied to a target device, wherein the target device comprises a programmable device having a logic unit; the method comprises: Acquire multiple key data of the target device; storing the plurality of key data in the logic unit; Based on the storage manner of each of the multiple key data in the logical unit, storage mapping information is generated; wherein the storage mapping information is used to enable the target device to read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started.

2. The method according to claim 1, wherein: The generating storage mapping information based on the storage mode of the plurality of key data in the logical unit includes: For each key data of the plurality of key data, based on the storage mode of the key data in the logic unit, a storage characteristic representation of the key data is obtained; wherein the storage characteristic representation includes a plurality of subclass representation information with different characteristic attributes; Generate the storage mapping information; wherein the storage mapping information includes a plurality of storage feature representations corresponding one-to-one to the plurality of key data.

3. The method according to claim 2, wherein: The plurality of subclass representation information includes a storage location in the logic unit, and at least one of a file identifier, a file type, a file extension, a file size, and file verification information.

4. The method according to claim 2, further comprising: Based on the plurality of stored feature representations, obtaining a plurality of mapping sub-information; According to a distributed storage method, the multiple mapping sub-information are stored in a non-volatile memory of the target device; wherein the multiple mapping sub-information are used to enable the target device to read the multiple mapping sub-information from the non-volatile memory to the memory of the target device after the operating system is started; based on the multiple mapping sub-information stored in the memory, a target feature representation is obtained; based on the target feature representation, the first target data corresponding to the target feature representation is read from the multiple key data stored in the logical unit.

5. The method according to claim 4, wherein: The obtaining of multiple mapping sub-information based on the multiple storage feature representations includes: Taking each of the plurality of storage feature representations as a mapping sub-information to obtain the plurality of mapping sub-information; Alternatively, the subclass representation information with the same characteristic attribute in the multiple pieces of stored characteristic representations are collectively taken as one piece of mapping sub-information to obtain the multiple pieces of mapping sub-information.

6. The method according to claim 5, wherein: The storing the plurality of mapping sub-information in the non-volatile memory in a distributed storage manner includes: The plurality of mapping sub-information are stored in a plurality of data storage spaces in the non-volatile memory in a one-to-one correspondence.

7. The method according to claim 6, further comprising: For each mapping sub-information of the plurality of mapping sub-information, obtaining a transfer frequency value corresponding to the mapping sub-information; According to the transfer frequency value, the data storage space of the mapping sub-information in the non-volatile memory is changed.

8. The method according to claim 7, wherein: The obtaining of the plurality of mapping sub-information based on the plurality of storage feature representations includes: taking each storage feature representation in the plurality of storage feature representations as a mapping sub-information to obtain the plurality of mapping sub-information; and obtaining the transfer frequency value corresponding to the mapping sub-information includes: Obtaining a transfer frequency indication parameter of the mapping sub-information; wherein the transfer frequency indication parameter is used to control the frequency of changing the data storage space of the mapping sub-information in the non-volatile memory, and the transfer frequency indication parameter is positively correlated with the data security requirement of the second target data; the second target data is the key data corresponding to the mapping sub-information among the multiple key data; A transfer frequency value that is positively correlated with the transfer frequency indication parameter is obtained.

9. The method according to claim 8, wherein: The step of obtaining the transfer frequency indication parameter of the mapping sub-information includes: Obtaining a reading frequency of the second target data and / or a core degree index of the second target data; Based on the reading frequency of the second target data and / or the core degree index of the second target data, a transfer frequency indication parameter of the mapping sub-information is obtained.

10. The method according to any one of claims 1 to 9, wherein: The plurality of critical data include a first number of pieces of critical system software data and / or a second number of pieces of critical additional application data.

11. A data reading method, applied to a target device, the target device comprising a programmable device having a logic unit, the logic unit storing a plurality of key data of the target device, and the target device generating storage mapping information based on the storage mode of each key data of the plurality of key data in the logic unit; the method comprising: When the operating system of the target device is started, first target data is read from the plurality of key data stored in the logic unit based on the storage mapping information.

12. The method according to claim 11, wherein: The storage mapping information includes a plurality of storage feature representations corresponding to the plurality of key data one by one, and the target device is further used to obtain a plurality of mapping sub-information based on the plurality of storage feature representations; and store the plurality of mapping sub-information in a non-volatile memory of the target device in a distributed storage manner; The step of reading the first target data from the plurality of key data stored in the logic unit based on the storage mapping information includes: Reading the plurality of mapping sub-information from the non-volatile memory into the memory of the target device; Obtaining a target feature representation based on the plurality of mapping sub-information stored in the memory; Based on the target feature representation, first target data corresponding to the target feature representation is read from the plurality of key data stored in the logic unit.

13. A data storage device, applied to a target device, wherein the target device comprises a programmable device having a logic unit; the device comprises: A data acquisition unit, used to acquire multiple key data of the target device; A data storage unit, used for storing the plurality of key data in the logic unit; An information generation unit is used to generate storage mapping information based on the storage method of each of the multiple key data in the logical unit; wherein the storage mapping information is used to enable the target device to read the first target data from the multiple key data stored in the logical unit based on the storage mapping information after the operating system is started.

14. The device according to claim 13, wherein: The information generating unit is used to: For each key data of the plurality of key data, based on the storage mode of the key data in the logic unit, a storage characteristic representation of the key data is obtained; wherein the storage characteristic representation includes a plurality of subclass representation information with different characteristic attributes; Generate the storage mapping information; wherein the storage mapping information includes a plurality of storage feature representations corresponding one-to-one to the plurality of key data.

15. The device according to claim 14, wherein: The plurality of subclass representation information includes a storage location in the logic unit, and at least one of a file identifier, a file type, a file extension, a file size, and file verification information.

16. The apparatus according to claim 14, further comprising: An information allocation unit, configured to obtain a plurality of mapping sub-information based on the plurality of storage feature representations; A storage control unit, used for storing the multiple mapping sub-information in a non-volatile memory of the target device in a distributed storage manner; wherein the multiple mapping sub-information is used to enable the target device to read the multiple mapping sub-information from the non-volatile memory to the internal memory of the target device after the operating system is started; based on the multiple mapping sub-information stored in the internal memory, a target feature representation is obtained; based on the target feature representation, first target data corresponding to the target feature representation is read from the multiple key data stored in the logic unit.

17. The device according to claim 16, wherein: The information distribution unit is used for: Taking each of the plurality of storage feature representations as a mapping sub-information to obtain the plurality of mapping sub-information; Alternatively, the subclass representation information with the same characteristic attribute in the multiple pieces of stored characteristic representations are collectively taken as one piece of mapping sub-information to obtain the multiple pieces of mapping sub-information.

18. The device according to claim 17, wherein: The storage control unit is used for: The plurality of mapping sub-information are stored in a plurality of data storage spaces in the non-volatile memory in a one-to-one correspondence.

19. The apparatus according to claim 18, further comprising: A frequency value acquisition unit, configured to acquire, for each mapping sub-information in the plurality of mapping sub-information, a transfer frequency value corresponding to the mapping sub-information; The storage space control unit is used to change the data storage space of the mapping sub-information in the non-volatile memory according to the transfer frequency value.

20. The device according to claim 19, wherein The information allocation unit is used to use each of the multiple storage feature representations as a mapping sub-information to obtain the multiple mapping sub-information; the frequency value acquisition unit is used to: Obtaining a transfer frequency indication parameter of the mapping sub-information; wherein the transfer frequency indication parameter is used to control the frequency of changing the data storage space of the mapping sub-information in the non-volatile memory, and the transfer frequency indication parameter is positively correlated with the data security requirement of the second target data; the second target data is the key data corresponding to the mapping sub-information among the multiple key data; A transfer frequency value that is positively correlated with the transfer frequency indication parameter is obtained.

21. The device according to claim 20, wherein: The frequency value acquisition unit is used for: Obtaining a reading frequency of the second target data and / or a core degree index of the second target data; Based on the reading frequency of the second target data and / or the core degree index of the second target data, a transfer frequency indication parameter of the mapping sub-information is obtained.

22. The device according to any one of claims 13 to 21, wherein: The plurality of critical data include a first number of pieces of critical system software data and / or a second number of pieces of critical additional application data.

23. A data reading device, applied to a target device, the target device comprising a programmable device having a logic unit, the logic unit storing a plurality of key data of the target device, and the target device generating storage mapping information based on the storage mode of each key data of the plurality of key data in the logic unit; the device comprising: A data reading unit is used to read first target data from the multiple key data stored in the logic unit based on the storage mapping information when the operating system of the target device is started.

24. The device according to claim 23, wherein: The storage mapping information includes a plurality of storage feature representations corresponding to the plurality of key data one by one, and the target device is further used to obtain a plurality of mapping sub-information based on the plurality of storage feature representations; the plurality of mapping sub-information is stored in a non-volatile memory of the target device in a distributed storage manner; the data reading unit is used to: Reading the plurality of mapping sub-information from the non-volatile memory into the memory of the target device; Obtaining a target feature representation based on the plurality of mapping sub-information stored in the memory; Based on the target feature representation, first target data corresponding to the target feature representation is read from the plurality of key data stored in the logic unit.

25. An electronic device comprising: at least one processor; a memory communicatively coupled to the at least one processor; 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 perform the method according to any one of claims 1 to 12.

26. A non-transitory computer-readable storage medium storing computer instructions, wherein: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 12.

27. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the computer program implements the method according to any one of claims 1 to 12.