Data shielding method and device and computer readable storage medium

By mounting a blank folder into the data partition when the data partition of the electronic device is abnormal, shielding the damaged folder and starting the operating system, the problem of the device being unusable is solved, and data backup is performed after the system is started to ensure Security of user data and normal encryption and decryption operations of the file system.

CN118690399AActive Publication Date: 2024-09-24HUAWEI TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202310306175.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-03-21
Publication Date
2024-09-24
Estimated Expiration
2043-03-21

AI Technical Summary

Technical Problem

When the data partition is abnormal, electronic devices cannot be started or used normally, resulting in problems such as repeated restarts and black screens. Existing technologies may cause user data to be lost or file system encryption and decryption operations to fail when solving this problem.

Method used

By detecting abnormalities in the data partition, mount a blank folder to the data partition, shield potentially damaged folders, use unshielded folders to start the operating system, and perform data backup after the system starts successfully to ensure file system encryption. Independence of decryption operations.

Benefits of technology

It avoids the problem of device being unusable due to abnormal data partition, while retaining user data and ensuring the normal operation of file system encryption and decryption, avoiding data loss and system crash.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000
    Figure 00000000_0000
Patent Text Reader

Abstract

The invention provides a data shielding method and device and a computer readable storage medium, and relates to the technical field of terminals.The method comprises the steps that after it is detected that a first data partition mounted in a first directory is abnormal, the first directory is blocked; at least one blank folder corresponding to at least one first folder in the first data partition is mounted to at least one second directory, the first data partition supports the electronic equipment to start an operating system, and the blank folder is created in the second data partition; the at least one second directory is a subdirectory for mounting at least one first folder in the first directory; and starting the operating system by using the first directory. According to the technical scheme provided by the invention, the blank folder in the second data partition can be used for shielding the data in the first folder in the first data partition, so that the situation that the electronic equipment cannot be normally used due to starting abnormity of an operating system caused by file damage or data abnormity in the first folder is avoided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of terminal technology, and in particular to a data shielding method, device and computer-readable storage medium. Background Art

[0002] The operating system of an electronic device, such as the Android system, performs a large number of read and write operations on the user data stored in the specified data partition during startup and operation. If the data partition is abnormal, for example, the files stored in the data partition are damaged, or the third-party application data is abnormal, the operating system will not be able to start normally, causing the electronic device to restart repeatedly and unable to boot normally. It may also cause the electronic device to repeatedly crash or black screen after successfully booting, so that the electronic device cannot be used normally. Summary of the invention

[0003] In view of this, the present application provides a data shielding method, device and computer-readable storage medium, which to a certain extent solve the problem of device unusability due to data partition anomalies.

[0004] In order to achieve the above-mentioned purpose, in a first aspect, an embodiment of the present application provides a data shielding method, which is applied to an electronic device, and the method includes:

[0005] After detecting an abnormality in the first data partition mounted in the first directory, at least one blank folder corresponding to at least one first folder in the first data partition is mounted to at least one second directory, the first data partition supports the electronic device to start the operating system, the blank folder is created in the second data partition, and the at least one second directory is a subdirectory of the first directory in which at least one first folder is mounted respectively; the first directory is used to start the operating system.

[0006] The first directory may be related to user data in the file system, such as the / data directory. The first folder is a folder in the first data partition that is easily damaged, such as / data / app, / data / app-asec, / data / app-ephemeral, / data / app-lib, / data / app-private, / data / app-staging, / data / app_acc and other application-related folders, / data / cache, / data / dalvik-cache and other cache-related folders, etc. The number and selection of the first folders can be set based on experience.

[0007] Based on the data shielding method provided by the present application, in the case of an abnormality in the first data partition, a blank folder is mounted in the second directory (i.e., a subdirectory of the first directory) where at least one preset first folder is mounted, so as to shield the first folder mounted in the second directory that may be damaged, thereby ensuring that in the process of starting the operating system through the first directory, the electronic device cannot read the user data in the first folder. This avoids the problem that the operating system cannot be started or the electronic device cannot be used normally after startup due to abnormal user data in the first folder.

[0008] In some embodiments, after detecting that the first data partition mounted in the first directory is in an abnormal state, the method also includes: creating the second data partition, the second data partition is a blank data partition; creating folders on the second data partition with the same name as each of the first folders, to obtain at least one blank folder.

[0009] In some embodiments, at least one of the first folders does not include a folder related to file encryption and file decryption in the first data partition.

