System mode control method and storage device

By monitoring the time interval information of the storage device and calculating the power consumption assessment, the time threshold is dynamically adjusted to control it to enter a low-power consumption mode, which solves the problems of energy waste and performance degradation caused by traditional fixed time thresholds, and achieves more effective power consumption management. .

CN118349187BActive Publication Date: 2024-09-17HEFEI KAIMENG TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410764371.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-14
Publication Date
2024-09-17
Estimated Expiration
2044-06-14

AI Technical Summary

Technical Problem

The traditional low-power mode implementation uses a fixed time threshold, which lacks flexibility and cannot be adjusted according to the actual usage of the device, resulting in energy waste and performance degradation in some cases.

Method used

By monitoring the status of the storage device within a time range, multiple time interval information is obtained, the power consumption evaluation information of the candidate time threshold is calculated based on this information, the target time threshold is determined, and the storage device is controlled based on the threshold when it is in idle mode. Enter low power mode.

Benefits of technology

Without affecting the performance of the storage device as much as possible, the power consumption of the storage device during operation is effectively reduced, and additional power consumption caused by excessively frequent entry and exit of the low-power mode is avoided.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118349187B
    Figure CN118349187B
Patent Text Reader

Abstract

The present invention provides a system mode control method and a storage device. The method comprises: monitoring the state of a storage device within a time range to obtain a plurality of time interval information, wherein each time interval information reflects the time length between a first time point when the storage device processes a previous instruction and a second time point when the storage device obtains a next instruction within the time range; obtaining power consumption evaluation information corresponding to a plurality of candidate time thresholds according to the plurality of time interval information; determining one of the plurality of candidate time thresholds as a first target time threshold according to the power consumption evaluation information; and when the storage device is in an idle mode, controlling the storage device to enter a low power consumption mode according to the first target time threshold. Thus, the power consumption of the storage device during operation can be effectively reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a control technology of a storage device, and in particular to a system mode control method and a storage device. Background Art

[0002] Storage devices including flash memory are non-volatile storage devices, which are widely used in electronic devices such as memory cards, solid-state drives, and portable multimedia players. Low power design is an important research field in modern electronic devices, especially in the firmware design of storage devices. The firmware usually switches to low power mode when the system is idle for a long time to save energy and extend the life of the device.

[0003] The traditional way to implement low power mode is to set a fixed time threshold. When the device is inactive within this time threshold, it will automatically enter the low power state. However, this fixed threshold method lacks flexibility and cannot be adjusted according to the actual use of the device. In some cases, it may waste energy and reduce device performance. For example, when the idle time of the system is much longer than the set time threshold, if the time threshold is not adjusted, it will cause higher power consumption. Summary of the invention

[0004] The present invention provides a system mode control method and a storage device, which can improve the above-mentioned problem and effectively reduce the power consumption of the storage device during operation without affecting the performance of the storage device as much as possible.

[0005] An embodiment of the present invention provides a system mode control method for a storage device, the system mode control method comprising: monitoring the state of the storage device within a time range to obtain a plurality of time interval information, wherein each time interval information in the plurality of time interval information reflects the length of time between a first time point when the storage device completes processing a previous instruction and a second time point when the storage device executes a next instruction within the time range; obtaining a plurality of power consumption evaluation information corresponding to a plurality of candidate time thresholds based on the plurality of time interval information; determining a first target time threshold among the plurality of candidate time thresholds based on the power consumption evaluation information; and when the storage device is in an idle mode, controlling the storage device to enter a low power consumption mode based on the first target time threshold.

[0006] An embodiment of the present invention further provides a storage device, which includes a connection interface unit, a memory module and a memory controller. The connection interface unit is used to connect to a host system. The memory controller is connected to the connection interface unit and the memory module. The memory controller is used to: monitor the state of the storage device within a time range to obtain multiple time interval information, wherein each time interval information in the multiple time interval information reflects the time length between the first time point when the storage device processes the previous instruction and the second time point when the next instruction is obtained within the time range; obtain multiple power consumption evaluation information corresponding to multiple candidate time thresholds based on the multiple power consumption evaluation information; determine the first target time threshold among the multiple candidate time thresholds based on the multiple power consumption evaluation information; and when the storage device is in idle mode, control the storage device to enter low power consumption mode according to the first target time threshold. BRIEF DESCRIPTION OF THE DRAWINGS

[0007] Figure 1 is a schematic diagram of a storage device according to an embodiment of the present invention;

[0008] Figure 2 is a schematic diagram of a management memory module according to an embodiment of the present invention;

[0009] Figure 3 is a schematic diagram showing a storage device operating in different system modes at different time points according to an embodiment of the present invention;

[0010] Figure 4 is a schematic diagram of monitoring the state of a storage device within a preset time range to obtain multiple time interval information according to an embodiment of the present invention;

[0011] Figure 5 is a schematic diagram of power consumption evaluation information corresponding to multiple candidate time thresholds according to an embodiment of the present invention;

[0012] Figure 6 is a schematic diagram of tabular data according to an embodiment of the present invention;

[0013] Figure 7 is a flow chart of a system mode control method according to an embodiment of the present invention. DETAILED DESCRIPTION

[0014] Reference will now be made in detail to exemplary embodiments of the present invention, examples of which are illustrated in the accompanying drawings. Whenever possible, the same reference numerals are used in the drawings and the description to refer to the same or like parts.

[0015] Figure 1is a schematic diagram of a memory storage device according to an embodiment of the present invention. Figure 1 The data storage system includes a storage device 10 and a host system 11. The host system 11 can be any type of computer system, such as a smart phone, a tablet computer, a notebook computer, a desktop computer, an industrial computer, a game console, a server or a vehicle-mounted computer, etc., and the type of the host system 11 is not limited thereto.

[0016] The storage device 10 is connected to the host system 11 and is used to store data from the host system 11. For example, the storage device 10 may include a solid state drive, a USB flash drive, a memory card, or other types of non-volatile storage devices. The host system 11 may communicate with the storage device 10 through an embedded Multi-Media Card (embedded Multi-Media Card, eMMC), a universal flash memory (Universal FlashStorage, UFS), a fast peripheral component interconnect (Peripheral Component Interconnect Express, PCIExpress), a fast non-volatile memory (Non-Volatile Memory Express, NVM express), a serial advanced technology attachment (Serial Advanced Technology Attachment, SATA), a universal serial bus (Universal Serial Bus, USB) or other types of connection interface standards. Therefore, the host system 11 can store data to the storage device 10 and / or read data from the storage device 10.

[0017] The storage device 10 includes a connection interface unit 101, a memory module 102, and a memory controller 103. The connection interface unit 101 is used to connect the storage device 10 to the host system 11. For example, the connection interface unit 101 may support connection interface standards such as eMMC, UFS, PCI Express, NVM express, SATA, PCI Express, or USB. The storage device 10 can communicate with the host system 11 (e.g., exchange signals, instructions, and / or data) via the connection interface unit 101.

[0018] The memory module 102 is used to store data. The memory module 102 may include one or more rewritable non-volatile memory modules. Each rewritable non-volatile memory module may include one or more memory cell arrays. The memory cells in the memory cell array store data in the form of voltage (also called threshold voltage). For example, the memory module 102 may include a single level cell (SLC) NAND type flash memory module, a multi level cell (MLC) NAND type flash memory module, a triple level cell (TLC) NAND type flash memory module, a quad level cell (QLC) NAND type flash memory module and / or other memory modules having the same or similar characteristics.

