A storage device and a method for controlling communication frequency thereof
By using the temperature sensor and the main controller in the storage device, frequency adjustment is made according to the operating temperature and frequency, the problem of data identification errors in high-temperature environments is solved, and the communication quality and usage performance of the storage device are improved.
Patent Information
- Application Number
- CN202411178750.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-27
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2044-08-27
AI Technical Summary
In high temperature environments, a large number of data identification errors are easily generated between the host and the storage device, affecting the communication quality.
Design a storage device that includes a temperature sensor and a main controller, by measuring the operating temperature and the current communication frequency, comparing it with the preset threshold temperature and frequency, generating temperature status data and writing it into the status register, according to which the host Data sends control instructions to adjust the communication frequency to ensure that the frequency is maintained or adjusted within different temperature intervals to ensure communication quality.
At different operating temperatures, ensure good communication quality between the host and the storage device, and improve the performance and service life of the storage device.
Smart Images

Figure CN118708124B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of static storage technology, and in particular to a storage device and a method for controlling the communication frequency thereof. Background Art
[0002] The data transmission between the host and the storage device relies on a hardware circuit with electrical characteristics. When the storage device is running hot or the ambient temperature of the storage device changes, the stability of the electrical characteristics of the hardware circuit will be greatly affected. If the host and the storage device always maintain a high-speed communication, a large number of data recognition errors will be generated, which seriously affects the communication quality between the host and the storage device. Therefore, there is room for improvement. Summary of the invention
[0003] The present invention provides a storage device and a method for controlling the communication frequency thereof, so as to solve the technical problem in the prior art that a large number of data recognition errors are easily generated between a host and a storage device in a high temperature environment.
[0004] The present invention provides a storage device, comprising:
[0005] flash memory;
[0006] A temperature sensor is used to measure the operating temperature of the main controller;
[0007] A main controller is electrically connected to the flash memory, and the main controller includes:
[0008] a status register, used to store temperature status data of the main controller, wherein the temperature status data reflects the operating temperature and communication frequency of the main controller; and
[0009] a central processing unit, configured to obtain a current communication frequency and an operating temperature of the main controller, compare the current communication frequency with a preset threshold frequency, and the current operating temperature with a preset threshold temperature, generate temperature status data based on the comparison result, and write the temperature status data into the status register, wherein the threshold temperature and the threshold frequency are non-zero constants;
[0010] The central processing unit sends the temperature status data to the host, and the host sends a communication frequency control instruction to the storage device based on the temperature status data to maintain or adjust the communication frequency of the main controller.
[0011] In one embodiment of the present invention, the central processing unit is used to set a plurality of the threshold temperatures, the plurality of the threshold temperatures divide the operating temperature into a plurality of temperature intervals, and each of the temperature intervals corresponds to a threshold frequency;
[0012] The central processing unit is used to maintain the current communication frequency when the main controller is in a certain temperature range and the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency; when the current communication frequency of the main controller is greater than the corresponding threshold frequency, the temperature status data is sent to the host to adjust the communication frequency of the main controller.
[0013] In one embodiment of the present invention, when the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency, the central processing unit sends the corresponding temperature status data to the host and then receives a communication frequency maintenance instruction returned by the host;
[0014] When the current communication frequency of the main controller is greater than the corresponding threshold frequency, the central processing unit sends the corresponding temperature status data to the host, and then receives the communication frequency adjustment instruction returned by the host, so that the adjusted communication frequency of the main controller is less than the corresponding threshold frequency.
[0015] In one embodiment of the present invention, the central processing unit is used to set the numerical value of the temperature interval to be inversely proportional to the numerical value of the threshold frequency among the multiple temperature intervals and the multiple threshold frequencies, so that the temperature interval with a larger value corresponds to the threshold frequency with a smaller value.
[0016] In one embodiment of the present invention, the status register is provided with a general flag bit area, a reserved bit area, a command line bit area and a test mode bit area, the general flag bit area, the reserved bit area and the command line bit area are used to store the operating status data of the storage device, and the test mode bit area is used to store the temperature status data of the storage device.
[0017] In one embodiment of the present invention, the central processing unit is used to set at least three threshold temperatures, and the at least three threshold temperatures divide the operating temperature into at least four temperature intervals;
[0018] The central processing unit is used to save the temperature status data on the test mode bit as a maintained value when the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency when the storage device is in a certain temperature range, and save the temperature status data on the test mode bit as a first value, a second value or a third value when the current communication frequency of the main controller is greater than the corresponding threshold frequency.
[0019] In one embodiment of the present invention, the central processing unit is used to save the temperature status data on the test mode bit as a first value, a second value, and a third value, respectively, when the main controller is in a first temperature range, a second temperature range, and a third temperature range, respectively, and when the current communication frequency of the main controller is greater than the corresponding threshold frequency, and the first value is less than the second value and less than the third value.
[0020] The present invention also provides a method for controlling the communication frequency of a storage device, comprising:
[0021] measuring the operating temperature of a main controller in a storage device;
[0022] Acquire the current communication frequency and operating temperature of the main controller, and compare the current communication frequency with a preset threshold frequency, and the current operating temperature with a preset threshold temperature, wherein the threshold temperature and the threshold frequency are non-zero constants;
[0023] Generate temperature status data based on the comparison result, and write the temperature status data into the status register of the main controller, wherein the temperature status data reflects the operating temperature and communication frequency of the main controller;
[0024] The temperature status data is sent to a host, and the host sends a communication frequency control instruction to the storage device based on the temperature status data to maintain or adjust the communication frequency of the main controller.
[0025] In one embodiment of the present invention, the step of sending the temperature status data to a host comprises:
[0026] Setting a plurality of the threshold temperatures, wherein the plurality of the threshold temperatures divide the operating temperature into a plurality of temperature intervals, each of the temperature intervals corresponding to one of the threshold frequencies;
[0027] When the main controller is in a certain temperature range, when the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency, maintaining the current communication frequency;
[0028] When the main controller is in the certain temperature range and the current communication frequency of the main controller is greater than the corresponding threshold frequency, the temperature status data is sent to the host to adjust the communication frequency of the main controller.
[0029] In one embodiment of the present invention, when the main controller is in a certain temperature range and the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency, after sending the corresponding temperature status data to the host, a communication frequency maintenance instruction returned by the host is received;
[0030] When the main controller is in the certain temperature range, when the current communication frequency of the main controller is greater than the corresponding threshold frequency, after sending the corresponding temperature status data to the host, the main controller receives an adjustment instruction of the communication frequency returned by the host, so that the adjusted communication frequency of the main controller is less than the corresponding threshold frequency.
[0031] Beneficial effects of the present invention: The present invention proposes a storage device and a method for controlling its communication frequency, which can ensure good communication quality between the host and the storage device when the storage device is at different operating temperatures, thereby improving the performance and service life of the storage device. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] In order to more clearly illustrate the specific implementation methods of the present application or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0033] Figure 1 A schematic diagram of the structure of a storage device provided in one embodiment of the present invention.
[0034] Figure 2 A schematic diagram of the steps of a method for controlling the communication frequency of a storage device provided by an embodiment of the present invention.
[0035] Figure 3 An embodiment of the present invention provides Figure 2 Schematic diagram of step S40 in FIG.
[0036] Figure 4 An embodiment of the present invention provides Figure 3 Schematic diagram of steps after step S420 and step S430. DETAILED DESCRIPTION
[0037] The following describes the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.
[0038] It should be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present invention, and thus the drawings only show components related to the present invention rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.
[0039] In the following description, numerous details are discussed to provide a more thorough explanation of the embodiments of the present invention. However, it is obvious to those skilled in the art that the embodiments of the present invention can be implemented without these specific details. In other embodiments, well-known structures and devices are shown in the form of block diagrams rather than in detail to avoid making the embodiments of the present invention difficult to understand.
[0040] See also Figures 1 to 4 The present invention proposes a storage device and a control method for its communication frequency, which can be applied to storage devices such as eMMC (Embedded Multi Media Card), SSD (Solid State Disk), and UFS (Univeral Flash Storage). The present invention can ensure good communication quality between the host 10 and the storage device 20 when the storage device 20 is at different operating temperatures, and improve the performance and service life of the storage device 20. The following is a detailed description through specific embodiments.
[0041] See also Figure 1 In one embodiment of the present invention, a storage device 20 is provided. The storage device 20 is provided with a bus interface. The storage device 20 is electrically connected to a host 10 through the bus interface. The host 10 can write host data and send instructions to the storage device 20, or the host 10 can read host data and receive instructions from the storage device 20. The host 10 can be a communication device such as a personal computer (PC), a tablet computer (Pad), a mobile phone (Cell Phone), etc.
[0042] Specifically, the communication between the host 10 and the storage device 20 relies on a command signal (CMD), a data signal (data), and a clock signal (clock). Before the host 10 actually starts communicating with the storage device 20, the host 10 sets a specific rate value for the storage device 20 to ensure frequency synchronization between the host 10 and the storage device 20. Usually, in order to ensure operating performance, the host 10 sets a high rate value during the startup phase of the storage device 20, and uses the frequency during the operation phase of the storage device 20.
[0043] See also Figure 1In one embodiment of the present invention, the storage device 20 may include a main controller 30, a flash memory 40 and a temperature sensor 50. The flash memory 40 is a non-volatile memory, which is usually used to store host data and system programs. The main controller 30 is mainly used to operate and manage the flash memory 40. The main controller 30 can greatly improve the performance of reading, writing and moving host data in the flash memory 40.
[0044] See also Figure 1 In one embodiment of the present invention, inside the storage device 20, a flash memory interface is provided on the main controller 30, and the main controller 30 is electrically connected to the flash memory 40 through the flash memory interface. The main controller 30 may include a status register 31 and a central processing unit (CPU) 32, and the central processing unit 32 is the computing core and control core of the storage device 20.
[0045] See also Figure 1 In one embodiment of the present invention, the storage device 20 generates heat during operation, and the temperature sensor 50 can be used to measure the operating temperature of the main controller 30. If the temperature sensor 50 directly measures the ambient temperature around the storage device 20 without measuring the operating temperature of the main controller 30, the ambient temperature will not reflect the operating temperature of the main controller 30, that is, the ambient temperature cannot reflect the real temperature of the main controller 30. In this embodiment, by measuring the operating temperature of the main controller 30, the factors of the ambient temperature and the main controller 30 itself can be taken into account at the same time, and the operating temperature is represented as the real temperature of the main controller 30.
[0046] Specifically, when the main controller 30 is at a certain operating temperature, the magnitude relationship between the communication frequency of the main controller 30 and the threshold frequency is analyzed. Then, the host 10 can maintain or adjust the communication frequency of the storage device 20, so that the storage device 20 maintains an appropriate communication frequency at a certain operating temperature, thereby ensuring the communication quality between the host 10 and the storage device 20, and improving the performance and service life of the storage device 20.
[0047] It should be understood that the communication frequency of the storage device 20 is the communication frequency of the main controller 30. Outside the storage device 20, the communication frequency of the storage device 20 is written to facilitate the description of the communication connection between the storage device 20 and the host 10. Inside the storage device 20, the communication frequency of the main controller 30 is written to facilitate the description of the electrical connection between the main controller 30 and the flash memory 40 and the temperature sensor 50.
[0048] See also Figure 1In one embodiment of the present invention, the status register 31 can be used to store the temperature status data of the storage device 20, and the temperature status data reflects the operating temperature and communication frequency of the main controller 30. For example, when the operating temperature is ≤45°C, the storage device 20 is at a normal temperature, and the main controller 30 can be allowed to be in a high-speed communication frequency state. When the operating temperature is ≤45°C, the corresponding temperature status data can be set to 00, where 00 is binary data. When the temperature status data appearing below is 00, 01, 10, 11, it is also binary data.
[0049] For example, when 45°C<operating temperature≤60°C, the main controller 30 is at a relatively high temperature. In order to ensure the communication quality between the storage device 20 and the host 10, the storage device 20 may be allowed to be in a communication frequency state lower than HS200. HS200 means that the bus communication frequency of the storage device 20 is 200MB / S. When 45°C<operating temperature≤60°C, if the communication frequency of the storage device 20 is>200MB / S, the corresponding temperature state data may be set to 01, and if the communication frequency of the storage device 20 is≤200MB / S, the corresponding temperature state data may be set to 00.
[0050] For example, when 60°C<operating temperature≤85°C, the main controller 30 is at a relatively high temperature. In order to ensure the communication quality between the storage device 20 and the host 10, the storage device 20 may be allowed to be in a communication frequency state lower than HDR52. HDR52 means that the bus communication frequency of the storage device 20 is 104MB / S. When 60°C<operating temperature≤85°C, if the communication frequency of the storage device 20 is>104MB / S, the corresponding temperature state data may be set to 10, and if the communication frequency of the storage device 20 is≤104MB / S, the corresponding temperature state data may be set to 00.
[0051] For example, when 85°C < operating temperature, the main controller 30 is at a very high temperature. In order to ensure the communication quality between the storage device 20 and the host 10, the storage device 20 may be allowed to be in a communication frequency state lower than SDR52. SDR52 means that the bus communication frequency of the storage device 20 is 52MB / S. When 85°C < operating temperature, if the communication frequency of the storage device 20 is > 52MB / S, the corresponding temperature state data may be set to 11, and if the communication frequency of the storage device 20 is ≤ 52MB / S, the corresponding temperature state data may be set to 00.
[0052] From the above analysis, it can be seen that when the temperature status data is 00, there is no need to adjust the communication frequency of the storage device 20. When the temperature status data is 01, 10 or 11, it indicates that the storage device 20 is at a relatively high temperature. For example, the temperature status data 01 corresponds to an operating temperature of the storage device 20 of 45°C to 60°C, and the temperature status data 10 corresponds to an operating temperature of the storage device 20 of 60°C to 85°C. For example, the temperature status data 11 corresponds to an operating temperature of the storage device 20 greater than 85°C. When the temperature status data is 01, 10 or 11, the storage device 20 is at a relatively high temperature, and the communication frequency of the storage device 20 is relatively high at this time, and the communication quality between the storage device 20 and the host 10 cannot be guaranteed, and the communication frequency of the storage device 20 needs to be adjusted.
[0053] It can be seen that the temperature status data can reflect the operating temperature and communication frequency of the main controller 30, so that the temperature status data can be used to further consider whether the communication frequency of the storage device 20 needs to be adjusted to ensure the communication quality between the storage device 20 and the host 10. The host 10 does not have to analyze the operating temperature and communication frequency of the storage device 20 all the time. The host 10 adjusts the communication frequency of the storage device 20 only when it receives abnormal information from the storage device 20, that is, the host 10 only adjusts the communication frequency of the storage device 20 when it receives the temperature status data returned by the main controller 30 as 01, 10 or 11, thereby reducing the workload of the host 10.
[0054] See also Figure 1 In one embodiment of the present invention, the central processing unit 32 serves as the computing core and control core of the storage device 20. The central processing unit 32 can obtain the current communication frequency and operating temperature of the main controller 30, and compare the current communication frequency with the preset threshold frequency, and the current operating temperature with the preset threshold temperature, and generate temperature status data based on the comparison result. The threshold temperature and the threshold frequency are non-zero constants. The operating temperature is compared with the threshold temperature, and the threshold temperature can reflect the numerical value of the operating temperature. The communication frequency is compared with the threshold frequency, and the threshold frequency can reflect the numerical value of the communication frequency. The central processing unit 32 can write the temperature status data into the status register 31 to save the temperature status data.
[0055] Specifically, multiple threshold temperatures can be set to 45°C, 60°C, and 85°C, and the operating temperature can be divided into temperature intervals of less than 45°C, 45°C to 60°C, 60°C to 85°C, and greater than 85°C. In the temperature interval of less than 45°C, the main controller 30 is at a normal temperature, allowing the storage device 20 to be in a high-speed communication frequency state. In the temperature interval of 45°C to 60°C, the threshold frequency can be 200MB / S. In the temperature interval of 60°C to 85°C, the threshold frequency can be 104MB / S. In the temperature interval of greater than 85°C, the threshold frequency can be 52MB / S.
[0056] See also Figure 1 In one embodiment of the present invention, when the host 10 writes host data to the storage device 20, the host data of the host 10 is first stored in the main controller 30, and the main controller 30 then sends the host data of the host 10 to the flash memory 40. When the host 10 reads data from the storage device 20, the host data in the flash memory 40 is first stored in the main controller 30, and the main controller 30 then sends the host data in the flash memory 40 to the host 10. The flash memory 40 may include a plurality of blocks 41, and the blocks 41 may be used to store the host data written by the host 10, and one block 41 may also include a plurality of pages 42.
[0057] See also Figure 1 In one embodiment of the present invention, during the communication between the storage device 20 and the host 10, the central processing unit 32 may periodically obtain the operating temperature detected by the temperature sensor 50. For example, the central processing unit 32 obtains the operating temperature of the main controller 30 through the temperature sensor 50 every 10 minutes. The central processing unit 32 sends the temperature status data to the host 10, and the host 10 sends a control instruction of the communication frequency to the storage device 20 based on the temperature status data to maintain or adjust the communication frequency of the storage device 20. As analyzed above, when the temperature status data is 00, there is no need to adjust the communication frequency of the storage device 20, and when the temperature status data is 01, 10 or 11, it is necessary to adjust the communication frequency of the storage device 20.
[0058] Specifically, the central processing unit 32 sends the temperature status data to the host 10. After receiving the temperature status data, the host 10 obtains the specific value of the temperature status data. When the temperature status data is 00, the host 10 may send a communication frequency maintenance instruction to the storage device 20, or the host 10 does not send a communication frequency control instruction to the storage device 20, so that the communication frequency of the storage device 20 is maintained. When the temperature status data is 01, 10 or 11, the host 10 may send a communication frequency adjustment instruction to the storage device 20 to adjust the communication frequency of the storage device 20.
[0059] See also Figure 1 In one embodiment of the present invention, the central processing unit 32 sets a plurality of threshold temperatures, and the plurality of threshold temperatures divide the operating temperature into a plurality of temperature intervals, each temperature interval corresponding to a threshold frequency. When the main controller 30 is in a certain temperature interval, the central processing unit 32 maintains the current communication frequency when the current communication frequency of the storage device 20 is less than or equal to the corresponding threshold frequency. When the current communication frequency of the storage device 20 is greater than the corresponding threshold frequency, the temperature status data is sent to the host 10 to adjust the communication frequency of the storage device 20.
[0060] Specifically, as the operating temperature of the main controller 30 increases, in order to ensure the communication quality between the storage device 20 and the host 10, the communication frequency of the storage device 20 needs to be adjusted. In order to improve the adjustment efficiency of the communication frequency of the storage device 20, it is not necessary to set a threshold frequency corresponding to each temperature value, and the operating temperature can be divided into multiple temperature intervals according to the value.
[0061] For example, multiple threshold temperatures can be set to 45°C, 60°C, and 85°C, and the operating temperature can be divided into temperature intervals of less than 45°C, 45°C to 60°C, 60°C to 85°C, and greater than 85°C. In the temperature interval of less than 45°C, the main controller 30 is at a normal temperature, allowing the storage device 20 to be in a high-speed communication frequency state. In the temperature interval of 45°C to 60°C, the threshold frequency corresponds to 200MB / S. In the temperature interval of 60°C to 85°C, the threshold frequency corresponds to 104MB / S. In the temperature interval of greater than 85°C, the threshold frequency corresponds to 52MB / S. In the multiple temperature intervals and multiple threshold frequencies, the central processing unit 32 sets the numerical value of the temperature interval inversely proportional to the numerical value of the threshold frequency, so that the temperature interval with a larger numerical value corresponds to the threshold frequency with a smaller numerical value.
[0062] Specifically, the threshold frequency is 104MB / S in the temperature range of 60°C to 85°C. When the main controller 30 is in the temperature range of 60°C to 85°C, the central processing unit 32 can maintain the current communication frequency when the current communication frequency of the storage device 20 is less than or equal to the threshold frequency of 104MB / S. When the current communication frequency of the storage device 20 is greater than the threshold frequency of 104MB / S, the temperature status data can be sent to the host 10 to adjust the communication frequency of the storage device 20.
[0063] See also Figure 1In one embodiment of the present invention, when the current communication frequency of the storage device 20 is less than or equal to the corresponding threshold frequency, the central processing unit 32 sends the corresponding temperature status data to the host 10, and then receives the communication frequency maintenance instruction returned by the host 10. When the current communication frequency of the storage device 20 is greater than the corresponding threshold frequency, the central processing unit 32 sends the corresponding temperature status data to the host 10, and then receives the communication frequency adjustment instruction returned by the host 10, so that the adjusted communication frequency of the storage device 20 is less than the corresponding threshold frequency.
[0064] Specifically, taking the temperature range of 60°C to 85°C and the threshold frequency of 104MB / S as an example, the command transmission between the host 10 and the central processing unit 32 is described. In the temperature range of 60°C to 85°C, when the current communication frequency of the storage device 20 is less than or equal to the threshold frequency of 104MB / S, the central processing unit 32 sends the corresponding temperature status data to the host 10, and then receives the communication frequency maintenance instruction returned by the host 10. When the current communication frequency of the storage device 20 is greater than the threshold frequency of 104MB / S, the central processing unit 32 sends the corresponding temperature status data to the host 10, and then receives the communication frequency adjustment instruction returned by the host 10, so that the adjusted communication frequency of the storage device 20 is less than the corresponding threshold frequency.
[0065] Table 1. Table of bits of status register 31
[0066]
[0067] See also Figure 1 As shown in Table 1, in one embodiment of the present invention, the status register (Device status) 31 includes a general identifier bit area, a reserved bit area, a command line bit area (VendorCMD) area and a test mode bit area. The general identifier bit area, the reserved bit area and the command line bit area can store the operation status data of the storage device 20. The test mode bit area is a reserved bit area independently controlled by the manufacturer of the storage device 20. The temperature status data of the storage device 20 can be stored in the test mode bit area. The status register 31 may include a storage space of 32 bits, the number of bits in the general identifier bit area is Bit31~Bit5, the number of bits in the reserved bit area is Bit4, the number of bits in the command line bit area is Bit3~Bit2, and the number of bits in the test mode bit area is Bit1~Bit0. The central processing unit 32 reads the status register 31 and can simultaneously obtain the operation status data and temperature status data of the storage device 20.
[0068] Specifically, the central processing unit 32 can set at least three threshold temperatures, and the at least three threshold temperatures can divide the operating temperature into at least four temperature intervals. When the main controller 30 is in a certain temperature interval, when the current communication frequency of the storage device 20 is less than or equal to the corresponding threshold frequency, the central processing unit 32 saves the temperature state data on the test mode bit as a maintained value. When the current communication frequency of the storage device 20 is greater than the corresponding threshold frequency, the temperature state data on the test mode bit is saved as a first value, a second value, or a third value. The first value can be binary 01, the second value can be binary 10, and the third value can be binary 11.
[0069] Specifically, three threshold temperatures can be set to 45°C, 60°C, and 85°C, and the operating temperature can be divided into four temperature intervals of less than 45°C, 45°C to 60°C, 60°C to 85°C, and greater than 85°C. Take the temperature interval of 60°C to 85°C and the threshold frequency of 104MB / S as an example for explanation. When the main controller 30 is in the temperature interval of 60°C to 85°C, the central processing unit 32 saves the temperature status data on the test mode bit as a retained value when the current communication frequency of the storage device 20 is less than or equal to the threshold frequency of 104MB / S. When the current communication frequency of the storage device 20 is greater than the threshold frequency of 104MB / S, the temperature status data on the test mode bit is saved as a second value 10.
[0070] See also Figure 1 As shown in Table 1, in one embodiment of the present invention, when the main controller 30 is in the first temperature interval, the second temperature interval, and the third temperature interval, respectively, the central processing unit 32 saves the temperature state data on the test mode bit as the first value, the second value, and the third value when the current communication frequency of the storage device 20 is greater than the corresponding threshold frequency. The value of the first temperature interval < the value of the second temperature interval < the value of the third temperature interval, and the first value < the second value < the third value.
[0071] Specifically, the first temperature interval may be 45°C to 60°C, the second temperature interval may be 60°C to 85°C, and the third temperature interval may be greater than 85°C. The threshold frequency corresponding to the first temperature interval may be 200MB / S, the threshold frequency corresponding to the second temperature interval may be 104MB / S, and the threshold frequency corresponding to the third temperature interval may be 52MB / S. The first value may be 01 in binary, the second value may be 10 in binary, and the third value may be 11 in binary. The values of the first temperature interval, the second temperature interval, and the third temperature interval are proportional to the values of the first value, the second value, and the third value. According to the operating temperature of the storage device 20, the communication frequency between the host 10 and the storage device 20 is adjusted in steps to ensure the communication quality between the host 10 and the storage device 20.
[0072] See also Figure 1 and Figure 2 In one embodiment of the present invention, a method for controlling the communication frequency of a storage device is proposed, which may include the following steps.
[0073] Step S10: measuring the operating temperature of the main controller in the storage device.
[0074] In one embodiment of the present invention, the main controller 30 of the storage device 20 generates heat during operation, and the temperature sensor 50 can be used to measure the operating temperature of the main controller 30. If the temperature sensor 50 directly measures the ambient temperature around the storage device 20 without measuring the operating temperature of the main controller 30, the ambient temperature will not reflect the operating temperature of the main controller 30, that is, the ambient temperature cannot reflect the real temperature of the main controller 30. In this embodiment, by measuring the operating temperature of the main controller 30, the factors of the ambient temperature and the main controller 30 itself can be taken into account at the same time, and the operating temperature is represented as the real temperature of the main controller 30.
[0075] Step S20, obtaining the current communication frequency and operating temperature of the main controller, comparing the current communication frequency with a preset threshold frequency, and the current operating temperature with a preset threshold temperature, wherein the threshold temperature and the threshold frequency are non-zero constants.
[0076] In one embodiment of the present invention, the current communication frequency and operating temperature of the main controller 30 can be obtained, and the current communication frequency is compared with the preset threshold frequency, and the current operating temperature is compared with the preset threshold temperature, and the temperature state data is generated based on the comparison result. The threshold temperature and the threshold frequency are non-zero constants, and the operating temperature is compared with the threshold temperature, and the threshold temperature can reflect the numerical value of the operating temperature. The communication frequency is compared with the threshold frequency, and the threshold frequency can reflect the numerical value of the communication frequency. The central processing unit 32 can write the temperature state data into the state register 31 to save the temperature state data.
[0077] Step S30: Generate temperature status data based on the comparison result, and write the temperature status data into the status register of the main controller. The temperature status data reflects the operating temperature of the main controller and the size of the communication frequency.
[0078] In one embodiment of the present invention, for example, the operating temperature of the main controller 30 corresponding to the temperature state data 01 is 45°C to 60°C, the operating temperature of the main controller 30 corresponding to the temperature state data 10 is 60°C to 85°C, and for example, the operating temperature of the main controller 30 corresponding to the temperature state data 11 is greater than 85°C. In the temperature range of 45°C to 60°C, the threshold frequency corresponds to 200MB / S. In the temperature range of 60°C to 85°C, the threshold frequency corresponds to 104MB / S. In the temperature range greater than 85°C, the threshold frequency corresponds to 52MB / S.
[0079] Step S40: Send the temperature status data to the host. Based on the temperature status data, the host sends a communication frequency control instruction to the storage device to maintain or adjust the communication frequency of the main controller.
[0080] In one embodiment of the present invention, when the temperature status data is 01, 10 or 11, the main controller 30 is at a relatively high temperature, and at this time, the communication frequency of the storage device 20 is relatively high, and the communication quality between the storage device 20 and the host 10 cannot be guaranteed, and the communication frequency of the storage device 20 needs to be adjusted. After the storage device 20 sends the temperature status data to the host 10, the host 10 sends a control instruction of the communication frequency to the storage device 20 based on the temperature status data to maintain or adjust the communication frequency of the storage device 20. For example, when the temperature status data is 00, there is no need to adjust the communication frequency of the storage device 20, and when the temperature status data is 01, 10 or 11, the host 10 sends a communication frequency adjustment instruction to the storage device 20 to adjust the communication frequency of the storage device 20.
[0081] See also Figure 1 , Figure 2 and Figure 3 In one embodiment of the present invention, the step of sending the temperature status data to the host 10 in step S40 may include steps S410, S420 and S430. Step S410 may be expressed as setting a plurality of threshold temperatures, wherein the plurality of threshold temperatures divide the operating temperature into a plurality of temperature intervals, and each temperature interval corresponds to a threshold frequency.
[0082] Specifically, for example, three threshold temperatures can be set as 45°C, 60°C, and 85°C, and the operating temperature can be divided into four temperature intervals of less than 45°C, 45°C~60°C, 60°C~85°C, and greater than 85°C.
[0083] Step S420 may be represented as maintaining the current communication frequency of the storage device 20 when the current communication frequency of the storage device 20 is less than or equal to the corresponding threshold frequency when the main controller 30 is in a certain temperature range.
[0084] Specifically, the threshold frequency is 104 MB / S in the temperature range of 60° C. to 85° C. When the main controller 30 is in the temperature range of 60° C. to 85° C., when the current communication frequency of the storage device 20 is less than or equal to the threshold frequency of 104 MB / S, the current communication frequency can be maintained.
[0085] Step S430 may be represented as sending temperature status data to the host 10 to adjust the communication frequency of the storage device 20 when the current communication frequency of the main controller 30 is greater than the corresponding threshold frequency when the main controller 30 is in a certain temperature range.
[0086] Specifically, the threshold frequency is 104MB / S in the temperature range of 60°C to 85°C. When the main controller 30 is in the temperature range of 60°C to 85°C, when the current communication frequency of the main controller 30 is greater than the threshold frequency of 104MB / S, the temperature status data can be sent to the host 10 to adjust the communication frequency of the main controller 30.
[0087] See also Figure 1 , Figure 3 and Figure 4 In one embodiment of the present invention, for step S420, when the main controller 30 is in a certain temperature range and the current communication frequency of the main controller 30 is less than or equal to the corresponding threshold frequency, after sending the corresponding temperature status data to the host 10, the host 10 receives a communication frequency maintenance instruction returned by the host 10.
[0088] Specifically, the temperature range of 60°C to 85°C and the threshold frequency of 104MB / S are still used as an example for explanation. When the main controller 30 is in the temperature range of 60°C to 85°C, when the current communication frequency of the main controller 30 is less than or equal to the threshold frequency of 104MB / S, after sending the corresponding temperature status data to the host 10, the host 10 can receive a communication frequency maintenance instruction returned by the host 10.
[0089] For step S430, when the main controller 30 is in a certain temperature range and the current communication frequency of the main controller 30 is greater than the corresponding threshold frequency, the corresponding temperature status data is sent to the host 10, and then the communication frequency adjustment instruction returned by the host 10 is received, so that the adjusted communication frequency of the main controller 30 is less than the corresponding threshold frequency.
[0090] Specifically, within the temperature range of 60°C ~ 85°C, when the current communication frequency of the main controller 30 is greater than the threshold frequency of 104MB / S, after sending the corresponding temperature status data to the host 10, the host 10 receives the communication frequency adjustment instruction returned by the host 10, so that the adjusted communication frequency of the main controller 30 is less than the corresponding threshold frequency.
[0091] In summary, the present invention proposes a storage device and a method for controlling its communication frequency, which can ensure good communication quality between the host and the storage device when the storage device is at different operating temperatures, thereby improving the performance and service life of the storage device.
[0092] The flow chart and block diagram in the accompanying drawings illustrate the possible implementation architecture, function and operation of the method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
Claims
1. A storage device, It is characterized in that include: flash memory; A temperature sensor is used to measure the operating temperature of the main controller; A main controller is electrically connected to the flash memory, and the main controller includes: a status register, used to store temperature status data of the main controller, wherein the temperature status data reflects the operating temperature and communication frequency of the main controller; and a central processing unit, configured to obtain a current communication frequency and an operating temperature of the main controller, compare the current communication frequency with a preset threshold frequency, and the current operating temperature with a preset threshold temperature, generate temperature status data based on the comparison result, and write the temperature status data into the status register, wherein the threshold temperature and the threshold frequency are non-zero constants; The central processing unit sends the temperature status data to the host, and the host sends a communication frequency control instruction to the storage device based on the temperature status data to maintain or adjust the communication frequency of the main controller; The central processing unit is used to set at least three threshold temperatures, and the at least three threshold temperatures divide the operating temperature into at least four temperature intervals, including a normal temperature interval, a first temperature interval, a second temperature interval, and a third temperature interval, wherein the normal temperature interval < the first temperature interval < the second temperature interval < the third temperature interval; The central processing unit is used for maintaining the current communication frequency when the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency when the main controller is in a temperature range among the first temperature range, the second temperature range, and the third temperature range, and sending the temperature status data to the host to adjust the communication frequency of the main controller when the current communication frequency of the main controller is greater than the corresponding threshold frequency; The central processing unit is used to save the temperature status data on the test mode bit in the status register as a retained value when the main controller is in a normal temperature range; The central processing unit is used to save the temperature status data on the test mode bit as a first value, a second value, and a third value, respectively, when the main controller is in the first temperature range, the second temperature range, and the third temperature range, respectively, and when the current communication frequency of the main controller is greater than the corresponding threshold frequency, the first value < the second value < the third value.
2. The storage device according to claim 1, It is characterized in that The central processing unit is used for receiving a communication frequency maintenance instruction returned by the host after sending the corresponding temperature status data to the host when the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency when the main controller is in a temperature range among the first temperature range, the second temperature range, and the third temperature range; When the current communication frequency of the main controller is greater than the corresponding threshold frequency, the central processing unit sends the corresponding temperature status data to the host, and then receives the communication frequency adjustment instruction returned by the host, so that the adjusted communication frequency of the main controller is less than the corresponding threshold frequency.
3. The storage device according to claim 1, It is characterized in that The central processing unit is used to set the numerical values of the temperature intervals and the threshold frequencies inversely proportional to the numerical values of the threshold frequencies, so that the temperature interval with a larger numerical value corresponds to the threshold frequency with a smaller numerical value.
4. The storage device according to claim 1, It is characterized in that The status register is provided with a general flag bit area, a reserved bit area, a command line bit area and a test mode bit area. The general flag bit area, the reserved bit area and the command line bit area store the operating status data of the storage device, and the test mode bit area is used to store the temperature status data of the storage device.
5. A method for controlling the communication frequency of a storage device, It is characterized in that include: measuring the operating temperature of a main controller in a storage device; Acquire the current communication frequency and operating temperature of the main controller, and compare the current communication frequency with a preset threshold frequency, and the current operating temperature with a preset threshold temperature, wherein the threshold temperature and the threshold frequency are non-zero constants; Generate temperature status data based on the comparison result, and write the temperature status data into the status register of the main controller, wherein the temperature status data reflects the operating temperature and communication frequency of the main controller; The temperature status data is sent to a host, and the host sends a communication frequency control instruction to the storage device based on the temperature status data to maintain or adjust the communication frequency of the main controller; At least three threshold temperatures are set, and the at least three threshold temperatures divide the operating temperature into at least four temperature intervals, including a normal temperature interval, a first temperature interval, a second temperature interval, and a third temperature interval, wherein the normal temperature interval < the first temperature interval < the second temperature interval < the third temperature interval; When the main controller is in a temperature range among the first temperature range, the second temperature range, and the third temperature range, when the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency, the current communication frequency is maintained; when the current communication frequency of the main controller is greater than the corresponding threshold frequency, the temperature status data is sent to the host to adjust the communication frequency of the main controller; The central processing unit of the main controller is used to save the temperature status data on the test mode bit in the status register as a retained value when the main controller is in a normal temperature range; The central processing unit is used to save the temperature status data on the test mode bit as a first value, a second value, and a third value, respectively, when the main controller is in a first temperature range, a second temperature range, and a third temperature range, respectively, and when the current communication frequency of the main controller is greater than the corresponding threshold frequency, the first value < the second value < the third value.
6. The method for controlling the communication frequency of a storage device according to claim 5, It is characterized in that When the main controller is in a temperature range among the first temperature range, the second temperature range, and the third temperature range, when the current communication frequency of the main controller is less than or equal to the corresponding threshold frequency, after sending the corresponding temperature status data to the host, receiving a communication frequency maintenance instruction returned by the host; When the main controller is in any temperature range among the first temperature range, the second temperature range, and the third temperature range, when the current communication frequency of the main controller is greater than the corresponding threshold frequency, after sending the corresponding temperature status data to the host, the main controller receives an adjustment instruction of the communication frequency returned by the host, so that the adjusted communication frequency of the main controller is less than the corresponding threshold frequency.
Citation Information
Patent Citations
Storage device and temperature control of electronic device including same
CN113157208A