[0010] For example, in the Android system, the folders related to file encryption and file decryption may be the / data / misc folder that stores WIFI accounts and passwords, the / data / system_de folder that stores system keys, and the / data / user_de folder that stores user accounts. Normally, the data in the folders related to file encryption and file decryption will basically not have data anomalies. Since only the data in the first file that may have data anomalies is shielded in the first directory, no other operations are performed on the folders related to the system configuration, including the folders related to file encryption and file decryption. The data shielding operation is completely decoupled from the encryption and decryption operations of the file system, and they do not affect each other, that is, after the operating system is successfully started, regardless of whether the encryption and decryption process of the file system is updated, the first data partition and the folders related to file encryption and file decryption can be accessed through the first directory, thereby completing the encryption and decryption operations of the file system, such as supporting identity authentication during data backup.

[0011] In some embodiments, after the operating system is successfully started, the method further includes: displaying a data backup interface; and backing up user data mounted on the first directory in response to a first operation of the user on the data backup interface.

[0012] In some embodiments, after the operating system is successfully started, the method further includes: displaying a lock screen interface or a main interface.

[0013] In some embodiments, the method of detecting the abnormality of the first data partition includes: determining that the first data partition is abnormal when detecting that the number of restarts of the electronic device is greater than a preset number of restarts.

[0014] In some embodiments, the method of detecting the abnormality of the first data partition includes:

[0015] When a data masking instruction input by a user is detected, it is determined that the first data partition is abnormal.

[0016] This is for scenarios where the electronic device has a black screen or freezes after it is started.

[0017] In a second aspect, an embodiment of the present application provides an electronic device, comprising: a memory and a processor, the memory being used to store a computer program; the processor being used to execute the method described in the first aspect or any one of the embodiments of the first aspect when calling the computer program.

[0018] In a third aspect, an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the method described in the first aspect or any one of the embodiments of the first aspect is implemented.

[0019] In a fourth aspect, an embodiment of the present application provides a computer program product. When the computer program product runs on an electronic device, the electronic device executes the method described in the first aspect or any implementation method of the first aspect.

[0020] In a fifth aspect, an embodiment of the present application provides a chip system, including a processor, the processor is coupled to a memory, and the processor executes a computer program stored in the memory to implement the method described in the first aspect or any embodiment of the first aspect. The chip system can be a single chip or a chip module composed of at least one chip.

[0021] It can be understood that the beneficial effects of the second to fifth aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] Figure 1 A flow chart of a data shielding method provided in an embodiment of the present application;

[0023] Figure 2 A schematic diagram of a data backup interface provided in an embodiment of the present application;

[0024] Figure 3 A schematic diagram of the structure of a data shielding device provided in an embodiment of the present application;

[0025] Figure 4A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0026] The embodiments of the present application are described below in conjunction with the drawings in the embodiments of the present application. The terms used in the implementation method section of the embodiments of the present application are only used to explain the specific embodiments of the present application, and are not intended to limit the present application. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.

[0027] In order to facilitate understanding of the technical solutions in the embodiments of the present application, some of the terms involved in the embodiments of the present application are first explained below:

[0028] Data partition: Data partition refers to the storage area in the memory of an electronic device for storing user data, which can be driven and accessed as a block device. The so-called user data refers to the data created by the electronic device during use, such as data related to settings, contacts, information, and third-party applications.

[0029] During the boot process of the electronic device, the data partition can be mounted in a specified directory of the system kernel based on a mount mechanism during the kernel startup phase. For example, for the Android system, the data partition is mounted in the / data directory, so that the system kernel can access the data partition of the memory by accessing the / data directory, and implement read and write operations on the data partition.

[0030] Mounting: refers to identifying a storage partition as a block device and associating the block device with an existing directory (or folder) in the system kernel, so that the system kernel can access the storage partition through the directory. The directory is the mount point of the storage partition. Based on the mounting mechanism, when partition A is mounted on the mount point, the data stored in partition A can be read and written through the mount point. Afterwards, if partition B is mounted on the mount point, partition B can be accessed through the mount point but partition A cannot be accessed. It can be understood that the later mounted partition B will overwrite the earlier mounted partition A on the mount point.