[0019] The memory controller 103 is connected to the connection interface unit 101 and the memory module 102. The memory controller 103 can be regarded as the control core of the memory device 10 and is used to control the memory device 10. For example, the memory controller 103 can be responsible for controlling and / or managing the entire or partial operation of the memory device 10. For example, the memory controller 103 may include a central processing unit (CPU), or other programmable general-purpose or special-purpose microprocessors, digital signal processors (DSP), programmable controllers, application specific integrated circuits (ASIC), programmable logic devices (PLD) or other similar devices or combinations of these devices. In one embodiment, the memory controller 103 includes a flash memory controller.

[0020] In one embodiment, the memory controller 103 may further include a buffer memory, a power management circuit, an encoding circuit, a decoding circuit and / or various other types of circuit modules, which are not limited by the present invention. The buffer memory is used to cache data. The power management circuit is used to manage the power of the storage device 10. The encoding circuit is used to encode the data to be stored in the memory module 102 to generate an error correction code (and / or an error checking code). The decoding circuit is used to decode the data read from the memory module 102 to correct possible errors in the read data. For example, the encoding circuit and / or the decoding circuit may use various encoding / decoding algorithms such as Low Density Parity Check Code (LDPC code), BCH code, Reed-Solomon code (RS code), Exclusive OR (XOR) code, etc. to encode and decode data.

[0021] The memory module 102 may receive a command sequence from the memory controller 103 and access the storage unit according to the command sequence. For example, when data is to be stored, the memory controller 103 may send a write command sequence to the memory module 102 to instruct the memory module 102 to store the data in a specific storage unit. When data is to be read, the memory controller 103 may send a read command sequence to the memory module 102 to instruct the memory module 102 to read data from a specific storage unit. When data is to be deleted, the memory controller 103 may send an erase command sequence to the memory module 102 to instruct the memory module 102 to erase the data stored in the specific storage unit. In addition, the memory controller 103 may also send other types of command sequences to the memory module 102 to instruct the memory module 102 to perform corresponding operations, which is not limited by the present invention.

[0022] Figure 2 FIG. 1 is a schematic diagram of a management memory module according to an embodiment of the present invention. Figure 1 and Figure 2 The memory module 102 includes a plurality of physical units 201 ( 1 ) to 201 (B). Each physical unit includes a plurality of storage cells and is used for non-volatile storage of data.

[0023] In one embodiment, a physical unit may include one or more physical programming units. For example, a physical programming unit may include multiple physical sectors. For example, the data capacity of a physical sector may be 512 bytes (Bytes, B), and a physical programming unit may include 8 physical sectors. However, the data capacity of a physical sector and / or the total number of physical sectors included in a physical programming unit can be adjusted according to practical needs, and the present invention is not limited thereto. In one embodiment, a physical programming unit can be regarded as a physical page. For example, the data capacity of a physical programming unit may be 4 kilobytes (4KB), and the present invention is not limited thereto.

[0024] In one embodiment, a physical programming unit is the minimum unit for synchronously writing data in the memory module 102. For example, when a programming operation is performed on a physical programming unit to write data to the physical programming unit, multiple memory cells in the physical programming unit can be synchronously programmed to store corresponding data. For example, when programming a physical programming unit, a write voltage can be applied to the physical programming unit to change the threshold voltage of at least part of the memory cells in the physical programming unit. The threshold voltage of each memory cell can reflect the bit data stored in the memory cell.

[0025] In one embodiment, a physical erase unit may include a plurality of physical programming units. A plurality of storage cells in a physical erase unit may be erased synchronously. For example, when performing an erase operation on a physical erase unit, an erase voltage may be applied to a plurality of physical programming units in the physical erase unit to change the threshold voltage of at least a portion of the storage cells in these physical programming units and clear the bit data stored in these physical programming units.

[0026] In one embodiment, the memory controller 103 may logically associate the physical units 201(1)-201(A) with the data area 21 and associate the physical units 201(A+1)-201(B) with the spare area 22. The physical units 201(1)-201(A) in the data area 21 are used to store data (also referred to as user data) from the host system 11. For example, each physical unit in the data area 21 may store valid data and / or invalid data. In addition, the physical units 201(A+1)-201(B) in the spare area 22 do not store data.

[0027] In one embodiment, if a physical unit does not store valid data, the physical unit can be associated with the idle area 22. In one embodiment, the idle area 22 is also called a free pool. In addition, the physical unit associated with the idle area 22 can be erased to clear the data in the physical unit.

[0028] In one embodiment, when data (i.e., user data) from the host system 11 needs to be stored, the memory controller 103 may select one or more physical units from the idle area 22 and instruct the memory module 102 to store the data from the host system 11 into the selected physical units. At the same time, the selected physical units may be associated with the data area 21.

[0029] In one embodiment, the memory controller 103 may configure a plurality of logical units 202 (1) to 202 (C) to map the physical units 201 (1) to 201 (A) in the data area 21. For example, a logical unit may correspond to a logical block address (LBA) or other logical management units. A logical unit may be mapped to one or more physical units in the data area 21.

[0030] In one embodiment, if a physical unit is currently mapped by any logical unit, the memory controller 103 may determine that the data currently stored in the physical unit includes valid data. Conversely, if a physical unit is not currently mapped by any logical unit, the memory controller 103 may determine that the physical unit does not currently store any valid data (and / or the data in the physical unit are all invalid data).

[0031] In one embodiment, the memory controller 103 may record the mapping relationship between the logical unit and the physical unit in a logical-to-physical mapping table. When receiving an access instruction (such as a read instruction, a write instruction, a delete instruction, or other types of instructions) from the host system 11, the memory controller 103 may instruct the memory module 102 to perform a corresponding operation behavior according to the information in the logical-to-physical mapping table.

[0032] In one embodiment, the memory controller 103 may control the storage device 10 to operate in one of a normal operating mode, an idle mode, and a low power consumption mode. In one embodiment, in the normal operating mode, the memory controller 103 may perform corresponding operation behaviors according to instructions (also referred to as commands) from the host system 11. For example, according to a read instruction from the host system 11, the memory controller 103 may send a read instruction sequence to the memory module 102 to read data from the memory module 102. According to a write instruction from the host system 11, the memory controller 103 may send a write instruction sequence to the memory module 102 to write data to the memory module 102. Alternatively, according to an erase instruction from the host system 11, the memory controller 103 may send an erase instruction sequence to the memory module 102 to erase data from the memory module 102. In addition, according to other types of instructions from the host system 11, the memory controller 103 may control the storage device 10 to perform other types of operation behaviors, which are not limited by the present invention.

[0033] In one embodiment, in the normal working mode, after a certain instruction is processed (i.e., an operation behavior for a certain instruction is completed), the storage device 10 may automatically enter the idle mode. In the idle mode, the storage device 10 may be in an idle state. For example, in the idle mode, the memory controller 103 does not perform any operation behavior for any instruction from the host system 11. In particular, the power consumption of the storage device 10 in the idle mode may be lower than the power consumption of the storage device 10 in the normal working mode. For example, this power consumption may be positively correlated with the power consumption per unit time of the storage device 10.

[0034] In one embodiment, in the idle mode, the memory controller 103 may determine whether the cumulative time length of the memory device 10 operating in the idle mode reaches (e.g., is greater than or equal to) a time threshold (also referred to as a switching time threshold). If the cumulative time length reaches the switching time threshold, the memory controller 103 may control the system of the memory device 10 to enter a low power consumption mode. In particular, the power consumption of the memory device 10 in the low power consumption mode may be lower than the power consumption of the memory device 10 in the idle mode. However, if the cumulative time length does not reach (e.g., is less than) the switching time threshold, the memory controller 103 may not control the memory device 10 to enter the low power consumption mode.