[0031] Data partition abnormality: refers to the abnormality of user data stored in the data partition. For example, the electronic device loses power or resets abnormally during the boot process, causing some files in the data partition to be damaged, the user data is incompatible with the system software, and the data of the third-party application installed by the user is abnormal. Data partition abnormality often causes the electronic device to be unable to be used normally. For example, the operating system cannot be started normally, causing the electronic device to have a black screen or remain in the boot state (that is, the boot animation interface is always displayed), or repeatedly restart but cannot boot. Alternatively, the operating system starts normally and the electronic device can be successfully booted, but the electronic device always displays the lock screen interface and cannot receive the unlocking operation input by the user, and thus cannot display the main interface; the electronic device can be unlocked normally and display the main interface, but a black screen, crashes, or frequent restarts occur during use.

[0032] For data partition abnormality, the above problem can generally be solved by controlling the electronic device to restore factory settings, format or update the operating system version. However, this will cause permanent loss of user data.

[0033] Some solutions propose: during the kernel startup phase, a blank virtual data partition is mounted on the mount point of the original data partition, and the original data partition is mounted on the new mount point. After the operating system is successfully started using the virtual data partition, the data in the original data partition is backed up and then restored to factory settings. This ensures that the operating system is successfully started without losing user data. However, in this solution, when the version of the system's encryption and decryption process changes, even if the key is synchronized from the original data partition to the virtual data partition, the electronic device cannot use the key to perform operations related to encryption and decryption of the file system, resulting in the electronic device still not being able to start normally and the user still being unable to back up data.

[0034] To this end, the present application provides a data shielding method, which uses a blank folder to shield a first folder that may be damaged in a first data partition, and uses the remaining folders that are not shielded in the first data partition and the blank folder to start the operating system, thereby avoiding the problem that the electronic device cannot be used normally due to abnormal user data in the first folder.

[0035] The data shielding method provided by the present application is exemplarily described below in conjunction with specific embodiments.

[0036] Figure 1 A flowchart of a data shielding method provided in an embodiment of the present application is shown in FIG. Figure 1 As shown, the method may include:

[0037] S101, after detecting an abnormality in the first data partition mounted in the first directory, mount at least one blank folder corresponding to at least one first folder in the first data partition to at least one second directory, the blank folder is a blank folder created in the second data partition, and the second directory is a subdirectory of the first folder mounted in the first directory.

[0038] The first data partition is a partition that supports the electronic device to start and run the operating system and stores user data. For example, in the Android system, the first data partition can be a data partition, which is an internal memory of the electronic device, such as a partition in a random access memory (RAM).

[0039] The first folder is a preset folder in the first data partition. For example, the first folder may be a folder that is easily damaged and is determined based on big data statistics.

[0040] In the Android system, according to statistics, the folders related to third-party applications in the data partition, such as / data / app, / data / app-asec, / data / app-ephemeral, / data / app-lib, / data / app-private, / data / app-staging, / data / app_acc, etc., and the folders related to cache in the data partition, such as / data / cache, / data / dalvik-cache, etc., are folders with a high probability of file corruption, data anomalies, etc. The folders related to system configuration, such as / data / unencrypted, / data / misc, / data / system, / data / system_de, / data / vendor, / data / media, / data / data, / data / data, / data / user_de, etc., have a very low probability of file corruption, data anomalies, etc. Therefore, the first folder in the embodiment of the present application can be a folder related to third-party applications and a folder related to cache in the data partition.

[0041] The first directory is a directory in the system kernel that needs to be accessed when starting and running the operating system, and is used to mount the first data partition. For example, the first data partition may be a data partition, and the first directory may be the / data directory in the Android system. When the first data partition is mounted to the first directory, the electronic device can read the user data stored in the first data partition by accessing the first directory.

[0042] Correspondingly, the subdirectory in the first directory used to mount the first folder can be determined as the second directory.

[0043] In some embodiments, the electronic device can determine whether the first data partition is abnormal based on the number of restarts. For example, in a scenario where the electronic device repeatedly restarts during the boot process or repeatedly restarts during use, the electronic device can count the number of consecutive automatic restarts. When the number of consecutive automatic restarts of the electronic device exceeds a preset number of restarts, the electronic device can determine that the first data partition is abnormal.

[0044] For example, assuming that the preset number of restarts is 2, when the electronic device detects the third restart, it can be determined that the first data partition is abnormal, that is, during the third restart of the electronic device, the first folder shielding operation can be performed, that is, after mounting the first data partition in the first directory, the blank folder is mounted in the second directory.

[0045] In some embodiments, in the scenario where the electronic device has a black screen, freezes, or crashes, the electronic device may also determine that the first data partition is abnormal based on a data shielding instruction input by the user.