[0035] In one embodiment, when entering the idle mode, the memory controller 103 may start a timer. The timing value of this timer may reflect the cumulative length of time that the storage device 10 operates in the idle mode. In one embodiment, the memory controller 103 may compare this timing value with the switching time threshold. If this timing value reaches the switching time threshold, the memory controller 103 may control the storage device 10 to enter the low power mode. However, if this timing value does not reach the switching time threshold, the memory controller 103 may not control the system of the storage device 10 to enter the low power mode.

[0036] In one embodiment, in the low power mode, when receiving an instruction from the host system 11, the memory controller 103 can control the storage device 10 to exit the low power mode and return to the normal working mode. After returning to the normal working mode, the memory controller 103 can execute the operation behavior corresponding to the instruction in the normal working mode.

[0037] Figure 3 is a schematic diagram showing a storage device operating in different system modes at different time points according to an embodiment of the present invention. Figure 3 In one embodiment, it is assumed that at time point T(1), the memory controller 103 has processed instruction A. After time point T(1), the storage device 10 may automatically enter the idle mode. After entering the idle mode, it is assumed that at time point T(2), the memory controller 103 determines that the cumulative length of time that the storage device 10 operates in the idle mode reaches the switching time threshold. After time point T(2), the memory controller 103 controls the storage device 10 to enter the low power mode. For example, between time points T(2) and T(3) (i.e., within the time range ΔT(1)), the memory controller 103 controls the storage device 10 to perform preparation operations for entering the low power mode. For example, within the time range ΔT(1), the memory controller 103 may shut down some electronic circuits in the storage device 10 and / or adjust the operating parameters of some electronic circuits in the storage device 10. At time point T(3), the memory controller 103 completes the preparation operations for entering the low power mode. After time point T(3), the storage device 10 begins to operate in the low power mode. For example, between time points T( 3 ) and T( 4 ), the storage device 10 operates in the low power consumption mode.

[0038] In one embodiment, it is assumed that at time point T(4), the memory controller 103 obtains instruction B. Between time points T(4) and T(5) (i.e., within the time range ΔT(2)), the memory controller 103 performs preparation operations for exiting the low power mode. For example, within the time range ΔT(2), the memory controller 103 may start some electronic circuits in the storage device 10 and / or adjust the operating parameters of some electronic circuits in the storage device 10 to restore the storage device 10 to the normal operating mode. At time point T(5), the memory controller 103 completes the preparation operations for exiting the low power mode. After time point T(5), the storage device 10 operates again in the normal operating mode to execute the operation corresponding to instruction B.

[0039] It should be noted that in Figure 3 In the embodiment, although the power consumption of the storage device 10 operating in the low power mode may be lower than the power consumption of the storage device 10 operating in the idle mode, the memory controller 103 will also generate additional power consumption when performing the preparation operation of entering and exiting the low power mode. Therefore, in practice, in addition to the possibility that the storage device 10 will never enter the low power mode due to the switching time threshold being set too large, the storage device 10 may also be unable to enter the low power mode due to the switching time threshold being set too small, so that the storage device 10 performs the preparation operation of entering and exiting the low power mode too frequently, resulting in an increase in the power consumption of the storage device 10 instead of a decrease. Both of the above defective states violate the original purpose of setting the low power mode to reduce the power consumption of the storage device 10. Therefore, how to effectively maintain the practicality of the low power mode under the variable command transmission environment between the host system 11 and the storage device 10, and avoid the additional power consumption of the storage device 10 caused by excessively frequent entry and exit of the low power mode, is one of the issues that those skilled in the art need to work on improving.

[0040] In one embodiment, the memory controller 103 may monitor the state of the storage device 10 within a time range to obtain a plurality of time interval information. For example, each of the plurality of time interval information may reflect the length of time between the time point at which the storage device 10 completes processing of a previous instruction (also referred to as a first time point) and the time point at which the next instruction is obtained (also referred to as a second time point) within the time range. Figure 3 For example, the first time point and the second time point may be time points T(1) and T(4) respectively. However, the time length between the first time point and the second time point reflected by each of these time interval information may be at least partially the same or different, and the present invention is not limited thereto.

[0041] In one embodiment, the memory controller 103 may configure multiple time thresholds (also referred to as candidate time thresholds). The multiple candidate time thresholds may be different. In one embodiment, the memory controller 103 may set one of the multiple candidate time thresholds as the switching time threshold.

[0042] It can be understood that for the acquisition of candidate time thresholds, the time interval information with the longest duration is divided equally according to the preset shares, and one divided time duration is used as a candidate time threshold, and two divided time durations are used as another candidate time threshold, and so on. The present application does not make any specific restrictions here.

[0043] In one embodiment, the memory controller 103 may obtain multiple power consumption assessment information corresponding to the multiple candidate time thresholds according to the multiple time interval information. For example, the power consumption assessment information may at least reflect the total power consumption of the storage device 10 estimated within the time range if a candidate time threshold among the multiple candidate time thresholds is used as the switching time threshold. For example, this total power consumption may include, within the time range, the sum of the power consumption of the estimated storage device 10 operating in idle mode, the power consumption of the storage device 10 operating in low power mode, and the power consumption of the storage device 10 performing preparation operations for entering and exiting the low power mode. In one embodiment, the memory controller 103 may determine one of the multiple candidate time thresholds as the first target time threshold according to the power consumption assessment information. In one embodiment, the memory controller 103 may determine the first target time threshold among the multiple candidate time thresholds according to the multiple power consumption assessment information. It should be noted that the first target time threshold is the candidate time threshold corresponding to the power consumption assessment information that performs best among the multiple power consumption assessment information. Thereafter, when the storage device 10 is in the idle mode, the memory controller 103 may control the storage device 10 to enter the low power mode (or maintain the idle mode) according to the first target time threshold. For details on how to control the storage device 10 to enter the low power mode according to the first target time threshold, please refer to Figure 3 In the embodiment, the first target time threshold is used as the switching time threshold, which is not repeated here.

[0044] In one embodiment, each power consumption assessment information reflects the estimated total power consumption of the storage device within the time range when the corresponding candidate time threshold is used as the switching time threshold, wherein the switching time threshold is the time length for the storage device to enter the low power consumption mode from the idle mode.

[0045] In one embodiment, the memory controller 103 may use each of the candidate time thresholds as a switching time threshold to calculate the first total power consumption corresponding to the plurality of time interval information. Then, the memory controller 103 may determine each of the first total power consumption as the power consumption evaluation information corresponding to the candidate time threshold.

[0046] In one embodiment, the memory controller 103 may use each of the candidate time thresholds as a switching time threshold, and divide the idle duration, mode conversion duration, and low power consumption duration in the multiple time interval information. The memory controller 103 may obtain the idle mode power consumption value, the mode conversion power consumption value, and the low power consumption mode power consumption value according to the idle duration, the mode conversion duration, and the low power consumption duration. Then, the memory controller 103 may determine the first total power consumption corresponding to each of the candidate time thresholds according to the idle mode power consumption value, the mode conversion power consumption value, and the low power consumption mode power consumption value.

[0047] In one embodiment, if the multiple candidate time thresholds include a first candidate time threshold and a second candidate time threshold, the power consumption assessment information includes power consumption assessment information corresponding to the first candidate time threshold (also referred to as first power consumption assessment information) and power consumption assessment information corresponding to the second candidate time threshold (also referred to as second power consumption assessment information). The first power consumption assessment information may reflect the estimated total power consumption of the storage device 10 within the time range (also referred to as the first candidate total power consumption) if the first candidate time threshold is used as the switching time threshold. In addition, the second power consumption assessment information may reflect the estimated total power consumption of the storage device 10 within the time range (also referred to as the second candidate total power consumption) if the second candidate time threshold is used as the switching time threshold.