[0046] Exemplarily, the data shielding instruction may be input by the user based on a physical button on the electronic device, and the physical button may be a combination of one or more of the "volume +" button, the "volume -" button, and the "power" button set on the electronic device. For example, taking the "volume +" button as an example, the operation of triggering the data shielding instruction may be pressing the "volume +" button according to a preset duration, pressing the "volume +" button according to a preset number of times, pressing the "volume +" button and the "volume -" button according to a preset alternating pressing rule, pressing the "volume +" button and the "power" button according to a preset alternating pressing rule, pressing the "volume +" button and the "power" button and the "volume -" button according to a preset alternating pressing rule, etc. The specific operation can be set based on actual needs, and this application does not limit this.

[0047] When the electronic device detects that the user inputs a shielding instruction, the electronic device may restart and perform the first folder shielding operation during this restart process.

[0048] In some embodiments, the second data partition may be a pre-created blank data partition, and correspondingly, the blank folder may be a pre-created blank folder in the second data partition. The second data partition may be another partition of the RAM. Alternatively, since no data needs to be stored in the second data partition, the second data partition may also be a partition on a read-only memory (ROM). Of course, if an external memory card (e.g., a Micro SD card) is also extended in the electronic device, the second data partition may also be a partition on the external memory card.

[0049] For example, after the electronic device is powered on, during the system kernel startup phase, the system kernel starts the block device driver to drive the preset partitions in the internal memory. For example, the first data partition corresponds to the block device 43, defined by / dev / block / sda43, and the second data partition corresponds to the block device 45, defined by / dev / block / sda45.

[0050] After the first data partition and the second data partition complete the block device driver, the file system formats the block device 43 corresponding to the first data partition and the block device 45 corresponding to the second data partition by calling the formatting function to obtain a format corresponding to the file system. The file system first mounts the formatted first data partition to the first directory, and correspondingly, each folder in the first data partition is mounted to a directory with the same name in the first directory.

[0051] Taking the first folder / data / app in the first data partition as an example, the corresponding second directory is the / data / app directory. At this time, the mount path associated with the / data / app directory can be expressed as / dev / block / sda43 on / data / app. By accessing the / data / app directory, the electronic device can access the first data partition defined by the block device 43 and read the application data stored in the first folder / data / app.

[0052] When the electronic device determines that the first data partition is abnormal and completes mounting of the first data partition, the file system can mount a blank folder in the second data partition with the same name as the first folder to the second directory where the first folder is mounted.

[0053] For example, the second data partition includes a blank folder / data / app with the same name as the first folder / data / app. The file system mounts the blank folder / data / app into the / data / app directory. At this time, the mount path associated with the / data / app directory is changed to / dev / block / sda45 on / data / app. By accessing the / data / app directory, the electronic device can access the second data partition defined by the block device 45 and read the application data stored in the blank folder / data / app. Since the blank folder / data / app is a blank folder, the data read by the electronic device from the blank folder / data / app is empty.

[0054] Optionally, the second data partition may also be a virtual data partition temporarily created by the electronic device after determining that the first data partition is abnormal. For example, after the electronic device is powered on, during the system kernel startup phase, the system kernel starts the block device driver to drive the preset partitions in the internal memory. For example, the first data partition is defined by / dev / block / sda43. Then, by calling the formatting function, the block device corresponding to the first data partition is formatted to obtain a format corresponding to the file system. The file system first mounts the formatted first data partition into the first directory, and accordingly, each folder in the first data partition is mounted into a directory with the same name in the first directory.

[0055] Afterwards, the file system creates a second data partition by calling a block device creation operation. For example, a blank second data partition may be created on a RAM, or on a ROM, or, if an external memory card is also extended in the electronic device, a blank second data partition may be created on the external memory card. For example, the second data partition is defined by / dev / block / sda45.

[0056] After the second data partition is created, the system file formats the block device corresponding to the second data partition to obtain a format corresponding to the file system. Then, a blank folder with the same name as each first folder is created in the second data partition to obtain a blank folder corresponding to each first folder. Finally, the file system can mount the blank folder created in the second data partition to the second directory with the same name as the blank folder in the first directory.

[0057] Taking the first folder / data / app in the first data partition as an example, the corresponding second directory is the / data / app directory, and the name of the blank folder is / data / app. Before mounting the blank folder as / data / app on the / data / app directory, the mount path associated with the / data / app directory can be expressed as / dev / block / sda43 on / data / app. By accessing the / data / app directory, the electronic device can access the first data partition defined by the block device 43 and read the application data stored in the first folder / data / app.

[0058] After the blank folder / data / app is mounted on the directory / data / app, the mount path associated with the / data / app directory is changed to / dev / block / sda45 on / data / app. The electronic device can access the second data partition defined by the block device 45 by accessing the / data / app directory, and read the application data stored in the blank folder / data / app. Since the blank folder / data / app is a blank folder, the data read by the electronic device from the blank folder / data / app is empty.

[0059] S102, start the operating system using the first directory.

[0060] It is understandable that if the anomaly of the first data partition is caused by anomalies in one or more of the first folders, then after mounting a blank folder on the corresponding second directory, the abnormal data mounted on the first directory can be shielded, making the abnormal data unreadable. At this time, the user data that can be accessed using the first directory is the data in the first data partition that is not shielded.

[0061] Since the startup and operation of the operating system is not affected when the first data partition is empty, after shielding the first folder that may store abnormal data in the first data partition, the electronic device can successfully start the operating system based on the remaining folders and blank folders in the first data partition. In this way, the electronic device can be started and used normally on the basis of retaining the user data in the first data partition.

[0062] In some embodiments, at least one first folder does not include folders related to file encryption and file decryption. For example, in an Android system, a / data / misc folder stores WIFI accounts and passwords, a / data / system_de folder stores system keys, and a / data / user_de folder stores user accounts. Generally, data in folders related to file encryption and file decryption will not have data anomalies.

[0063] In this example, since only the data in the first file that may have data anomalies is shielded in the first directory, and no other operations are performed on the folders related to system configuration, including the folders related to file encryption and file decryption, the data shielding operation is completely decoupled from the encryption and decryption operations of the file system, and they do not affect each other, that is, after the operating system is successfully started, regardless of whether the encryption and decryption process of the file system is updated, the folders related to file encryption and file decryption in the first data partition can be accessed through the first directory, thereby completing the encryption and decryption operations of the file system.

[0064] In some embodiments, when the operating system is successfully started, the electronic device can pull up the lock screen interface according to the conventional process. After the user unlocks the device, the data backup application can be manually started to back up the user data mounted on the first directory. For example, click the icon of the data backup application on the desktop of the electronic device to start the data backup function.

[0065] In some embodiments, the user can select the user data to be backed up through the relevant interface provided by the data backup application, or directly back up all the user data mounted on the first directory by default. It is understandable that, since the application data in the first folder mounted on the first directory has been shielded, the data backup application cannot read the application data in the first folder, thus avoiding the backup of possibly abnormal application data.

[0066] The data backup application can back up the application data to the memory of the electronic device, for example, an external memory card. The application can also back up the application data to other electronic devices (for example, a computer) after the electronic device is connected to other electronic devices (for example, a computer), and this application does not limit this.

[0067] After completing the data backup, the user can choose to format the first data partition to restore the first data partition to factory settings to delete all data stored in the first data partition, and then restore the backed up user data to restore the data of other folders except the first folder in the first data partition.

[0068] Optionally, after the user unlocks the lock screen, the user can also directly delete the potentially damaged application data in the first directory through applications such as Phone Manager, File Manager, and Settings.

[0069] In some embodiments, when the operating system is successfully started, the electronic device may also directly enter the emergency backup mode, that is, the operating system first starts the data backup application and displays the data backup interface.

[0070] Exemplarily, the data backup interface can be as follows Figure 2 As shown, it includes an "Emergency Backup" button. If the user inputs a first operation on the data backup interface, such as clicking the "Emergency Backup" button, the electronic device can respond to the user's first operation on the data backup interface and back up the user data mounted on the first directory.

[0071] Optionally, the data backup interface may further include a "restore factory settings" button. If the user enters a second operation on the data backup interface, such as clicking the "restore factory settings" button, the electronic device can directly format the first data partition in response to the user's second operation on the data backup interface.

[0072] Optionally, the data backup interface may also include a "skip" button, etc. If the user inputs a third operation on the data backup interface, such as clicking the "skip" button, the electronic device can respond to the user's third operation on the data backup interface, exit the emergency backup mode, and display the lock screen interface.

[0073] It should be noted that when the electronic device is performing data backup or restoring factory settings, if user authentication is required, then since the folders related to file encryption and file decryption in the first data partition can still be accessed normally through the first directory, the electronic device can perform data backup or restore factory settings normally.

[0074] It will be understood that the user interface described in the embodiments of the present application is merely an example and is not intended to limit the present application. In some embodiments, the user interface displayed by the electronic device may include more or fewer interface elements than shown in the diagram to implement more or fewer functions. Each function may also be implemented using other interface elements or in other user interfaces, and this embodiment does not specifically limit this.