[0048] It can be understood that the first candidate time threshold and the second candidate time threshold are only defined for the convenience of explaining the present application and are not specifically limited.

[0049] In one embodiment, the memory controller 103 may obtain an idle mode power consumption value (also referred to as a first idle mode power consumption value), a mode conversion power consumption value (also referred to as a first mode conversion power consumption value), and a low power mode power consumption value (also referred to as a first low power mode power consumption value) according to the plurality of time interval information and the first candidate time threshold. The first idle mode power consumption value, the first mode conversion power consumption value, and the first low power mode power consumption value may sequentially reflect, if the first candidate time threshold is used as the switching time threshold, the estimated power consumption of the memory device 10 operating in the idle mode within the time range, the power consumption of the memory device 10 performing the preparation operation of entering and exiting the low power mode within the time range, and the power consumption of the memory device 10 operating in the low power mode within the time range. Then, the memory controller 103 may obtain the first power consumption evaluation information according to the sum of the first idle mode power consumption value, the first mode conversion power consumption value, and the first low power mode power consumption value.

[0050] In one embodiment, the memory controller 103 may obtain another idle mode power consumption value (also referred to as a second idle mode power consumption value), another mode conversion power consumption value (also referred to as a second mode conversion power consumption value), and another low power mode power consumption value (also referred to as a second low power mode power consumption value) according to the plurality of time interval information and the second candidate time threshold. The second idle mode power consumption value, the second mode conversion power consumption value, and the second low power mode power consumption value may sequentially reflect, if the second candidate time threshold is used as the switching time threshold, the estimated power consumption of the memory device 10 operating in the idle mode within the time range, the power consumption of the memory device 10 performing the preparation operation of entering and exiting the low power mode within the time range, and the power consumption of the memory device 10 operating in the low power mode within the time range. Then, the memory controller 103 may obtain the second power consumption evaluation information according to the sum of the second idle mode power consumption value, the second mode conversion power consumption value, and the second low power mode power consumption value.

[0051] In one embodiment, the memory controller 103 may compare the first power consumption assessment information with the second power consumption assessment information to obtain a comparison result. According to the comparison result, the memory controller 103 may determine one of the first candidate time threshold and the second candidate time threshold as the first target time threshold.

[0052] In one embodiment, the comparison result may reflect that the first candidate total power consumption is greater than the second candidate total power consumption or the first candidate total power consumption is less than the second candidate total power consumption. In one embodiment, if the comparison result reflects that the first candidate total power consumption is greater than the second candidate total power consumption, the memory controller 103 may determine the second candidate time threshold as the first target time threshold. Alternatively, in one embodiment, if the comparison result reflects that the first candidate total power consumption is less than the second candidate total power consumption, the memory controller 103 may determine the first candidate time threshold as the first target time threshold.

[0053] In one embodiment, the memory controller 103 may compare a plurality of the power consumption assessment information to obtain target power consumption assessment information, wherein the target power consumption assessment information is power consumption assessment information reflecting the lowest total power consumption of the storage device within the time range among the plurality of the power consumption assessment information. Then, the memory controller 103 may determine the candidate time threshold corresponding to the target power consumption assessment information as the first target time threshold.

[0054] Figure 4 is a schematic diagram of monitoring the state of a storage device within a preset time range to obtain multiple time interval information according to an embodiment of the present invention. Figure 4 , assuming that within a preset time range, the memory controller 103 completes processing of the previous instruction at time point TP(1) and obtains the next instruction at time point TP(1)', completes processing of the previous instruction at time point TP(i) and obtains the next instruction at time point TP(i)', and completes processing of the previous instruction at time point TP(n) and obtains the next instruction at time point TP(n)'. Between time points TP(i) and TP(i)' (i.e., within the time range ΔTP(i)), the storage device 10 may operate in an idle mode or may enter a low power consumption mode. Wherein, i is between 1 and n.

[0055] In one embodiment, the memory controller 103 may monitor the state of the storage device 10 within the time range to obtain a plurality of time interval information 41(1)-41(n). The time interval information 41(i) corresponds to the time range ΔTP(i). For example, the time interval information 41(i) may reflect the time length of the time range ΔTP(i). It should be noted that the time lengths corresponding to the time ranges ΔTP(1)-ΔTP(n) may be different or at least partially the same, and the present invention is not limited thereto.

[0056] Figure 5 FIG. 1 is a schematic diagram of power consumption evaluation information corresponding to multiple candidate time thresholds according to an embodiment of the present invention. Figure 5 , continued by Figure 4 In the embodiment of the present invention, the memory controller 103 may set a plurality of time thresholds THR(1)-THR(m). Each of the time thresholds THR(1)-THR(m) is a candidate time threshold.

[0057] In one embodiment, the memory controller 103 may Figure 4The power consumption evaluation information W(1)~W(m) is obtained by using the time interval information 41(1)~41(n). The power consumption evaluation information W(j) corresponds to the time threshold THR(j), and j is between 1 and m. In particular, the power consumption evaluation information W(j) can reflect the estimated total power consumption of the storage device 10 within the time range if the time threshold THR(j) is used as the switching time threshold.

[0058] In one embodiment, the memory controller 103 may compare the power consumption assessment information W(1)-W(m) with each other to obtain a comparison result. The memory controller 103 may determine one of the time thresholds THR(1)-THR(m) as the first target time threshold based on the comparison result. For example, assuming that the comparison result reflects that the total power consumption corresponding to the power consumption assessment information W(j) is the lowest, the memory controller 103 may determine the time threshold THR(j) as the first target time threshold.

[0059] In one embodiment, taking the power consumption assessment information W(j) as an example, the memory controller 103 may obtain the power consumption assessment information W(j) according to the time interval information 41(1)-41(n) and the time threshold THR(j). For example, the memory controller 103 may obtain the power consumption assessment information W(j) according to the following equation (1.1).

[0060] W(j)=W1(j)+W2(j)+W3(j) (1.1)

[0061] In equation (1.1), parameters W1(j), W2(j), and W3(j) represent, in sequence, if the time threshold THR(j) is used as the switching time threshold, the estimated power consumption of the storage device 10 operating in the idle mode, the power consumption of the storage device 10 performing the preparation operation of entering and exiting the low power mode, and the power consumption of the storage device 10 operating in the low power mode within the time range. In one embodiment, parameters W1(j), W2(j), and W3(j) may be referred to as the idle mode power consumption value, the mode switching power consumption value, and the low power mode power consumption value, in sequence. It should be noted that equation (1.1) may also be adjusted according to practical needs, and the present invention is not limited thereto.

[0062] In one embodiment, the memory controller 103 may classify each of the time interval information 41(1)-41(n) into first-category time interval information and second-category time interval information according to the time threshold THR(j). The time length reflected by the first-category time interval information is shorter than the time threshold THR(j). The time length reflected by the second-category time interval information is longer than or equal to the time threshold THR(j). The memory controller 103 may obtain the power consumption assessment information W(j) according to the total number of the first-category time interval information and / or the total number of the second-category time interval information.

[0063] In one embodiment, the memory controller 103 may obtain the parameters W1(j), W2(j), and W3(j) in equation (1.1) according to the following equations (2.1) to (2.3).

[0064] W1(j)=T1×P1+THR(j)×N×P1 (2.1)

[0065] W2(j)=N×WT (2.2)

[0066] W3(j)=(T2-THR(j)×N-TE×N)×P2 (2.3)