[0075] Those skilled in the art will appreciate that the above embodiments are exemplary and are not intended to limit the present application. Where possible, the execution order of one or more of the above steps may be adjusted, or may be selectively combined to obtain one or more other embodiments. Those skilled in the art may select and combine any of the above steps as needed, and all those that do not depart from the essence of the present application fall within the scope of protection of the present application.

[0076] Based on the same concept, as an implementation of the above method, an embodiment of the present application provides a data shielding device, and the device embodiment corresponds to the aforementioned method embodiment. For ease of reading, the present device embodiment will no longer repeat the details of the aforementioned method embodiment one by one, but it should be clear that the device in this embodiment can correspond to all the contents in the aforementioned method embodiment.

[0077] Figure 3 A schematic diagram of the structure of a data shielding device provided in an embodiment of the present application is shown in FIG. Figure 3 As shown, the device provided in this embodiment includes:

[0078] Display module 310 , input module 320 , processing module 330 and communication module 340 .

[0079] The display module 310 is used to support the electronic device to perform the interface display operation in the above embodiment and / or other processes for the technology described herein. The display module can be a touch screen or other hardware or a combination of hardware and software.

[0080] The input module 320 is used to receive user input on the electronic device, such as touch input, voice input, gesture input, key input, etc. The input module is used to support the electronic device to perform the steps of receiving user operations in the above embodiments and / or other processes for the technology described herein. The input module can be a touch screen or other hardware or a combination of hardware and software.

[0081] The processing module 330 is used to support the electronic device in executing the processing operations in the steps of the methods in the above embodiments and / or other processes used for the technology described herein.

[0082] The communication module 340 is used to support the electronic device in executing operations related to the communication process between other electronic devices in the above embodiments and / or other processes used for the technology described herein.

[0083] The device provided in this embodiment can execute the above method embodiment, and its implementation principle and technical effect are similar, which will not be repeated here.

[0084] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.

[0085] Based on the same concept, the present application also provides an electronic device, see Figure 4 , Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.

[0086] The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0087] It is to be understood that the structure illustrated in the embodiment of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0088] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Different processing units may be independent devices or integrated into one or more processors.

[0089] The controller may be the nerve center and command center of the electronic device 100. The controller may generate an operation control signal according to the instruction operation code and the timing signal to complete the control of fetching and executing instructions.

[0090] The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.

[0091] In some embodiments, the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.

[0092] The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). The I2S interface can be used for audio communication. The PCM interface can also be used for audio communication to sample, quantize and encode analog signals. The UART interface is a universal serial data bus for asynchronous communication; the bus can be a bidirectional communication bus, which converts the data to be transmitted between serial communication and parallel communication. The MIPI interface can be used to connect the processor 110 with peripheral devices such as the display screen 194 and the camera 193; the MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. The GPIO interface can be configured by software, and the GPIO interface can be configured as a control signal or a data signal. The USB interface 130 is an interface that complies with the USB standard specification, and can specifically be a Mini USB interface, a MicroUSB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the electronic device 100, and can also be used to transmit data between the electronic device 100 and peripheral devices. It can also be used to connect headphones and play audio through them. This interface can also be used to connect other electronic devices, such as AR devices.

[0093] It is understandable that the interface connection relationship between the modules illustrated in the embodiment of the present application is only a schematic illustration and does not constitute a structural limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.

[0094] The charging management module 140 is used to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger through the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive wireless charging input through a wireless charging coil of the electronic device 100. While the charging management module 140 is charging the battery 142, it may also power the electronic device through the power management module 141.

[0095] The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, and supplies power to the processor 110, the internal memory 121, the external memory, the display screen 194, the camera 193, and the wireless communication module 160. The power management module 141 can also be used to monitor parameters such as battery capacity, battery cycle number, battery health status (leakage, impedance), etc. In some other embodiments, the power management module 141 can also be set in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 can also be set in the same device.

[0096] The wireless communication function of the electronic device 100 can be implemented through the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor and the baseband processor.

[0097] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.

[0098] The mobile communication module 150 can provide solutions for wireless communications including 2G / 3G / 4G / 5G, etc., applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, and filter, amplify, and process the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the same device as at least some of the modules of the processor 110.

[0099] The modem processor may include a modulator and a demodulator. Among them, the modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor outputs a sound signal through an audio device (not limited to a speaker 170A, a receiver 170B, etc.), or displays an image or video through a display screen 194. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 110 and be set in the same device as the mobile communication module 150 or other functional modules.