[0067] In equations (2.1) to (2.3), parameter T1 represents the time length reflected by the first type of time interval information in the time interval information 41 (1) to 41 (n), parameter P1 represents the power consumption per unit time of the storage device 10 operating in the idle mode, parameter N represents the total number of the second type of time interval information in the time interval information 41 (1) to 41 (n), parameter WT represents the power consumption of the storage device 10 performing the preparation operation for entering and exiting the low power mode, parameter T2 represents the time length reflected by the second type of time interval information in the time interval information 41 (1) to 41 (n), parameter TE represents the time required for the storage device 10 to enter the low power mode, and parameter P2 represents the power consumption per unit time of the storage device 10 operating in the low power mode. It should be noted that equations (2.1) to (2.3) can also be adjusted according to practical needs, and the present invention is not limited thereto.

[0068] It should be noted that the above formula (2.3) is applicable to the second type of time interval information whose time length is greater than or equal to THR(j)+TE, that is, the sum of the corresponding candidate time interval and the time required to enter the low power mode; when there is a second type of time interval information whose time length is less than THR(j)+TE, the number M of such second type of time interval information and the time length T3 reflected are determined, and the above formula (2.3) can be rewritten as:

[0069] W3(j)=(T2-T3-THR(j)×(NM)-TE×(NM))×P2 (2.3)

[0070] In one embodiment, the memory controller 103 may obtain counting information (also referred to as first-type counting information) corresponding to the first candidate time threshold and counting information (also referred to as second-type counting information) corresponding to the second candidate time threshold according to the plurality of time interval information. For example, the memory controller 103 may associate each of the plurality of time interval information with one of the plurality of candidate time thresholds and update the counting information corresponding to the candidate time threshold. For example, the memory controller 103 may associate at least one of the plurality of time interval information (also referred to as first time interval information) with the first candidate time threshold and update the first-type counting information accordingly. The updated first-type counting information may reflect the total number of the first time interval information. In addition, the memory controller 103 may associate at least one of the plurality of time interval information (also referred to as second time interval information) with the second candidate time threshold and update the second-type counting information accordingly. The updated second-type counting information may reflect the total number of the second time interval information.

[0071] In one embodiment, the memory controller 103 may apply a specific algorithm corresponding to the first candidate time threshold according to the first type of counting information, the second type of counting information, the first candidate time threshold, and the second candidate time threshold to obtain the first power consumption evaluation information. In addition, the memory controller 103 may apply a specific algorithm corresponding to the second candidate time threshold according to the first type of counting information, the second type of counting information, the first candidate time threshold, and the second candidate time threshold to obtain the second power consumption evaluation information.

[0072] In one embodiment, the memory controller 103 may obtain counting information corresponding to each of the candidate time thresholds according to the plurality of time interval information, wherein each counting information reflects the number of time interval information associated with the corresponding candidate time threshold in the plurality of time interval information. Then, the memory controller 103 may obtain a plurality of the power consumption assessment information corresponding to the plurality of candidate time thresholds according to the counting information and the candidate time threshold.

[0073] Figure 6 is a schematic diagram of table data according to an embodiment of the present invention. Figure 6 In one embodiment, the memory controller 103 may be configured according to Figure 4 The table data 61 is established based on the time interval information 41(1)-41(n). The table data 61 can be used to record the counting information C(1)-C(m) corresponding to the time thresholds THR(1)-THR(m). For example, the counting information C(j) corresponds to the time threshold THR(j). In one embodiment, the table data 61 can also be used to record the power consumption evaluation information W(1)-W(m).

[0074] In one embodiment, the memory controller 103 may associate the time interval information 41(1)-41(n) one by one with one of the time thresholds THR(1)-THR(m). For example, the memory controller 103 may associate the time interval information 41(1)-41(n) that is relatively close to the time threshold THR(j) with the time threshold THR(j). Then, the memory controller 103 may update the count information C(j) corresponding to the time threshold THR(j). The updated count information C(j) may reflect how many time interval information 41(1)-41(n) are associated with the time threshold THR(j). In addition, the sum of the updated count information C(1)-C(m) may be the same as the total number of the time interval information 41(1)-41(n). For example, assume that the total number of the time interval information 41(1)-41(n) is "10" (i.e., n=10), and the total number of the time thresholds THR(1)-THR(m) is "3" (i.e., m=3). The counting information C(1) may reflect that N(1) time interval information is respectively associated with the time threshold THR(1), the counting information C(2) may reflect that N(2) time interval information is respectively associated with the time threshold THR(2), the counting information C(3) may reflect that N(3) time interval information is respectively associated with the time threshold THR(3), and the sum of N(1), N(2) and N(3) is "10".

[0075] Generally, the memory controller 103 may associate each of the multiple time interval information with the closest candidate time threshold and update the corresponding count information. In addition, the time interval information greater than the previous candidate time threshold and less than or equal to the next candidate time threshold may be associated with the next candidate time threshold and update the corresponding count information.

[0076] In one embodiment, the memory controller 103 may obtain the power consumption evaluation information W(j) by applying an algorithm corresponding to the time threshold THR(j) according to the time threshold THR(1)-THR(m) and the counting information C(1)-C(m). For example, the memory controller 103 may obtain the power consumption evaluation information W(j) according to the following equations (3.1)-(3.4).

[0077] W(j)=W1(j)+W2(j)+W3(j) (3.1)

[0078] (3.2)

[0079] (3.3)

[0080] (3.4)

[0081] In equations (3.1) to (3.4), parameter P1 represents the power consumption per unit time of the storage device 10 operating in the idle mode, parameter WT represents the power consumption of the storage device 10 performing the preparation operation of entering and exiting the low power mode, parameter TE represents the time required for the storage device 10 to enter the low power mode, and parameter P2 represents the power consumption per unit time of the storage device 10 operating in the low power mode. It should be noted that equations (3.1) to (3.4) can also be adjusted according to practical needs, and the present invention is not limited thereto.

[0082] In one embodiment, for different time thresholds THR(j), the constant j and the time threshold THR(j) in equations (3.1) to (3.4) can be adjusted accordingly to obtain the corresponding power consumption assessment information W(j). Thus, through equations (3.1) to (3.4), power consumption assessment information W(1) to W(m) can be obtained. It should be noted that equations (3.1) to (3.4) can also be adjusted according to practical needs, and the present invention is not limited thereto.

[0083] In one embodiment, the memory controller 103 may use each of the candidate time thresholds as a switching time threshold, determine that other candidate time thresholds less than the switching time threshold are idle mode times, and other candidate time thresholds greater than the switching time threshold are low power mode times. The memory controller 103 may obtain the first power consumption according to each of the idle mode times and the corresponding counting information, the switching time threshold and the corresponding counting information, and the counting information corresponding to the low power mode time; obtain the second power consumption according to the switching time threshold and the counting information corresponding to the low power mode time; and obtain the third power consumption according to each of the low power mode times and the corresponding counting information and the switching time threshold. For example, the parameters W1(j), W2(j), and W3(j) in equation (3.1) may correspond to the first power consumption, the second power consumption, and the third power consumption, respectively. Then, the memory controller 103 may determine the power consumption evaluation information corresponding to each of the candidate time thresholds according to the first power consumption, the second power consumption, and the third power consumption. For example, the memory controller 103 may obtain the power consumption evaluation information W(j) corresponding to each of the candidate time thresholds according to equations (2.1) to (2.3) or (3.1) to (3.4).

[0084] By calculating the power consumption evaluation information of each candidate time threshold through the above method, the requirement on the system computing capability can be reduced, thereby reducing the occupation of system computing resources and improving the computing speed.

[0085] like Figure 6As shown, if the candidate time threshold THR(j) is selected as the switching time threshold, the corresponding counting information is C(j), then THR(1)~THR(j-1) is the candidate time threshold named as the idle mode time, and the corresponding counting information is C(1)~C(j-1); THR(j+1)~THR(m) is the candidate time threshold named as the low power mode time, and the corresponding counting information is C(j+1)~C(m).

[0086] In one embodiment, the memory controller 103 may obtain the total duration of the storage device being in the idle mode based on each of the idle mode time, the switching time threshold, the low power mode time, and the corresponding counting information. The first power consumption is obtained according to the idle power and the total duration of the storage device being in the idle mode. For details, refer to equations (2.1) and (3.2), and the present invention is not limited thereto.

[0087] In one embodiment, the memory controller 103 may obtain the second power consumption based on the mode switching power consumption and the counting information corresponding to the switching time threshold and the low power mode time. For details, please refer to equations (2.2) and (3.3), and the present invention is not limited thereto.

[0088] In one embodiment, the memory controller 103 may obtain the total duration of the storage device 10 being in the low power mode based on each of the low power mode times and the corresponding count information and the switching time threshold. The memory controller 103 may obtain the third power consumption according to the low power consumption power and the total duration of the storage device 10 being in the low power mode. For details, refer to equations (2.3) and (3.4), and the present invention is not limited thereto.

[0089] Specifically, as shown in (3.4), when calculating the total time the storage device is in low power mode, the time TE for entering low power mode needs to be excluded. Therefore, the above formula (3.4) is applicable to the time length of the low power mode time that is greater than or equal to THR(j)+TE, that is, the sum of the corresponding switching time interval and the time required to enter low power mode; when there is a low power mode time with a time length less than THR(j)+TE, the first low power mode time THR(H) with a time length greater than or equal to THR(j)+TE is determined, and the above formula (3.4) can be rewritten as:

[0090] (3.4)

[0091] In one embodiment, the memory controller 103 may determine whether the total number of the time interval information 41(1)-41(n) detected or stored has reached (e.g., is greater than or equal to) a preset number. If the total number of the time interval information 41(1)-41(n) has reached the preset number, the memory controller 103 may perform the aforementioned operation of setting or adjusting the first target time threshold. The details of the operation of how to set or adjust the first target time threshold have been described above and will not be repeated here. However, if the total number of the time interval information 41(1)-41(n) has not reached the preset number, the memory controller 103 may temporarily not perform the aforementioned operation of setting or adjusting the first target time threshold.

[0092] In one embodiment, the memory controller 103 may determine whether the cumulative operation time of the storage device 10 has reached (e.g., is greater than or equal to) a preset time. The cumulative operation time of the storage device 10 may refer to the cumulative time length from the time point when the storage device 10 was last powered on or powered on to the current time point. If the cumulative operation time of the storage device 10 has reached the preset time, the memory controller 103 may perform the aforementioned operation of setting or adjusting the first target time threshold. However, if the cumulative operation time of the storage device 10 has not reached the preset time, the memory controller 103 may temporarily not perform the aforementioned operation of setting or adjusting the first target time threshold.

[0093] In one embodiment, by adjusting the first target time threshold at an appropriate time, the practicality of the low power mode can be effectively maintained in a variable command transmission environment between the host system 11 and the storage device 10, and additional power consumption of the storage device 10 caused by excessively frequent entry and exit of the low power mode can be avoided.

[0094] In one embodiment, the memory controller 103 may acquire a second target time threshold, which is greater than all time interval information. In one embodiment, when the storage device 10 is in the low power consumption mode, the memory controller 103 may control the storage device 10 to exit the low power consumption mode according to the second target time threshold.

[0095] In one embodiment, in the low power mode, the memory controller 103 may determine whether the cumulative time length after the storage device 10 enters the idle mode and the low power mode reaches (e.g., is greater than or equal to) a time threshold (i.e., the second target time threshold). If the cumulative time length reaches the second target time threshold, the memory controller 103 may control the storage device 10 to exit the low power mode early and return to the idle mode. However, if the cumulative time length does not reach (e.g., is less than) the second target time threshold, the memory controller 103 may not control the storage device 10 to exit the low power mode early.

[0096] In one embodiment, the memory controller 103 may determine whether the counting information (also referred to as the third type of counting information) corresponding to the terminal candidate time threshold (also referred to as the third candidate time threshold) of the plurality of candidate time thresholds meets the preset condition. If the third type of counting information meets the preset condition, the memory controller 103 may update the second target time threshold according to the third candidate time threshold. However, if the third type of counting information does not meet the preset condition, the memory controller 103 may not update the second target time threshold.

[0097] It can be understood that the terminal candidate time threshold is a candidate time threshold that is greater than a preset time length.

[0098] In one embodiment, the third type of counting information may include counting information C(m) and / or C(m-1). The memory controller 103 may determine whether the counting information C(m) reaches (e.g., is greater than or equal to) a preset value. If the counting information C(m) reaches the preset value, the memory controller 103 may determine that the counting information C(m) meets the preset condition and update the second target time threshold according to the time threshold THR(m). For example, when the counting information C(m) meets the preset condition, the memory controller 103 may update the second target time threshold to the time threshold THR(m) minus the parameter TO. The parameter TO represents the time required for the storage device 10 to exit the low power mode. Thereafter, when the storage device 10 is in the low power mode, the memory controller 103 may control the storage device 10 to exit the low power mode according to the second target time threshold. However, if the counting information C(m) does not reach the preset value, the memory controller 103 may determine that the counting information C(m) does not meet the preset condition.

[0099] In one embodiment, if the counting information C(m) does not reach the preset value, the memory controller 103 may further determine whether the sum of the counting information C(m) and C(m-1) reaches the preset value. If the sum of the counting information C(m) and C(m-1) reaches the preset value, the memory controller 103 may determine that the counting information C(m) and C(m-1) meet the preset conditions and update the second target time threshold according to the time threshold THR(m-1). For example, when the counting information C(m) and C(m-1) meet the preset conditions, the memory controller 103 may update the second target time threshold to the time threshold THR(m-1) minus the parameter TO.

[0100] In one embodiment, by reducing the second target time threshold at an appropriate time, the storage device 10 can execute the preparation operation for exiting the low power mode earlier. Thereafter, when a new instruction is obtained, since the storage device 10 has executed (or even completed) the preparation operation for exiting the low power mode earlier, the storage device 10 can return to the normal working mode more quickly.

[0101] Figure 7is a flow chart of a system mode control method according to an embodiment of the present invention. Figure 7 In step S701, the state of the storage device within a time range is monitored to obtain multiple time interval information, wherein each time interval information reflects the length of time between a first time point when the storage device completes processing a previous instruction and a second time point when the storage device obtains a next instruction within the time range. In step S702, multiple power consumption evaluation information corresponding to multiple candidate time thresholds are obtained based on the multiple time interval information. In step S703, a first target time threshold among the multiple candidate time thresholds is determined based on the power consumption evaluation information. In step S704, when the storage device is in an idle mode, the storage device is controlled to enter a low power consumption mode based on the first target time threshold.

[0102] In one embodiment, the step of obtaining multiple power consumption assessment information corresponding to multiple candidate time thresholds based on the multiple time interval information includes: taking each of the candidate time thresholds as a switching time threshold, calculating the first total power consumption corresponding to the multiple time interval information; and determining each of the first total power consumption as the power consumption assessment information corresponding to the candidate time threshold.

[0103] In one embodiment, the step of taking each of the candidate time thresholds as a switching time threshold and calculating the first total power consumption corresponding to the multiple time interval information includes: taking each of the candidate time thresholds as a switching time threshold, dividing the idle duration, mode conversion duration and low power consumption duration in the multiple time interval information; obtaining the idle mode power consumption value, mode conversion power consumption value and low power consumption mode power consumption value according to the idle duration, mode conversion duration and low power consumption duration; and determining the first total power consumption corresponding to each of the candidate time thresholds according to the idle mode power consumption value, the mode conversion power consumption value and the low power consumption mode power consumption value.