[0100] The wireless communication module 160 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication technology (NFC), infrared technology (IR), etc., which are applied to the electronic device 100. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the frequency of the electromagnetic wave signal and performs filtering processing, and sends the processed signal to the processor 110. The wireless communication module 160 can also receive the signal to be sent from the processor 110, modulate the frequency of it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2.

[0101] In some embodiments, the antenna 1 of the electronic device 100 is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time division-synchronous code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technology, etc. The GNSS may include a global positioning system (GPS), a global navigation satellite system (GNSS), a Beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS) and / or a satellite based augmentation system (SBAS).

[0102] The electronic device 100 implements the display function through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or change display information.

[0103] The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light emitting diode or an active-matrix organic light emitting diode (AMOLED), a flexible light-emitting diode (FLED), Mini LED, Micro LED, quantum dot light emitting diodes (QLED), etc. In some embodiments, the electronic device 100 may include 1 or N display screens 194, where N is a positive integer greater than 1.

[0104] The electronic device 100 can realize the shooting function through ISP, camera 193, video codec, GPU, display screen 194 and application processor.

[0105] The ISP is used to process data fed back by the camera 193. The camera 193 is used to capture static images or videos. The digital signal processor is used to process digital signals. In addition to processing digital image signals, it can also process other digital signals. The video codec is used to compress or decompress digital videos.

[0106] NPU is a neural network (NN) computing processor. By drawing on the structure of biological neural networks, such as the transmission mode between neurons in the human brain, it can quickly process input information and can also continuously self-learn. Through NPU, applications such as intelligent cognition of electronic device 100 can be realized, such as image recognition, face recognition, voice recognition, text understanding, etc.

[0107] The internal memory 121 can be used to store computer executable program codes, which include instructions. The processor 110 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area can store an operating system, and at least one application required for a function (such as a sound playback function, an image playback function, etc.). The data storage area can store data created during the use of the electronic device 100 (such as audio data, a phone book, etc.). In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc.

[0108] The external memory interface 120 can be used to connect an external memory, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function, such as storing music, video and other files in the external memory card.

[0109] The electronic device 100 can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0110] The audio module 170 is used to convert digital audio information into analog audio signal output, and is also used to convert analog audio input into digital audio signal. The audio module 170 can also be used to encode and decode audio signals. In some embodiments, the audio module 170 can be arranged in the processor 110, or some functional modules of the audio module 170 are arranged in the processor 110. The speaker 170A, also known as the "speaker", is used to convert audio electrical signals into sound signals. The receiver 170B, also known as the "earpiece", is used to convert audio electrical signals into sound signals. The microphone 170C, also known as the "microphone" and "microphone", is used to convert sound signals into electrical signals. The headphone interface 170D is used to connect wired headphones. The headphone interface 170D can be a USB interface 130, or it can be a 3.5mm open mobile electronic equipment platform (open mobile terminal platform, OMTP) standard interface, and the cellular telecommunications industry association of the USA (cellular telecommunications industry association of the USA, CTIA) standard interface.

[0111] The button 190 includes a power button, a volume button, etc. The button 190 can be a mechanical button. It can also be a touch button. The electronic device 100 can receive the button input and generate a key signal input related to the user settings and function control of the electronic device 100. The motor 191 can generate a vibration prompt. The motor 191 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. The indicator 192 can be an indicator light, which can be used to indicate the charging status, power changes, messages, missed calls, notifications, etc. The SIM card interface 195 is used to connect the SIM card. The SIM card can be inserted into the SIM card interface 195, or pulled out from the SIM card interface 195 to achieve contact and separation with the electronic device 100. The electronic device 100 can support 1 or N SIM card interfaces, where N is a positive integer greater than 1. The SIM card interface 195 can support Nano SIM cards, Micro SIM cards, SIM cards, etc.

[0112] The electronic device provided in this embodiment can execute the above method embodiment, and its implementation principle and technical effect are similar, which will not be repeated here.

[0113] The embodiment of the present application also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the method described in the above method embodiment is implemented.

[0114] The embodiment of the present application also provides a computer program product. When the computer program product is run on an electronic device, the electronic device implements the method described in the above method embodiment when executing the computer program product.

[0115] The present application also provides a chip system, including a processor, the processor is coupled to a memory, and the processor executes a computer program stored in the memory to implement the method described in the above method embodiment. The chip system can be a single chip or a chip module composed of multiple chips.