[0104] In one embodiment, the step of obtaining multiple power consumption assessment information corresponding to multiple candidate time thresholds based on the multiple time interval information includes: obtaining counting information corresponding to each candidate time threshold based on the multiple time interval information, wherein each counting information reflects the number of time interval information in the multiple time interval information associated with the corresponding candidate time threshold; and obtaining multiple power consumption assessment information corresponding to the multiple candidate time thresholds based on the counting information and the candidate time threshold.

[0105] In one embodiment, the step of obtaining counting information corresponding to each candidate time threshold according to the plurality of time interval information includes: associating each time interval information in the plurality of time interval information to the closest candidate time threshold and updating the corresponding counting information.

[0106] In one embodiment, the step of obtaining multiple power consumption assessment information corresponding to multiple candidate time thresholds according to the counting information and the candidate time threshold includes: taking each of the candidate time thresholds as a switching time threshold, determining that other candidate time thresholds less than the switching time threshold are idle mode times, and other candidate time thresholds greater than the switching time threshold are low power consumption mode times; obtaining first power consumption according to each idle mode time and the corresponding counting information, the switching time threshold and the corresponding counting information, and the counting information corresponding to the low power consumption mode time; obtaining second power consumption according to the switching time threshold and the counting information respectively corresponding to the low power consumption mode time; obtaining third power consumption according to each low power consumption mode time and the corresponding counting information and the switching time threshold; determining power consumption assessment information corresponding to each candidate time threshold according to the first power consumption, the second power consumption and the third power consumption.

[0107] In one embodiment, according to each of the idle mode time and the corresponding counting information, the switching time threshold and the corresponding counting information, and the counting information corresponding to the low power mode time, the step of obtaining the first power consumption includes: based on each of the idle mode time, the switching time threshold, the low power mode time, and the corresponding counting information, obtaining the total duration of the storage device in the idle mode; according to the idle power and the total duration of the storage device in the idle mode, obtaining the first power consumption; according to the switching time threshold and the counting information respectively corresponding to the low power mode time, the step of obtaining the second power consumption includes: based on the mode switching power consumption and the switching time threshold and the counting information respectively corresponding to the low power mode time, obtaining the second power consumption; according to each of the low power mode time and the corresponding counting information and the switching time threshold, the step of obtaining the third power consumption includes: based on each of the low power mode time and the corresponding counting information and the switching time threshold, obtaining the total duration of the storage device in the low power mode; according to the low power consumption power and the total duration of the storage device in the low power mode, obtaining the third power consumption.

[0108] In one embodiment, based on the power consumption assessment information, the step of determining a first target time threshold among the multiple candidate time thresholds includes: comparing the multiple power consumption assessment information to obtain target power consumption assessment information, wherein the target power consumption assessment information is the power consumption assessment information among the multiple power consumption assessment information that reflects the lowest total power consumption of the storage device within the time range; and determining the candidate time threshold corresponding to the target power consumption assessment information as the first target time threshold.

[0109] In one embodiment, the system mode control method further includes: obtaining a second target time threshold, the second target time threshold being greater than all time interval information; and when the storage device is in the low power consumption mode, controlling the storage device to exit the low power consumption mode according to the second target time threshold.

[0110] However, Figure 7 The steps in the above are described in detail, so I will not repeat them here. It is worth noting that Figure 7 Each step in the above process can be implemented as multiple program codes or circuits, and the present invention is not limited thereto. Figure 7 The method can be used in conjunction with the above exemplary embodiments or can be used alone, and the present invention is not limited thereto.

[0111] In summary, the system mode control method and storage device provided by the present invention can adjust the first target time threshold at an appropriate time. Therefore, in the variable command transmission environment between the host system 11 and the storage device 10, the practicality of the low power mode can be effectively maintained, and the additional power consumption of the storage device 10 caused by excessively frequent entry and exit of the low power mode can be avoided. In addition, the system mode control method and storage device provided by the present invention can also adjust the second target time threshold at an appropriate time. Therefore, the efficiency of the subsequent storage device 10 returning to the normal working mode can be improved.

[0112] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention 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 invention.

Claims

1. A system mode control method, characterized in that: For a storage device, the system mode control method comprises: Monitoring the state of the storage device within a time range to obtain a plurality of time interval information, wherein each time interval information of the plurality of time interval information reflects the length of time between a first time point when the storage device completes processing a previous instruction and a second time point when the storage device obtains a next instruction within the time range; According to the multiple time interval information, obtain multiple power consumption evaluation information corresponding to multiple candidate time thresholds; Determine a first target time threshold among the plurality of candidate time thresholds according to the plurality of power consumption evaluation information; and When the storage device is in an idle mode, controlling the storage device to enter a low power consumption mode according to the first target time threshold; Wherein, determining, according to the multiple power consumption evaluation information, the first target time threshold among the multiple candidate time thresholds includes: Comparing the plurality of power consumption assessment information to obtain target power consumption assessment information, wherein the target power consumption assessment information is power consumption assessment information reflecting the lowest total power consumption of the storage device within the time range among the plurality of power consumption assessment information; The candidate time threshold corresponding to the target power consumption assessment information is determined as the first target time threshold.

2. The system mode control method according to claim 1, characterized in that: Each of the power consumption assessment information respectively reflects the estimated total power consumption of the storage device within the time range if the corresponding candidate time threshold is used as the switching time threshold, wherein the switching time threshold is the time length for the storage device to enter the low power consumption mode from the idle mode.

3. The system mode control method according to claim 2, characterized in that: The step of obtaining a plurality of power consumption evaluation information corresponding to a plurality of candidate time thresholds according to the plurality of time interval information comprises: Taking each of the candidate time thresholds as the switching time threshold, calculating the first total power consumption corresponding to the plurality of time interval information; and Determine each of the first total power consumptions as the power consumption evaluation information corresponding to the candidate time threshold.

4. The system mode control method according to claim 3, characterized in that: The step of using each of the candidate time thresholds as the switching time threshold and calculating the first total power consumption corresponding to the plurality of time interval information comprises: Using each of the candidate time thresholds as the switching time threshold, and dividing the idle duration, mode conversion duration, and low power consumption duration in the multiple time interval information; According to the idle time duration, the mode switching time duration and the low power consumption time duration, correspondingly acquiring an idle mode power consumption value, a mode switching power consumption value and a low power consumption mode power consumption value; and The first total power consumption corresponding to each of the candidate time thresholds is determined according to the idle mode power consumption value, the mode conversion power consumption value, and the low power consumption mode power consumption value.

5. The system mode control method according to claim 2, characterized in that: The step of obtaining the plurality of power consumption assessment information corresponding to the plurality of candidate time thresholds according to the plurality of time interval information comprises: Obtaining counting information corresponding to each of the candidate time thresholds according to the plurality of time interval information, wherein each of the counting information reflects the number of time interval information in the plurality of time interval information associated with the corresponding candidate time threshold; and According to the counting information and the candidate time threshold, the plurality of power consumption evaluation information corresponding to the plurality of candidate time thresholds are obtained.

6. The system mode control method according to claim 5, characterized in that: The step of obtaining the counting information corresponding to each of the candidate time thresholds according to the multiple time interval information comprises: Each time interval information among the plurality of time interval information is associated with the closest candidate time threshold and the corresponding counting information is updated.