[0116] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions may be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk or a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state disk (SSD)), etc.

[0117] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by computer programs to instruct related hardware, and the programs can be stored in computer-readable storage media. When the programs are executed, they can include the processes of the above-mentioned method embodiments. The aforementioned storage media can include: ROM or random access memory RAM, magnetic disk or optical disk and other media that can store program codes.

[0118] The naming or numbering of the steps in this application does not mean that the steps in the method flow must be executed in the time / logical sequence indicated by the naming or numbering. The named or numbered process steps can change the execution order according to the technical purpose to be achieved, as long as the same or similar technical effects can be achieved.

[0119] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0120] In the embodiments provided in the present application, it should be understood that the disclosed devices / equipment and methods can be implemented in other ways. For example, the device / equipment embodiments described above are merely schematic, for example, the division of the modules or units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.

[0121] It should be understood that in the description of the present application specification and the appended claims, the terms "include", "comprises", "have" and any variations thereof are intended to cover non-exclusive inclusions and mean "including but not limited to", unless otherwise specifically emphasized. For example, a process, method, system, product or device that includes a series of steps or modules is not necessarily limited to those steps or modules that are clearly listed, but may include other steps or modules that are not clearly listed or inherent to these processes, methods, products or devices.

[0122] In the description of this application, unless otherwise specified, " / " indicates that the objects associated before and after are in an "or" relationship, for example, A / B can represent A or B; "and / or" in this application is used to describe the association relationship of associated objects, indicating that there can be three relationships, for example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. Unless otherwise specified, "multiple" means two or more than two. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can represent: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or plural.

[0123] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.

[0124] In addition, in the description of the present specification and the appended claims, the terms "first", "second", etc. are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence, nor can they be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments described herein can be implemented in an order other than that illustrated or described herein; the features defined as "first" or "second" may explicitly or implicitly include at least one of the features.

[0125] In the embodiments of the present application, the words "exemplarily" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described as "exemplarily" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplarily" or "for example" is intended to present related concepts in a specific way.

[0126] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the phrases "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. appearing in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways.

[0127] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A data shielding method, applied to electronic equipment, characterized in that: The method comprises: After detecting that the first data partition mounted in the first directory is abnormal, mounting at least one blank folder corresponding to at least one first folder in the first data partition to at least one second directory, the first data partition supports the electronic device to boot the operating system, the blank folder is created in the second data partition, and the at least one second directory is a subdirectory of the first directory where at least one first folder is mounted respectively; The operating system is started using the first directory.

2. The data shielding method according to claim 1, characterized in that: After detecting that the first data partition mounted in the first directory is in an abnormal state, the method further includes: Creating the second data partition, where the second data partition is a blank data partition; Folders having the same name as each of the first folders are created on the second data partition to obtain at least one blank folder.

3. The data shielding method according to claim 1 or 2, characterized in that: At least one of the first folders does not include a folder related to file encryption and file decryption in the first data partition.

4. The data shielding method according to any one of claims 1 to 3, characterized in that: After the operating system is successfully started, the method further includes: Display the data backup interface; In response to a first operation performed by the user on the data backup interface, the user data mounted on the first directory is backed up.

5. The data shielding method according to any one of claims 1 to 4, characterized in that: The method of detecting the abnormality of the first data partition includes: When it is detected that the number of restarts of the electronic device is greater than a preset number of restarts, it is determined that the first data partition is abnormal.

6. The data shielding method according to any one of claims 1 to 4, characterized in that: The method of detecting the abnormality of the first data partition includes: When a data masking instruction input by a user is detected, it is determined that the first data partition is abnormal.

7. An electronic device, characterized in that: include: A memory and a processor, wherein the memory is used to store a computer program; and the processor is used to execute the data shielding method according to any one of claims 1 to 6 when calling the computer program.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the data shielding method according to any one of claims 1 to 6 is implemented.

9. A computer program product, characterized in that When the computer program product runs on an electronic device, the electronic device executes the data shielding method according to any one of claims 1 to 6.

10. A chip system, characterized in that: The chip system includes a processor, which is coupled to a memory. The processor executes a computer program stored in the memory to implement the data shielding method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Method and device for system booting

    CN107766089A

  • System starting method and device, electronic equipment and storage medium

    CN109710317A

  • Data backup method and terminal

    CN111373379A

  • System upgrading method, terminal and storage medium

    CN111522566A

  • Directory mounting method and computing equipment

    CN115686364A