7. The system mode control method according to claim 6, characterized in that: The step of obtaining the plurality of power consumption assessment information corresponding to the plurality of candidate time thresholds according to the counting information and the candidate time thresholds comprises: Using each of the candidate time thresholds as the switching time threshold, determining that other candidate time thresholds less than the switching time threshold are idle mode time, and other candidate time thresholds greater than the switching time threshold are low power mode time; Obtain a first power consumption according to each of the idle mode time and the corresponding counting information, the switching time threshold and the corresponding counting information, and the counting information corresponding to the low power mode time; obtain a second power consumption according to the switching time threshold and the counting information respectively corresponding to the low power mode time; obtain a third power consumption according to each of the low power mode time and the corresponding counting information and the switching time threshold; and The power consumption evaluation information corresponding to each of the candidate time thresholds is determined according to the first power consumption, the second power consumption, and the third power consumption.

8. The system mode control method according to claim 7, characterized in that: The step of acquiring the first power consumption according to each of the idle mode time and the corresponding counting information, the switching time threshold and the corresponding counting information, and the counting information corresponding to the low power consumption mode time includes: Based on each of the idle mode time, the switching time threshold, the low power mode time, and the corresponding counting information, obtaining a total time length of the storage device being in the idle mode; acquiring the first power consumption according to the idle power and the total time duration that the storage device is in the idle mode; The step of acquiring the second power consumption according to the counting information respectively corresponding to the switching time threshold and the low power consumption mode time includes: acquiring the second power consumption based on the mode switching power consumption and the counting information corresponding to the switching time threshold and the low power consumption mode time respectively; According to each of the low power consumption mode times and the corresponding counting information and the switching time threshold, the step of acquiring the third power consumption includes: Based on each of the low power mode times and the corresponding counting information and the switching time threshold, obtaining a total time duration of the storage device being in the low power mode; and The third power consumption is acquired according to the low power consumption and the total time duration that the storage device is in the low power consumption mode.

9. The system mode control method according to claim 1, characterized in that: Also includes: Acquire a second target time threshold, where the second target time threshold is greater than all time interval information; as well as When the storage device is in the low power consumption mode, the storage device is controlled to exit the low power consumption mode according to the second target time threshold.

10. A storage device, characterized in that: include: A connection interface unit for connecting to a host system; Memory module; as well as a memory controller connected to the connection interface unit and the memory module, The memory controller is used to: Monitoring the state of the storage device within a time range to obtain a plurality of time interval information, wherein each time interval information of the plurality of time interval information reflects the length of time between a first time point when the storage device completes processing a previous instruction and a second time point when the storage device obtains a next instruction within the time range; According to the multiple time interval information, obtain multiple power consumption evaluation information corresponding to multiple candidate time thresholds; Determine, according to the plurality of power consumption assessment information, a first target time threshold among the plurality of candidate time thresholds; as well as When the storage device is in an idle mode, controlling the storage device to enter a low power consumption mode according to the first target time threshold; Wherein, determining, according to the multiple power consumption evaluation information, the first target time threshold among the multiple candidate time thresholds includes: Comparing the plurality of power consumption assessment information to obtain target power consumption assessment information, wherein the target power consumption assessment information is power consumption assessment information reflecting the lowest total power consumption of the storage device within the time range among the plurality of power consumption assessment information; The candidate time threshold corresponding to the target power consumption assessment information is determined as the first target time threshold.

11. The storage device according to claim 10, characterized in that: Each of the power consumption assessment information respectively reflects the estimated total power consumption of the storage device within the time range if the corresponding candidate time threshold is used as the switching time threshold, wherein the switching time threshold is the time length for the storage device to enter the low power consumption mode from the idle mode.

12. The storage device according to claim 11, characterized in that: The operation of obtaining a plurality of power consumption evaluation information corresponding to a plurality of candidate time thresholds according to the plurality of time interval information includes: Taking each of the candidate time thresholds as the switching time threshold, calculating the first total power consumption corresponding to the plurality of time interval information; and Determine each of the first total power consumptions as the power consumption evaluation information corresponding to the candidate time threshold.

13. The storage device according to claim 12, characterized in that: The operation of using each of the candidate time thresholds as the switching time threshold and calculating the first total power consumption corresponding to the plurality of time interval information includes: Using each of the candidate time thresholds as the switching time threshold, and dividing the idle duration, mode conversion duration, and low power consumption duration in the multiple time interval information; According to the idle time duration, the mode switching time duration and the low power consumption time duration, correspondingly acquiring an idle mode power consumption value, a mode switching power consumption value and a low power consumption mode power consumption value; and The first total power consumption corresponding to each of the candidate time thresholds is determined according to the idle mode power consumption value, the mode conversion power consumption value, and the low power consumption mode power consumption value.

14. The storage device according to claim 11, characterized in that: The operation of obtaining the plurality of power consumption assessment information corresponding to the plurality of candidate time thresholds according to the plurality of time interval information includes: Obtaining counting information corresponding to each of the candidate time thresholds according to the plurality of time interval information, wherein each of the counting information reflects the number of time interval information in the plurality of time interval information associated with the corresponding candidate time threshold; and According to the counting information and the candidate time threshold, the plurality of power consumption evaluation information corresponding to the plurality of candidate time thresholds are obtained.

15. The storage device according to claim 14, characterized in that: The operation of obtaining the counting information corresponding to each of the candidate time thresholds according to the multiple time interval information includes: Each time interval information among the plurality of time interval information is associated with the closest candidate time threshold and the corresponding counting information is updated.

16. The storage device according to claim 15, characterized in that: The operation of obtaining the plurality of power consumption evaluation information corresponding to the plurality of candidate time thresholds according to the counting information and the candidate time thresholds includes: Using each of the candidate time thresholds as the switching time threshold, determining that other candidate time thresholds less than the switching time threshold are idle mode time, and other candidate time thresholds greater than the switching time threshold are low power mode time; Obtain a first power consumption according to each of the idle mode time and the corresponding counting information, the switching time threshold and the corresponding counting information, and the counting information corresponding to the low power mode time; obtain a second power consumption according to the switching time threshold and the counting information respectively corresponding to the low power mode time; obtain a third power consumption according to each of the low power mode time and the corresponding counting information and the switching time threshold; and The power consumption evaluation information corresponding to each of the candidate time thresholds is determined according to the first power consumption, the second power consumption, and the third power consumption.

17. The storage device according to claim 16, characterized in that: The operation of acquiring the first power consumption according to each of the idle mode times and the corresponding counting information includes: The step of acquiring the first power consumption according to each of the idle mode time and the corresponding counting information, the switching time threshold and the corresponding counting information, and the counting information corresponding to the low power consumption mode time includes: Based on each of the idle mode time, the switching time threshold, the low power mode time, and the corresponding counting information, obtaining a total time length of the storage device being in the idle mode; acquiring the first power consumption according to the idle power and the total time duration that the storage device is in the idle mode; The step of acquiring the second power consumption according to the counting information respectively corresponding to the switching time threshold and the low power consumption mode time includes: acquiring the second power consumption based on the mode switching power consumption and the counting information corresponding to the switching time threshold and the low power consumption mode time respectively; According to each of the low power consumption mode times and the corresponding counting information and the switching time threshold, the step of acquiring the third power consumption includes: Based on each of the low power mode times and the corresponding counting information and the switching time threshold, obtaining a total time duration of the storage device being in the low power mode; and The third power consumption is acquired according to the low power consumption and the total time duration that the storage device is in the low power consumption mode.

18. The storage device according to claim 10, characterized in that: Also includes: Acquire a second target time threshold, where the second target time threshold is greater than all time interval information; as well as When the storage device is in the low power consumption mode, the storage device is controlled to exit the low power consumption mode according to the second target time threshold.