Storage apparatus

By integrating a free capacity management unit to align the storage device's free space reporting with the information processing device's perception, the storage device guarantees consistent write performance, addressing the mismatch and ensuring reliable data recording.

JP2024154307AInactive Publication Date: 2024-10-30HAGIWARA SOLUTIONS CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
JP2023068076
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Filing Date
2023-04-18
Publication Date
2024-10-30
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The mismatch between the information processing device's perception of free space in LBA space and the storage device's management of free space on the storage medium leads to unpredictable write performance, failing to meet the desired write performance requirements of the information processing device.

Method used

The storage device includes a free capacity management unit that calculates and notifies the information processing device of its available free space, ensuring alignment between the two perspectives and maintaining guaranteed write performance.

Benefits of technology

This alignment enables the information processing device to reliably meet its write performance demands by adjusting operations based on accurate free space information from the storage device, preventing performance drops and data loss.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2024154307000001_ABST
    Figure 2024154307000001_ABST
Patent Text Reader

Abstract

To provide a storage apparatus configured so that information on free space held in the storage apparatus is coincident with information on free space held in an information processing apparatus, which is an external device, thereby securing write performance required by the information processing apparatus.SOLUTION: A storage apparatus includes a free space management unit which calculates free space of a nonvolatile storage medium and holds the calculated free space. The storage apparatus is connected to an information processing apparatus 100, which is a predetermined external device, and has a function to provide the information processing apparatus 100 serving as an external device, with the information on the free space recorded in the free space management unit. The information on the free space provided to the information processing apparatus 100 is free space information with which a determination can be made whether the information processing apparatus 100 can implement required write performance.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present invention relates to a storage device that uses a nonvolatile storage medium such as a NAND flash memory as a main storage medium and is used in applications that require guaranteed write performance. [Background technology]

[0002] Techniques for recording data from an information processing device to a storage device at high speed are disclosed, for example, in Patent Document 1 and Patent Document 2. When writing data to a storage device or reading data from a storage device, an information processing device specifies the data to be accessed by a logical block address (hereinafter referred to as LBA) and the number of logical blocks to the storage device.

[0003] For example, an information processing device sends a request to a storage device such as "write 8 sectors from LBA=0x100" or "read 256 sectors from LBA=0x0." In this way, the information processing device manages the data recorded in the storage device in the LBA space. In other words, the information processing device recognizes an area in the LBA space where no valid data has been written as "free space" on the storage device. Note that the prefix "0x" indicates that the numeric value preceding it is in hexadecimal notation.

[0004] On the other hand, the storage device manages the correspondence between the LBA and the location on the storage medium where the latest data corresponding to that LBA is recorded. For example, the storage device manages the correspondence as "the latest data of LBA=0x100 is recorded at address A on the storage medium" or "the latest data of LBA=0x0 is stored at address B on the storage medium." In other words, the storage device manages the data recorded in the storage device by addresses on the storage medium, not in the LBA space. [Prior art documents] [Patent documents]

[0005] [Patent Document 1] JP 2005-190331 A [Patent Document 2] JP 2016-009280 A Summary of the Invention [Problem to be solved by the invention]

[0006] However, in the above-mentioned conventional technology, the information regarding free space held by the information processing device (managed in LBA space) and the information regarding free space held by the storage device (managed by addresses on the storage medium, not in LBA space) do not necessarily match, resulting in a problem that when the information processing device writes data to the storage device, the write performance desired by the information processing device is not guaranteed.

[0007] The present invention has been made in consideration of the above circumstances, and aims to provide a storage device that can match information regarding free space held by the storage device with information regarding free space held by an external device, such as an information processing device, and can guarantee the write performance desired by the information processing device. [Means for solving the problem]

[0008] The storage device of the present invention is equipped with a free space management unit that calculates the free space of the storage medium installed therein and holds the calculated free space, and is also connected to a specified external device and has the function of notifying the external device of information about the free space held in the free space management unit. Effect of the Invention

[0009] According to the present invention, since it is provided with a function of notifying an external device of information regarding free space, the information regarding free space held by the storage device can be matched with the information regarding free space held by the external device, that is, an information processing device, thereby ensuring the writing performance desired by the information processing device. [Brief description of the drawings]

[0010] [Figure 1] A configuration diagram for explaining the problem to be solved by the present invention. [Diagram 2] A schematic diagram of the LBA space used by an information processing device to manage data recorded in a storage device. [Diagram 3] A schematic diagram showing the state of data recorded in a storage device that uses NAND flash memory as a storage medium. [Figure 4] Internal configuration diagram of information processing device 100 [Diagram 5] Internal configuration diagram of storage device 200 [Figure 6] State transition diagram regarding write performance guarantee state of the storage device 200 [Figure 7] 1 is a flowchart showing a procedure for causing the information processing device 100 to transition the write performance state of the storage device 200 to the write performance guaranteed state 252. [Figure 8] 1 is a flowchart showing a procedure for transitioning the write performance state of the storage device 200 to the write performance non-guaranteed state 251 in the storage device 200. [Figure 9] 1 is a flowchart showing a procedure for acquiring free space information of the storage device 200 and calculating free space from the received free space information in the information processing device 100. [Figure 10] 1 is a flowchart showing a procedure for updating free space in the storage device 200. [Figure 11] 1 is a flowchart showing a procedure from a user's selection of a data recording mode to a procedure for presenting the remaining recordable time in the recording mode to the user in the information processing device 100. [Figure 12a] 1 is a flowchart showing the procedure of a process in the information processing device 100 for writing data to the storage device 200 while guaranteeing the bit rate required by the data recording mode designated by the user. [Figure 12b] 1 is a flowchart showing the procedure of a process in the information processing device 100 for writing data to the storage device 200 while guaranteeing the bit rate required by the data recording mode designated by the user. [Figure 13]FIG. 12 is a data schematic diagram for explaining the processing procedure of FIG. 12a and FIG. 12b. [Figure 14] FIG. 23 is a schematic diagram of a table for holding a plurality of unit sizes of free space information in the fourth embodiment; [Figure 15] FIG. 11 is a diagram showing an internal configuration of an information processing device 100 according to an eleventh embodiment. [Figure 16] FIG. 11 shows an internal configuration of a storage device 200 according to an eleventh embodiment. [Figure 17] FIG. 23 is a schematic diagram of free space information returned from the storage device 200 to the information processing device 100 in the thirteenth embodiment; DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0011] Hereinafter, an embodiment of the present invention will be described in detail with reference to the drawings. 1 is a configuration diagram showing a storage device according to the present invention and an information processing device connected thereto. The information processing device 100 is configured to read and write data between the information processing device 100 and the storage device 200 via a communication path 300. The communication path 300 connecting the information processing device 100 and the storage device 200 may be either wired (cable) or wireless. The storage device 200 may be in the form of a card that is inserted into the information processing device 100, or may be soldered to a printed circuit board in the information processing device 100.

[0012] A method for managing the LBA space in the information processing device 100 will now be described. When writing data to the storage device 200 or reading data from the storage device 200, the information processing device 100 specifies the data to be accessed by a logical block address (LBA) and the number of logical blocks to the storage device 200. This logical block is called a sector, and the size of a sector is, for example, 512 bytes.

[0013] The information processing device 100 transmits a request such as "write 8 sectors from LBA=0x100" or "read 256 sectors from LBA=0x0" to the storage device 200. In this way, the information processing device 100 manages the data recorded in the storage device 200 in the LBA space. That is, the information processing device 100 recognizes an area in the LBA space where no valid data has been written as the "free area" of the storage device 200.

[0014] Next, the recognition state of the "free space" of the storage device 200 by the information processing device 100 will be described with reference to Fig. 2. In this figure, for the sake of simplicity, the capacity of the storage device 200 is 5 megabytes (hereinafter referred to as MB), and the information processing device 100 manages the 5 MB in the LBA space 400. If the sector size is 512 bytes, the LBA ranges from 0x0 to 0x27FF.

[0015] FIG. 2(A) shows a state where no data has been written. At this time, the information processing device 100 recognizes that the free space of the storage device 200 is 5MB. FIG. 2(B) shows a state after the information processing device 100 has written 2MB (0x1000 sectors) of data from LBA=0x800 to the storage device 200 from the state of FIG. 2(A). At this time, the information processing device 100 recognizes that the free space of the storage device 200 is 3MB. FIG. 2(C) shows a state after the information processing device 100 has further written 1.5MB of data from LBA=0x800 to the storage device 200 from the state of FIG. 2(B). Since the information processing device 100 has simply written new data to the LBA area where data was previously written, it recognizes that the free space of the storage device 200 is still 3MB.

[0016] Incidentally, the information processing device 100 may include devices that require data writing to the storage device 200 to be completed within a desired time, such as a still camera that captures and records still images, a video recorder that captures and records moving images, a voice recorder that records audio, or a data logger that acquires and records various time-series data.

[0017] For example, a still camera has a recording mode called continuous shooting mode, which takes 20 consecutive shots per second. In this recording mode, if the size of one photo data is 1MB, 1MB x 20 photos = 20MB of data is generated per second, so the bit rate of this recording mode is expressed as 20MB per second. While such a still camera is taking pictures in continuous shooting mode, the storage device that records the captured data must demonstrate a writing performance of at least the bit rate of the continuous shooting mode, that is, 20MB per second.

[0018] If the write performance of the storage device 200 drops below the bit rate of the recording mode (continuous shooting mode), writing of the generated data to the storage device will fail, resulting in data loss and causing a disadvantage to the user of the still camera. Therefore, the write performance of the storage device 200 is important to the information processing device 100. Therefore, for an information processing device 100 such as a still camera that requires write performance at or above a specific bit rate, guaranteeing that the storage device 200 can write data at or above the bit rate is called write performance guarantee.

[0019] On the other hand, the storage device 200 manages the correspondence between the LBA and the location on the storage medium where the latest data corresponding to that LBA is recorded. The storage device 200 according to this embodiment manages the correspondence, for example, as "the latest data of LBA=0x100 is recorded at address A on the storage medium" or "the latest data of LBA=0x0 is stored at address B on the storage medium." In other words, the storage device 200 manages the data recorded in the storage device 200 by addresses on the storage medium, not on the LBA space 400.

[0020] For example, when the storage device 200 uses a NAND flash memory as a storage medium, the storage medium can be managed in units of blocks of the NAND flash memory, as shown in Fig. 3. In this figure, for the sake of simplicity, the size of a block of the NAND flash memory is set to 1 MB, and five blocks 21 to 25 show a storage capacity of 5 MB.

[0021] The storage device 200 calculates its own free space by multiplying the number of blocks in the NAND flash memory in which data can be written by the block size of the NAND flash memory. Figure 3(A) shows a state in which no data has been written (corresponding to Figure 2(A)). At this time, the storage device 200 recognizes that the free space is 5 MB, so the amount of free space recognized by the information processing device 100 and the free space recognized by the storage device 200 are both 5 MB.

[0022] Figure 3(B) shows the state after the information processing device 100 has written 2MB of data from LBA=0x800 to the storage device 200 from the state of Figure 3(A). The storage device 200 allocates a storage area for the data requested to be written, but the LBA and the address of the storage medium to which the data of that LBA is written are not always the same. Figure 3(B) shows that blocks 21 and 22 have been allocated to 2MB of data from LBA=0x800 and the data has been written, and at this point the storage device 200 recognizes the available capacity as 3MB.

[0023] Figure 3(B) shows the state corresponding to Figure 2(B), where the amount of free space recognized by the information processing device 100 and the amount of free space recognized by the storage device 200 are both equal at 3 MB. Figure 3(C) shows the state after the information processing device 100 has further written 1.5 MB of data from LBA=0x800 to the storage device 200 from the state of Figure 3(B). Data has already been written to blocks 21 and 22 of the NAND flash memory, and data cannot be written to them unless they are erased. For this reason, the storage device 200 allocates a new block and writes the data therein.

[0024] 3C shows that blocks 23 and 24 of the NAND flash memory are allocated to the 1.5 MB of data from LBA=0x800 written from the information processing device 100 and written thereto. At this time, the old "1.5 MB of data from LBA=0x800" remains written in blocks 21 and 22. However, block 21 cannot be reused until an erase process is performed, and block 22 still contains 0.5 MB of the latest data from LBA=0x1400 to 0x17FF, so it cannot be reused until this 0.5 MB of data is copied to another block and then erased.

[0025] Garbage collection is an example of an internal process of the storage device 200 that copies the latest data recorded in a block to another block and makes the former (copy source) block reusable. While the storage device 200 is accessing the NAND flash memory for the internal process, it cannot write write data received from the information processing device 100 to the NAND flash memory, so the write performance of the storage device 200 as viewed from the information processing device 100 is degraded.

[0026] When the storage device 200 cannot execute internal processing to guarantee write performance, it does not recognize blocks 22 that require internal processing for reuse as free space, and in that case, the storage device 200 recognizes the free space as 1.5 MB in the state of Fig. 3(C).Thus, even though Fig. 2(C) and Fig. 3(C) are both results of the same write processing being performed from the same state (Fig. 2(A) and Fig. 3(A)), the information processing device 100 recognizes the free space amount of the storage device 200 as 3 MB, and the storage device 200 recognizes the free space as 1.5 MB.

[0027] In this state, if the information processing device 100 requests the storage device 200 to write an additional 3 MB according to its own recognition, the storage device 200 only has 1.5 MB of free space at that time, and therefore internal processing is required for blocks 21 and 22 to write the remaining 1.5 MB. As described above, the internal processing for reusing blocks of the NAND flash memory involves data copy processing (read processing and write processing) and erasure processing, and during the internal processing, data received from the information processing device 100 cannot be written to the NAND flash memory, so that the write performance as viewed from the information processing device 100 decreases and falls below the guaranteed write performance, and there is a risk that the guarantee of the write performance will be breached.

[0028] The storage device 200 of this embodiment can prevent such a guarantee of write performance from being breached, and is provided with a free space management unit that calculates the free space of a media serving as a storage medium (in this embodiment, a non-volatile storage medium such as a semiconductor memory) and holds the calculated free space, and is connected to an information processing device 100 (a specified external device) and has a function of notifying the information processing device 100 (external device) of information on the free space held in the free space management unit.

[0029] As shown in FIG. 4, the information processing device 100 according to the first embodiment is configured to include a sensor 101, a sensor control unit 102, a user interface 103, a user interface control unit 104, a data buffer 105, a data control unit 106, a storage device control unit 107, a free space management unit 108, a device driver 109, an interface 110, a data bus 111, and a control bus 112.

[0030] The sensor 101 is a device capable of observing images, sounds, light, temperature, humidity, etc., and data acquired by this sensor 101 is transferred to and stored in a data buffer 105 via a data bus 111. The sensor control unit 102 is configured to control the time frequency at which the sensor 101 acquires data and the amount of data generated (acquired), and to change the image resolution and the amount of data per unit time in a moving image (bit rate).

[0031] The user interface 103 is composed of, for example, a button, a touch panel, or a dial, and the user of the information processing device 100 uses this user interface 103 to change (select) the operations and operation settings of the information processing device 100. The user interface control unit 104 is configured to notify the data control unit 106 of the contents of the user's input, and to change the user interface 103 according to instructions from the data control unit 106.

[0032] The data buffer 105 is a memory that temporarily stores data input from the sensor 101 and data processed or generated by the data control unit 106. When writing data to or reading data from the storage device 200, this data buffer 105 is used as a data repository. This data buffer 105 is typically realized by a volatile memory (such as a DRAM).

[0033] The data control unit 106 has functions such as transmitting the user's selection obtained through the user interface 103 to the sensor control unit 102 and determining the recording position in the data buffer 105 of the data obtained from the sensor 101. The storage device control unit 107 manages the LBA space 400, and is configured to manage the amount of free space in the LBA space 400. The storage device control unit 107 also has a function of determining the top LBA and the number of sectors to be specified when reading and writing data to and from the storage device 200, and is provided with, for example, a file system function.

[0034] The free space management unit 108 manages the free space information of the storage device 200, and is configured to hold free space information obtained from the storage device 200 and notify the contents of the information to the data control unit 106. The device driver 109 has a function of understanding the specifications to which the storage device 200 conforms, and converting operations of the storage device 200 desired by the storage device control unit 107 into actual commands, etc.

[0035] The device driver 109 also has a function of transmitting responses and information received from the storage device 200 to the storage device control unit 107. Note that, as the device driver 109, for example, a Serial ATA (SATA) driver, a Small Computer System Interface (SCSI) driver, an NVM Express (NVMe) driver, or the like can be used.

[0036] The interface 110 has a function of connecting the information processing device 100 and the storage device 200 via the communication path 300. For example, a SATA host controller or a PCI Express (PCIe) root complex can be used. The data bus 111 is a data path connecting the sensor 101, the data buffer 105, and the interface 110. The data control unit 106 and the data buffer 105 may be connected by the data bus 111. The control bus 112 is a bus for various control data and inter-module communication.

[0037] As described above, each of these elements constituting the information processing device 100 may be implemented in hardware or software. In the case of being implemented in software, a processor or controller for executing the software is separately provided.

[0038] As shown in FIG. 5, the storage device 200 of this embodiment is configured to include a host interface 201, a command control unit 202, a data management unit 203, an available space management unit 204, a media management unit 205, a device control unit 206, a data buffer 207, a RAM 208, a media interface 209, a data bus 210, a control bus 211, a media 212, and a media channel 213.

[0039] The host interface 201 has a function of connecting the information processing device 100 and the storage device 200 via the communication path 300. The command control unit 202 interprets various commands received from the information processing device 100, and transmits instructions to each module in the storage device 200 and receives responses. The data management unit 203 manages the correspondence between the data recorded in the storage device 200 and the recording position on the medium, and is configured to manage at least the position on the medium where the latest data of each sector on the LBA space 400 is recorded, in association with that LBA.

[0040] The free space management unit 204 is configured to calculate the free space of the storage device 200 (i.e., the free space of the medium 212) based on the latest data and recording position information on the medium held by the data management unit 203, media usage status information managed by a media management unit 205 described later, and a recording data size (bit rate) per unit time given by the information processing device 100 or preset in the storage device 200, and to hold the calculated free space. The free space management unit 204 also has a function of returning the held information on the free space to the information processing device 100 upon receiving a "request to notify free space" from the information processing device 100.

[0041] The media management unit 205 manages the media 212 (non-volatile storage medium, in this embodiment, semiconductor memory such as NAND flash memory) mounted on the storage device 200, and is configured to be able to perform information and processing specific to the media. The device control unit 206 has a function of controlling each of the above-mentioned modules to realize the storage function of the storage device 200. In addition to processing commands transmitted from the information processing device 100, the storage device 200 needs to perform internal processing such as sorting data recorded on the media 212, reliability assurance processing, and statistical information processing, and the device control unit 206 according to this embodiment also has a function of arbitrating these processes and command processing.

[0042] The data buffer 207 has a function of temporarily storing data when data is transferred between the information processing device 100 and the medium 212. The data buffer 207 is realized by a RAM such as a DRAM. The RAM 208 is used to allocate data required for the operation of each module. The media interface 209 is composed of a protocol conversion device for transferring data to the media 212, issuing commands, and receiving responses. If the media 212 is a NAND flash memory, the media interface 209 is a NAND interface.

[0043] Data bus 210 is a path used for data transfer, and control bus 211 is a path for exchanging commands, instructions, responses, and the like other than data. Media 212 is a non-volatile storage medium made of semiconductor memory, and storage device 200 realizes its function as a storage device by writing data to media 212 and further reading data from media 212. Media channel 213 is a bus that connects media interface 209 and media 212. Such media channel 213 may be one in which the data bus and the control bus are separate, or one in which the same signal line is shared by data and control.

[0044] In this embodiment, specifically, the medium 212 is a NAND flash memory. That is, the media interface 209 is a NAND interface, the media management unit 205 is a NAND management unit, and the media channel 213 is a NAND channel. In this embodiment, the medium 212 is a NAND flash memory, but the same applies to other non-volatile storage media. For example, the medium 212 may be a Magnetoresistive Random Access Memory (MRAM) or a Phase-change Memory (PCM), or may be other semiconductor memory or a non-semiconductor non-volatile storage medium.

[0045] 1 to 3, when the free space of the storage device 200 becomes small, the storage device 200 must execute, at its own discretion, an internal process such as garbage collection to increase the free space. However, while the storage device 200 is executing the internal process, the medium 212 is temporarily occupied by the internal process, and access to the medium 212 based on an access request from the information processing device 100 cannot be executed.

[0046] As a result, the write performance of the storage device 200 seen from the information processing device 100 is degraded while the internal processing is being executed, compared to when the internal processing is not being executed. This degraded write performance due to the influence of the internal processing often makes it difficult to guarantee the write performance required by the information processing device 100. Furthermore, the information processing device 100 cannot grasp whether the write performance of the storage device 200 can be guaranteed even when the internal processing is executed, whether the write performance can be guaranteed even when a small amount of internal processing is executed, or whether the desired write performance can be guaranteed in the first place. Therefore, as a state related to the write performance of the storage device 200, that is, a write performance state, two states are defined: a state in which the write performance required by the information processing device 100 is guaranteed, and a state in which the write performance is not guaranteed. The former is referred to as a "write performance guaranteed state" and the latter is referred to as a "write performance non-guaranteed state".

[0047] 6 shows state transitions related to the write performance of the storage device 200, including the write performance guaranteed state. The write performance state of the storage device 200 has at least two states, the write performance guaranteed state 252 and the write performance non-guaranteed state 251. In addition to these two states, multiple states may be provided, but the write performance of these states is classified as either guaranteed or not guaranteed, so in this embodiment, only these two states are illustrated.

[0048] The write performance guaranteed state 252 and the write performance non-guaranteed state 251 can transition from one to the other (state transition 253 and state transition 254). When it is necessary for the data write performance of the storage device 200 to be guaranteed, the information processing device 100 transitions the write performance state of the storage device 200 from the write performance non-guaranteed state 251 to the write performance guaranteed state 252 (state transition 253).

[0049] Furthermore, when it is not necessary for the storage device 200 to guarantee data write performance or when it is determined that the free space of the storage device 200 is small, the information processing device 100 transitions the write performance state of the storage device 200 from the write performance guaranteed state 252 to the write performance non-guaranteed state 251 (state transition 254). When the information processing device 100 determines that the free space of the storage device 200 is small, it transitions the write performance state of the storage device 200 to the write performance non-guaranteed state in order to notify the storage device 200 that it may execute internal processing required to recover the free space by explicitly transitioning to a state in which the write performance is not guaranteed.

[0050] Furthermore, when the free space falls below a threshold value previously determined by the storage device 200 itself while the write performance state is the write performance guaranteed state 252, the storage device 200 transitions the write performance state to the write performance non-guaranteed state 251 (state transition 254). The storage device 200 transitions the write performance state to the write performance non-guaranteed state 251 at its own discretion when the storage device 200 itself determines that the write performance required by the information processing device 100 cannot be guaranteed due to a decrease in free space, or when it determines that internal processing is essential to continue functioning as a storage device.

[0051] The storage device 200 has a function of notifying the information processing device 100 of whether its own write performance state is a write performance non-guaranteed state 251 or a write performance guaranteed state 252. In the storage device 200, the device control unit 206 records the current write performance state. Below, a procedure by which the information processing device 100 transitions the write performance state of the storage device 200 to the write performance guaranteed state will be described with reference to the flowchart in FIG.

[0052] The information processing device 100 judges whether or not it is necessary to guarantee the write performance of the storage device 200 (step S1101). An example of a case where it is necessary to guarantee the write performance of the storage device 200 is when data is recorded in the storage device 200 at a desired bit rate. When the information processing device 100 judges that it is necessary to guarantee the write performance of the storage device 200 (step S1101, Yes), it judges whether or not the free space obtained from the storage device 200 is sufficient to record for a sufficient time at the bit rate (step S1102). In this step S1102, the information processing device 100 judges the remaining recording time based on a criterion such as whether it is possible to shoot for 1 second or 5 seconds at the desired bit rate.

[0053] If the free space is sufficient (step S1102, Yes), the information processing device 100 checks whether the write performance state of the storage device 200 is already in a write performance guaranteed state (step S1103). If the write performance state of the storage device 200 is already in a write performance guaranteed state (step S1103, Yes), the information processing device 100 ends the process as is, and if the write performance state of the storage device 200 is in a write performance non-guaranteed state (step S1103, No), the information processing device 100 sends a request to the storage device 200 to transition the write performance state to a write performance guaranteed state (step S1104). If the result of the transition request of the write performance state received from the storage device 200 is successful (step S1105, Yes), the transition to a state in which the write performance is guaranteed is completed, and the process ends.

[0054] On the other hand, if the write performance state transition request has failed (step S1105, No), a notice to that effect is sent (step S1106) and the process ends. If it is found that the free space of the storage device 200 is insufficient despite the need for write performance guarantee of the storage device 200 (step S1102, No), a check is made as to whether the write performance state of the storage device 200 is in a write performance non-guaranteed state (step S1107).

[0055] If the write performance state is already in the write performance non-guaranteed state (step S1107, Yes), a notice is issued that there is insufficient free space in the storage device 200 (step S1108), and the process ends. If the write performance state is in the write performance guaranteed state (step S1107, No), a request is sent to the storage device 200 to transition the write performance state to the write performance non-guaranteed state (step S1109).

[0056] If the write performance state transition request received from the storage device 200 is successful (step S1110, Yes), the transition to a state in which write performance is not guaranteed is completed, and the user is notified that there is insufficient free space (step S1108), and the process ends. On the other hand, if the write performance state transition request is unsuccessful (step S1110, No), a notification is issued that the transition has failed (step S1111), and that there is also insufficient free space (step S1108), and the process ends.

[0057] If the write performance guarantee is not required (step S1101, No), the information processing device 100 checks whether the write performance state of the storage device 200 is in a write performance non-guaranteed state (step S1112). If the write performance state of the storage device 200 is in a write performance non-guaranteed state (step S1112, Yes), the information processing device 100 ends the process as is, and if the write performance state of the storage device 200 is in a write performance guaranteed state (step S1112, No), the information processing device 100 requests the storage device 200 to transition the write performance state to a write performance non-guaranteed state (step S1113).

[0058] Then, the information processing device 100 receives the result of the transition process from the storage device 200, and if the result is successful (step S1114, Yes), the process ends, whereas if the transition process is unsuccessful (step S1114, No), the user is notified that the state transition has failed (step S1115), and the process ends. In this way, a request from the information processing device 100 to the storage device 200 to confirm the write performance state or a request to transition the write performance state is executed by a dedicated command via the communication path 300.

[0059] That is, the storage device control unit 107 of the information processing device 100 instructs the device driver 109 to send a request, and the device driver 109 uses an appropriate command and arguments to send the request to the communication path 300 via the interface 110. In the storage device 200, the command control unit 202 receives the command indicating the request sent from the information processing device 100 via the host interface 201, and interprets and executes the request.

[0060] In addition, the command specifications to which the storage device 200 conforms usually include commands called "vendor specific commands" in addition to commonly used commands such as read and write. Vendor specific commands are used to define system specific commands according to the needs of the system, and for example, vendor specific commands also exist in NVMe.

[0061] In this embodiment, a request from the information processing device 100 to the storage device 200 to check the write performance state or to transition the write performance state can be realized by using this vendor-specific command. In addition, in the case of NVMe, there is a command called Get Log Page for acquiring the state and statistical information (Log) of the storage device 200, a Get Features command for acquiring and setting the state of the functions (Features) provided in the storage device 200, and a Set Features command.

[0062] The Get Log Page command and the Get Features command are used to acquire the write performance status of the storage device 200, and the Set Features command can also be used to transition the write performance status. When using the Get Log Page command or the Set and Get Features commands, this can be achieved by using the vendor-specific Log Page and the vendor-specific Feature, respectively.

[0063] Next, a procedure for causing the storage device 200 to transition its write performance state from the write performance guaranteed state 252 to the write performance non-guaranteed state 251 will be described with reference to the flowchart of FIG.

[0064] The storage device 200 checks whether the free space is below a threshold preset by the storage device 200 itself (step S2051). If the free space is equal to or greater than the preset threshold (step S2051, No), there is no need to transition the write performance state to a non-guaranteed state, and the process ends. If the free space is below a threshold preset by the storage device 200 itself (step S2051, Yes), it is determined that it is impossible for the storage device 200 to continue the write process while guaranteeing the preset write performance in order to continue providing the function of a storage device.

[0065] Therefore, the CPU 101 checks whether the write performance state is the write performance guaranteed state 252 (step S2052), and if the write performance state is the write performance guaranteed state 252 (step S2052, Yes), even if there is no request from the information processing device 100, the write performance state is transitioned to the write performance non-guaranteed state 251 (step S2053), and if the write performance state is the write performance non-guaranteed state 251 (step S2052, No), the processing is terminated.

[0066] As described above, the free space threshold set by the storage device 200 itself is a value indicating that the information processing device 100 cannot guarantee the desired write performance if the free space falls below this value. It is assumed that this is set when the information processing device 100 transitions the write performance state of the storage device 200 to the write performance guaranteed state 252 (step S1104). In this way, the storage device 200 transitions its write performance state to the write performance non-guaranteed state 251 on its own when it detects that the preset write performance cannot be guaranteed due to a decrease in free space, even if it does not receive a request to transition the write performance state from the information processing device 100.

[0067] Next, a procedure for the information processing device 100 to acquire the free space from the storage device 200 will be described with reference to the flowchart in Fig. 9. The information processing device 100 can acquire the initial value of the free space of the storage device 200 by performing the process of this procedure, for example, at the time of startup. Of course, the free space of the storage device 200 may be grasped appropriately by performing this process at any timing other than the time of startup.

[0068] First, the data control unit 106 instructs the free space management unit 108 to obtain the free space of the connected storage device 200 (step S1001). At this time, the data control unit 106 also indicates to the free space management unit 108 the bit rate of the data to be recorded in the storage device 200. The data to be recorded includes not only main data such as moving images, still images, and audio, but also additional information of the data. This additional information is called metadata, and includes, for example, position information and time information.

[0069] Then, the free space management unit 108, having received the instruction, presents the bit rate to the storage device control unit 107 and instructs it to obtain free space information from the storage device 200 (step S1002), and the storage device control unit 107, having received the instruction, instructs the device driver 109 to issue a command to obtain free space information in accordance with the protocol conforming to the storage device 200 (step S1003).

[0070] If it is necessary to write management data of the LBA space 400 to the storage device 200, the storage device control unit 107 may add the bit rate of the management data to the bit rate received from the free space management unit 108. The management data includes, for example, a File Allocation Table (FAT). The device driver 109 prepares appropriate commands and arguments based on the instruction, and issues the commands to the storage device 200 via the interface 110 and the communication path 300 (step S1004).

[0071] The device driver 109 receives a response to the command issued in step S1004 (step S1005), extracts free space information from the received response, and then sends the response to the free space management unit 108 (step S1006). The free space management unit 108, which has received the response from the device driver 109, performs appropriate conversion according to the content of the received free space information and sends the response to the data control unit 106 (step S1007). Note that the conversion process performed in step S1007 is, for example, multiplying the acquired free space information by 1024 when the unit of the received free space information is gigabytes and the unit of the free space required by the data control unit 106 is MB, but if the conversion process is unnecessary, the conversion process does not have to be performed.

[0072] In this way, the information processing device 100 can grasp the true free space of the storage device 200 (free space of the medium 212 (non-volatile storage medium)) at which the information processing device 100 can guarantee the desired write performance of the storage device 200. Note that the information processing device 100 may have a plurality of data recording modes, and may acquire free space information at which the storage device 200 can guarantee the write performance for each of the plurality of data recording modes. When acquiring free space for each of the plurality of data recording modes, this can be achieved by repeating the procedure of FIG. 9 for each recording mode.

[0073] Next, the procedure for calculating free space in the storage device 200 will be described with reference to the flowchart in Fig. 10. The storage device 200 can calculate the initial value of the free space by performing this process, for example, at startup. Of course, regardless of the presence or absence of a free space acquisition request from the information processing device 100, the free space can be appropriately kept up to date by performing this process at any timing other than startup.

[0074] First, the device control unit 206 of the storage device 200 instructs the media management unit 205 to update the usage status of the medium 212 (step S2001), and the media management unit 205, having received the instruction, updates the usage status of the medium 212 (step S2002). Examples of information indicating the usage status of the medium 212 include the number of blocks (called free blocks) that do not hold valid data and can be used to record new data, the number of blocks (active blocks) that hold valid data and cannot be used to record new data, the total size of valid (latest) data that has been written, the total size of invalid (old) data that has been written, etc. Some of this information, or other information not described here, may also be used.

[0075] Then, when the media management unit 205 updates the information indicating the usage status of the medium 212 to the latest information, the device control unit 206 instructs the free space management unit 204 to calculate and update the free space (step S2003). The free space management unit 204 calculates and holds the free space using a predetermined method (step S2004). A specific example of a method for calculating the free space is to multiply the number of free blocks by the block size of the medium 212.

[0076] When this method is used, the free space is expressed as a specific data size. For example, if the number of free blocks is 10 and the block size of the medium 212 is 32 MB, the free space is 10 x 32 = 320 MB. As another example of a method for calculating the free space, it is also possible to change the calculation method depending on a bit rate separately specified by the information processing device 100.

[0077] For example, when internal processing cannot be performed to guarantee data writing at the presented bit rate, the result of the simple multiplication as described above is regarded as the free space, and when internal processing can be performed while guaranteeing writing at the presented bit rate, a value obtained by adding a certain amount of capacity to the result of the simple multiplication is regarded as the free space. In this way, the free space is not necessarily the remaining data size that can be written to the storage device 200 when the storage device 200 is not performing any internal processing.

[0078] The information processing device 100 is capable of calculating the continuous shooting time of moving images, the number of continuous shooting still images, the continuous recording time of weather data (temperature, humidity, atmospheric pressure), and the like, using the free space of the storage device 200 acquired in the procedure shown in Fig. 7. This can be calculated from the acquired free space of the storage device 200 and the bit rate of data requested to be recorded in the storage device 200. For example, if the bit rate of the data requested to be recorded is 4 MB per second, and the free space received from the storage device 200 is 800 MB, it can be calculated that continuous recording is possible for only 800÷4=200 seconds.

[0079] Next, a procedure for calculating the remaining continuous recording time of data to be recorded in the storage device 200 by the information processing device 100 will be described with reference to the flowchart shown in FIG. First, the user interface 103 presents a method for changing the recording mode to the user (step S1051). The user may change the recording mode by, for example, touching a touch panel, rotating an operation knob, pressing an operation button, or the like.

[0080] The user interface control unit 104 checks whether the user has changed the recording mode (step S1052), and if the user has changed the recording mode (step S1053, Yes), the user interface control unit 104 notifies the data control unit 106 that the recording mode has been changed (step S1054). At this time, the user interface control unit 104 transmits information capable of identifying the newly selected recording mode to the data control unit 106.

[0081] The data control unit 106, which has received the notification of the change in the recording mode, instructs the free space management unit 108 to obtain the latest free space (step S1055). The free space management unit 108, which has received the instruction to obtain the latest free space, judges whether or not it is necessary to obtain free space information from the storage device 200 (step S1056). For this judgment, for example, conditions such as whether or not a predetermined time has passed since the last free space was received, or whether or not data has been written to the storage device 200 since the last free space was received, can be used.

[0082] 7 to receive the latest available space (step S1057), and then the available space management unit 108 notifies the data control unit 106 of the received and calculated available space (step S1058).On the other hand, if it is determined that there is no need to reacquire the available space (step S1056, No), the available space management unit 108 notifies the data control unit 106 of the available space it holds (step S1059).

[0083] Next, the data control unit 106 acquires the bit rate of the new recording mode notified by the user interface control unit 104 (step S1060). The data control unit 106 holds, for example, a list in which processable recording modes and the bit rate of each recording mode are associated, and can acquire the bit rate of the new recording mode by referring to the table. If the bit rate of the new recording mode has been acquired when sending an instruction to acquire free space to the free space management unit 108, the bit rate of the new recording mode is already clear, and therefore there is no need to execute this step.

[0084] After that, the data control unit 106 calculates the continuous recordable time in the new recording mode from the free space acquired in step S1058 or step S1059 and the bit rate acquired in step S1060 (step S1061). As described above, for example, if the bit rate of the new recording mode is 8 MB per second and the free space is 800 MB, the remaining continuous recordable time is 800÷8=100 seconds.

[0085] Then, the data control unit 106 notifies the user interface control unit 104 of the calculated remaining continuous recordable time (step S1062), and the user interface control unit 104 notifies the user of the remaining continuous recordable time received from the data control unit 106 through the user interface 103 (step S1063). On the other hand, if the recording mode has not been changed (step S1053, No), it is determined whether or not it is necessary to update the remaining continuous recordable time in the current recording mode (step S1064). The conditions for this determination may be, for example, whether a predetermined time has passed since the last time free space was received, or whether data has been written to the storage device 200 since the last time free space was received.

[0086] If it is determined that the remaining continuous recording time needs to be updated (step S1064, Yes), the process proceeds to step S1055. If it is determined that the remaining continuous recording time does not need to be updated, the process returns to checking whether the user has changed the recording mode (S1052). With the above, the procedure for calculating the remaining continuous recording time for the storage device 200 by the information processing device 100 and the procedure for presenting the remaining continuous recording time to the user are completed. Note that, in this embodiment, a moving image is used as an example of the calculation of the remaining continuous recording time, but even if the recorded data is a still image or weather data (temperature, humidity, atmospheric pressure), the information processing device 100 can calculate the number of continuously recordable frames and the continuous recordable time by the same procedure and present it to the user.

[0087] According to this embodiment, by going through the above procedure, information regarding the free space in the memory device 200 can be shared between the memory device 200 and the information processing device 100, and as a result, the writing performance from the information processing device 100 to the memory device 200 can be guaranteed.

[0088] Next, a procedure for writing data from the information processing device 100 to the storage device 200 while ensuring the write performance will be described with reference to the flowcharts of FIGS. 12(a) and 12(b). First, the information processing device 100 acquires the bit rate of data to be recorded in the storage device 200 (step S3001). The method and procedure for acquiring the bit rate of data to be written by the information processing device 100 uses the method and procedure using the user interface 103 as described in the flowchart of FIG.

[0089] Next, the information processing device 100 acquires the free space from the storage device 200 (step S3002). The procedure for acquiring the free space of the storage device 200 by the information processing device 100 is as described in the flowchart of FIG. 9. After acquiring the free space from the storage device 200, the information processing device 100 next calculates the remaining recordable time and presents it to the user (step S3003). The calculation of the remaining recordable time and the process of presenting it to the user are as described in the flowchart of FIG.

[0090] The information processing device 100 then checks the calculated remaining recordable time, and if it is zero or too short (step S3004, Yes), notifies the user of this fact (step S3005). For example, if the remaining recordable time is set to be one second as a condition for recording, the information processing device 100 notifies the user that there is insufficient free space if the remaining recordable time is less than one second. Then, the process waits until the user operates the user interface 103 to select a different recording mode (step S3006), and if the user selects a different recording mode, the process returns to step S3001 and continues. This is because if the user selects a recording mode with a lower bit rate (amount of recorded data per unit time), the remaining recordable time becomes longer.

[0091] Next, if the calculated remaining recordable time is sufficient (step S3004, No), the information processing device 100 transitions the write performance state of the storage device 200 to the write performance guaranteed state 252 (step S3007). The procedure for the transition process of the write performance state of the storage device 200 by the information processing device 100 is as described using the flowchart in FIG. 7. Note that the process of step S3007 may be performed in response to a user operation (operation using the user interface 103). For example, it may be performed in response to the user pressing an operation button that indicates preparation to start recording.

[0092] If the transition of the write performance state of the storage device 200 fails (step S3008, No), a notice to that effect is presented to the user (step S3009) and the process is terminated, whereas if the transition of the write performance state of the storage device 200 is successful (step S3008, Yes), writing begins in a state in which the write performance is guaranteed (step S3010). Even during the period in which performance-guaranteed writing is being performed, the information processing device 100 can check the free space of the storage device 200 periodically or when some event occurs (step S3011). This makes it possible, for example, to update the remaining recordable time or to determine the timing to stop recording.

[0093] When the free space falls below a threshold value previously determined by the information processing device 100 (Yes in step S3012), the information processing device 100 stops recording (step S3013) and transitions the write performance state of the storage device 200 to a write performance non-guaranteed state (step S3014). The threshold value can be the same as the condition used in the condition determination in step S3004.

[0094] Then, the information processing device 100 notifies the user that the write performance cannot be guaranteed due to a lack of free space (step S3015), and then returns to step S3001 and continues the process. Furthermore, if there is still sufficient free space (step S3012, No), it checks whether the user has stopped shooting (step S3016). If the user has stopped shooting (step S3016, Yes), the information processing device 100 transitions the write performance state of the storage device 200 to a write performance non-guaranteed state (step S3017), and notifies the user that the write performance has transitioned to a state where the write performance is not guaranteed (step S3018). The procedure of the transition process of the write performance state of the storage device 200 by the information processing device 100 is as described using the flowchart of FIG. 7. Then, the information processing device returns to step S3001 and continues the process.

[0095] Next, using a specific example, we will explain how the procedure actually works, as explained using the flowchart of Figure 12, by having the information processing device 100 and the storage device 200 share the free space that allows the storage device 200 to guarantee writing performance, thereby allowing the information processing device 100 to write data to the storage device 200 while maintaining the desired bit rate.

[0096] Fig. 13 is a series of diagrams showing in chronological order the writing of data from the information processing device 100 shown in Fig. 12 to the storage device 200, with the order of time being (A) → (B) → (C) → (D) → (E) → (F). In the example of Fig. 13, the total capacity of the storage device is 6 MB, and the LBA space that specifies the data write destination in the storage device when the information processing device 100 writes data is also 6 MB (from 0x0 to 0x2FFF). Furthermore, in Fig. 13, the block size of the NAND flash memory, which is a non-volatile storage medium mounted in the storage device 200, is 1 MB, and the remaining recording time threshold that is the criterion for the information processing device 100 to stop writing is 1.5 seconds.

[0097] Fig. 13(A) shows the state before the information processing device 100 starts writing data to the storage device 200. There is no used area in the LBA space, and all six NAND flash memory blocks are free. The following description will be given with reference to the procedure shown in Fig. 12 and the schematic diagram shown in Fig. 13. The information processing device 100 acquires the bit rate of the data to be recorded (step S3001). Here, the bit rate is set to 1 MB per second, and it is assumed that the storage device 200 does not have enough capacity for internal processing to guarantee the write performance of 1 MB per second.

[0098] The information processing device 100 acquires the free space of the storage device 200 (step S3002). With reference to Fig. 13(A), the free space at this point is 6 MB, so the storage device 200 responds to the information processing device 100 with "the free space is 6 MB." Upon receiving this free space, the information processing device 100 calculates the remaining recordable time from the free space (step S3003).

[0099] At this time, the free space is 6 MB and the bit rate is 1 MB per second, so the remaining recordable time at this bit rate is 6÷1=6 seconds. This remaining recordable time of 6 seconds is longer than the remaining recording time threshold of 1.5 seconds at which the information processing device 100 stops recording data (step S3004, No), so the information processing device 100 transitions the write performance state of the storage device 200 to the write performance guaranteed state 252 (step S3007).

[0100] Here, it is assumed that the state transition by the storage device 200 has been successful (Yes in step S3008). When the information processing device 100 determines that the storage device 200 has successfully transitioned to the write performance guaranteed state 252, it starts writing data at the bit rate (step S3010). First, if the information processing device 100 writes data to an area of ​​1 MB (up to 0xFFF) from LBA=0x800 in the storage device 200, the storage device 200 writes this data to block number 0 of the NAND flash memory. The state after this writing is shown in FIG. 13(B).

[0101] The current write performance state of the storage device 200 is the write performance guaranteed state 252, and this write will be completed within one second as expected by the information processing device 100, so the information processing device 100 checks the free space of the storage device 200 (step S3011). However, as shown in Fig. 13(B), the free space of the storage device 200 is 5 MB, so the storage device 200 notifies the information processing device 100 that "the free space is 5 MB."

[0102] Upon receiving this notification, the information processing device 100 again checks whether the free space, i.e., the remaining recording time, exceeds the threshold (step S3011). The current bit rate is 1 MB per second, and in this example, the threshold of the remaining recording time at which the information processing device 100 stops recording data is 1.5 seconds, so the minimum required free space is 1 x 1.5 = 1.5 MB. Therefore, the current free space of 5 MB remains sufficient (step S3012, No).

[0103] Next, the information processing device 100 checks whether the user has stopped recording (step S3016). If it is assumed here that the user has not stopped recording (No in step S3016), the information processing device 100 continues recording data at the desired bit rate (step S3010). Then, it is assumed that the information processing device 100 writes data in the following order: First, data is written to an area from LBA 0x1000 to 1 MB (up to 0x17FF), and the storage device 200 writes this data to the first block of the NAND flash memory. The state immediately after this writing is shown in FIG. 13(C). The free space is 4 MB, which is larger than the threshold of 1.5 MB at which the information processing device 100 stops recording data, so the data recording process continues.

[0104] Next, the data is written to an area from LBA=0x2800 to 1MB (up to 0x2FFF), and the storage device 200 writes this data to the second block of the NAND flash memory. The state immediately after this writing is shown in Fig. 13(D). Since the free space is 3MB, which is larger than the threshold of 1.5MB at which the information processing device 100 stops writing data, the data writing process continues.

[0105] Next, the data is written to the area from LBA=0x1400 to 1MB (up to 0x1BFF), and the storage device 200 writes this data to the third block of the NAND flash memory. FIG. 13(E) shows the state immediately after this writing. The data written to the area from LBA=0x1400 to 0x17FF at the time of FIG. 13(C) becomes "old data" due to this writing (overwriting). This is not reflected in the LBA space 400, but the storage device 200 leaves the "old data" written to the first block of the NAND flash memory as it is. As a result, the free space is 2MB. This free space is larger than the threshold of 1.5MB at which the information processing device 100 stops recording data, so the data recording process continues.

[0106] Next, data is written again to the area from LBA=0x1000 to 1MB (0x17FF) (step S3010), and the storage device 200 writes this data to block number 4 of the NAND flash memory. The state immediately after this writing is shown in Figure 13(F). As a result of this writing, all of the data recorded in block number 1 of the NAND flash memory and some of the data recorded in block number 3 become "old data".

[0107] The storage device 200 cannot execute internal processing to guarantee the write performance at the current bit rate, and cannot reuse block 1 of the NAND flash memory, where all data has become "old data," or block 3, where some data has become "old data," so the free space of the storage device 200 becomes 1 MB. Then, when the information processing device 100 checks the free space of the storage device 200 (step S3011), the free space is 1 MB, which is less than the threshold of 1.5 MB at which the information processing device 100 stops recording data (step S3012).

[0108] Therefore, the information processing device 100 stops the data recording (step S3013), and transitions the write performance guaranteed state of the storage device 200 to the write performance non-guaranteed state 251 (step S3014). Here, it is assumed that the state transition is successful. Then, the information processing device 100 notifies the user that data recording at the bit rate has been stopped due to insufficient free space in the storage device 200 (step S3015).

[0109] Thereafter, in the procedure from step S3001 to step S3006, the information processing device 100 checks whether the user has changed the bit rate of the data to be recorded or whether the free space of the storage device 200 has been restored, and checks whether data writing to the storage device 200 with guaranteed write performance can be executed again. The above is the state when data is written from the information processing device 100 to the storage device 200 with guaranteed write performance according to the procedure shown in FIG.

[0110] 13(F), there is 2.5MB of free space in the LBA space. However, there is only 1.5MB of free space in the storage device 200. Because the free space threshold at which the information processing device 100 stops recording is 1.5MB, if the information processing device 100 judges based only on the free space size in the LBA space 400, there is a possibility that the information processing device 100 will continue writing data even in the state of FIG. 13(F).

[0111] In such a case, adverse effects such as loss of data to be written and unstable operation of the storage device 200 and information processing device 100 may occur, which may cause disadvantages to the user of the information processing device 100. However, according to this embodiment, adverse effects such as loss of data to be written and unstable operation of the storage device 200 and information processing device 100 can be prevented.

[0112] Next, a second embodiment of the present invention will be described. In the first embodiment, as shown in Fig. 9, the free space information notified from the storage device 200 to the information processing device 100 is a specific size (a value in units of megabytes, etc.), so a large amount of information is required to express a large size. In view of this situation, in the second embodiment, the unit of the free space information notified from the storage device 200 to the information processing device 100 is a preset size, and the free space information notified from the storage device 200 to the information processing device 100 is information indicating how many times the unit size.

[0113] For example, if the free space on a storage device is 128 gigabytes, then expressing this value in bytes requires 37 bits since 128 gigabytes is 2 to the power of 37 bytes. Here, if the unit size of free space between the information processing device 100 and the storage device 200 is previously determined to be 1 gigabyte, then it will suffice to notify only 128 of the 128 gigabytes of free space.

[0114] Therefore, since 128 is the seventh power of 2 and requires only seven bits, a significant reduction in the amount of information can be achieved and large capacity can be easily expressed. A specific implementation method is to send unit size information together when the device driver 109 sends a free space information acquisition command to the storage device 200 (step S1004) in the process in which the information processing device 100 acquires free space information of the storage device 200 (the process explained in the flowchart shown in FIG. 9).

[0115] Next, a third embodiment of the present invention will be described. In the second embodiment, a unit size is set in the free space information notified from the storage device 200 to the information processing device 100. In the third embodiment, this unit size can be changed arbitrarily. A specific implementation method is to send unit size information every time the device driver 109 sends a free space information acquisition command to the storage device 200 (step S1004) in the process in which the information processing device 100 acquires free space information on the storage device 200 (the process explained in the flowchart of FIG. 9).

[0116] Next, a fourth embodiment of the present invention will be described. In the third embodiment, information on the unit size itself is added to the free space information acquisition command in order to change the unit size, whereas in the fourth embodiment, the information processing device 100 and the storage device 200 share the same table for the unit size of the free space information, and are configured to also notify the number (index) of the table when sending the free space information acquisition command.

[0117] In this embodiment, it is preferable that the information processing device 100 and the storage device 200 share a table showing the correspondence between the numbers specified in the free space information obtainment command and the unit sizes, as shown in Fig. 14. In this case, the information processing device 100 refers to Fig. 14 and specifies the number of the desired unit size in the process of issuing the free space information obtainment command to the storage device 200 (step S1004).

[0118] Furthermore, the storage device 200 extracts the number of the desired unit size from the command received from the information processing device 100, and the free space management unit 204 identifies the unit size from its own table of Fig. 14, expresses the free space information as a multiple of this unit size, and returns it to the information processing device 100. According to this fourth embodiment, various unit sizes can be supported by updating the table of Fig. 14.

[0119] Next, a fifth embodiment of the present invention will be described. In the second embodiment, a unit size is set for the free space information notified from the storage device 200 to the information processing device 100, whereas in the fifth embodiment, the block size of the NAND flash memory or an integer multiple thereof is used as the unit size. According to the fifth embodiment, the block size of the NAND flash memory is set as the unit size of the free space information, so that the storage device using the NAND flash memory as a non-volatile storage medium can be effectively utilized.

[0120] Next, a sixth embodiment of the present invention will be described. In the first embodiment, the free space information notified from the storage device 200 to the information processing device 100 is information regarding the size of the free space itself, whereas in the sixth embodiment, the free space information notified from the storage device 200 to the information processing device 100 is information indicating whether the current free space is equal to a size previously set in the storage device 200 by the information processing device 100 (either equal or not).

[0121] According to the sixth embodiment, free space information can be displayed in one bit, and the processing of the information processing device 100 can be reduced when there is sufficient free space remaining. The size of the comparison target can be notified to the storage device 200 when the free space information acquisition command is sent (step S1004) in Fig. 9, for example. In this case, the storage device 200 compares the received size of the comparison target with the free space held by the free space management unit 204 of the storage device 200, and returns the result (whether they are equal or not) to the information processing device 100.

[0122] Next, a seventh embodiment of the present invention will be described. In the sixth embodiment, the free space information notified from the storage device 200 to the information processing device 100 is information indicating whether the free space is equal to a preset size, whereas in the seventh embodiment, the free space information notified from the storage device 200 to the information processing device 100 is information indicating whether the free space is below a preset threshold value.

[0123] For example, if the free space threshold is set to 1 gigabyte, when the information processing device 100 acquires free space information with 2 gigabytes of free space remaining, it can acquire information from the storage device 200 that "the free space is not below the threshold." Also, if the free space threshold is similarly set to 1 gigabyte, when the information processing device 100 acquires free space information with 500 megabytes of free space remaining, it can acquire information from the storage device 200 that "the free space is below the threshold."

[0124] In this way, the information processing device 100 can obtain information about the free space of the storage device 200 that is directly related to the subsequent response (action), and the possibility of missing a state change is reduced, stabilizing the operation of the information processing device 100. Also in this embodiment, a method is considered in which the size to be compared is notified to the storage device 200 at the same time as sending the free space information acquisition command (step S1004) in Fig. 9. In this case, the storage device 200 compares the received size to be compared with the free space held by the free space management unit 204 of the storage device 200, and returns the result (whether it is smaller or not) to the information processing device 100.

[0125] Next, an eighth embodiment of the present invention will be described. In the seventh embodiment, the free space information notified by the storage device 200 to the information processing device 100 is information indicating whether the free space is below a preset threshold, whereas in the eighth embodiment, the free space information notified by the storage device 200 to the information processing device 100 is information indicating whether the free space is above a certain threshold.

[0126] The size (threshold) to be compared may be notified to the storage device 200 when the free space information acquisition command is sent (step S1004) in Fig. 9. In this case, the storage device 200 compares the received size to be compared with the free space held by the free space management unit 204 of the storage device 200, and returns the result (whether it exceeds or does not exceed) to the information processing device 100.

[0127] Next, a ninth embodiment of the present invention will be described. In the first embodiment, a dedicated command for acquiring free space information is executed as a method for notifying the information processing device 100 of free space information from the storage device 200, whereas in the ninth embodiment, free space information is included in a response to a write command sent from the information processing device 100 to the storage device 200. For example, in NVMe, a response to a write command is defined as 16 bytes, of which 4 bytes are unused. A method of writing free space information into this 4-byte area is considered.

[0128] That is, in the first embodiment, a request for notification of available space from the information processing device 100 and notification of available space information to the information processing device 100 use a command for a dedicated purpose, whereas in this embodiment, a request for notification of available space from the information processing device 100 and notification of available space information to the information processing device 100 are included in a command for another purpose. Note that it is preferable to use both the method of embedding available space information in the response to an existing command and the method of acquiring available space information using a command intended to acquire available space information in combination.

[0129] Next, a tenth embodiment of the present invention will be described. In the sixth embodiment, the free space information of the storage device 200 is information indicating whether the current free space is equal to a size previously set in the storage device 200 by the information processing device 100 (whether it is equal or not) (in the seventh embodiment, whether it is below a threshold value; in the eighth embodiment, whether it is above a threshold value), whereas in the tenth embodiment, the free space information of the storage device 200 is notified to the information processing device 100 from the storage device 200 when a condition previously set by the information processing device 100 is satisfied.

[0130] According to the tenth embodiment, the information processing device 100 does not need to actively obtain free space information from the storage device 200. For example, in the process described in the flowchart of Fig. 12a, during the free space confirmation process in step S3011, instead of obtaining free space information from the storage device 200, it is confirmed whether or not a notification indicating the occurrence of an event that satisfies a preset condition has been received from the storage device 200.

[0131] Next, an eleventh embodiment of the present invention will be described. In the series of embodiments described above, a path (communication path 300) for transmitting and receiving normal read and write commands and data that has been read or written is used as a path for transmitting and receiving requests (commands) and responses related to free space information of the storage device 200 between the information processing device 100 and the storage device 200, whereas the eleventh embodiment uses a communication path other than the communication path for transmitting and receiving normal commands such as Read and Write and associated data as a path for transmitting and receiving commands and responses related to free space information of the storage device 200 between the information processing device 100 and the storage device 200. This separate communication path is called a sideband.

[0132] Examples of this sideband include Universal Asynchronous Receiver Transmitter (UART), Inter-Integrated Circuit (I2C), and System Management Bus (SMBus). All of the methods described here require only a few signal lines, have relatively low operating frequencies, and have simple and standardized rules, making them suitable for sending and receiving commands and information related to free space information of the storage device 200.

[0133] As shown in Fig. 15, the information processing device 100 according to the eleventh embodiment includes a sideband interface 113 and a sideband interface device driver 114 in addition to the components of the above-mentioned embodiments, and is configured to connect to the storage device 200 via a sideband 301. In Fig. 15, the same components as those shown in Fig. 4 are denoted by the same reference numerals.

[0134] The sideband interface 113 connects to the sideband interface of the storage device 200 via a sideband 301 based on the communication protocol of the sideband to be used, i.e., the above-mentioned UART, I2C, or SMBus. The sideband interface device driver 114 performs processing based on the communication protocol of the sideband 301 via the sideband interface 113 based on a request to send a free space acquisition command from the storage device control unit 107.

[0135] 16, the storage device 200 according to the eleventh embodiment includes a sideband interface 214 in addition to the components of the above-mentioned embodiments, and is connected to the information processing device 100 via a sideband 301. In FIG. 15, the same components as those shown in FIG. 5 are denoted by the same reference numerals.

[0136] The sideband interface 214 transmits commands received from the information processing device 100 via the sideband 301 to the command control unit 202, and transmits responses received from the command control unit 202 to the information processing device 100 via the sideband 301. A method of acquiring free space information of the storage device 200 using this sideband 301 can be realized simply by changing the communication path for transmitting and receiving normal commands and the like in the first embodiment to the sideband 301, so the procedure described in the above embodiment can be applied almost as it is, and detailed description will be omitted here.

[0137] Next, a twelfth embodiment of the present invention will be described. In the first embodiment, the free space information that the information processing device 100 obtains from the storage device 200 is information indicating a data size that can guarantee the desired writing performance of the information processing device 100. In contrast, in the 12th embodiment, the information processing device 100 calculates the remaining recordable time from the free space information and the desired writing performance (bit rate) (specifically, this corresponds to steps S3002 and S3003 in FIG. 12a).

[0138] When the storage device 200 according to the twelfth embodiment receives a request to obtain free space information from the information processing device 100, it calculates the remaining recordable time from the free space held by the free space management unit 204 and the bit rate received from the information processing device 100, and returns the calculated remaining recordable time to the information processing device 100. The method of calculating the remaining recordable time by the storage device 200 may be the same as the method of calculating the remaining recordable time by the information processing device 100. For example, if the free space is 800 MB and the bit rate received from the information processing device 100 is 10 MB per second, the calculation can be made as follows: 800 MB÷10=80 seconds.

[0139] Furthermore, some types of information processing devices 100 manage the remaining number of recordable frames instead of the remaining recordable time. In that case, the storage device 200 similarly calculates the remaining number of recordable frames from the bit rate received from the information processing device 100 and returns the calculated number to the information processing device 100. That is, in this embodiment, the free space information notified to the information processing device 100 from the storage device 200 may be any of information related to the remaining data size, the remaining recordable time, or the remaining number of recordable frames.

[0140] Next, a thirteenth embodiment of the present invention will be described. In the first embodiment, when the information processing device 100 requests free space information from the storage device 200, the information processing device 100 notifies the storage device 200 of its desired write performance (see FIG. 9 and its description). In contrast, in this embodiment, the information processing device 100 does not notify the storage device 200 of its desired write performance, but responds to a free space information request from the information processing device 100 by sending a set of one or more write performances and free space information that can guarantee the write performance.

[0141] As shown in Fig. 17, this embodiment is composed of a write performance 1701 and free space information 1702 corresponding to each write performance. Fig. 17 shows an example of free space information returned by the storage device 200 in response to a free space information request from the information processing device 100. In Fig. 17, the unit of the write performance 1701 is written as MB / sec, and the unit of the free space information 1702 is written as MB, but these units may be different from those in the example of Fig. 17.

[0142] In response to a free space information request from the information processing device 100, the storage device 200 calculates the free space capable of guaranteeing each write performance of the write performance 1701 and the corresponding free space information 1702, and returns it to the information processing device 100 as free space information in the form of a table as shown in Fig. 17. The information processing device 100 that has received the free space information in the form of Fig. 17 compares the desired write performance that the information processing device 100 wishes to guarantee with the write performance 1701 in Fig. 17, selects a value that can realize the guarantee of the desired write performance, and extracts the corresponding free space information 1702. do.

[0143] For example, when the information processing device 100 that desires to guarantee a write performance of 150MB / sec receives the free space information of FIG. 17, it first searches for an element with the smallest write performance that exceeds 150MB / sec, and finds an element that is described as 200MB / sec. Next, it extracts 5000MB as free space information that corresponds to a write performance of 200MB / sec. From the above, the information processing device 100 acquires 5000MB as free space information that allows the storage device 200 that returned the free space information of FIG. 17 to guarantee a write performance of 150MB / sec. The method of using the acquired free space information by the information processing device 100 is similar to the contents described in the other embodiments, and therefore a detailed description will be omitted.

[0144] As described above, even in an embodiment in which the information processing device 100, when acquiring free space information of the storage device 200, responds with a set of several write performances and free space information that can guarantee those write performances, instead of presenting the desired write performance of the information processing device 100 itself, it is possible to realize a write performance guarantee when the information processing device 100 writes data to the storage device 200.

[0145] The storage device 200 according to the first to thirteenth embodiments is provided with a free space management unit that calculates the free space of a non-volatile storage medium and holds the calculated free space, and is connected to an information processing device 100 (a specified external device) and has a function of notifying the information processing device 100 of the information on the free space held in the free space management unit. Therefore, the information on the free space held by the storage device 200 can be matched with the information on the free space held by the information processing device 100, thereby ensuring the write performance desired by the information processing device 100.

[0146] Furthermore, the storage device 200 acquires information regarding the write performance required by the information processing device 100 (external device), and the free space information notified to the information processing device 100 (external device) is free space information that can determine whether or not the write performance required by the information processing device 100 can be realized. In particular, the free space information notified to the information processing device 100 (external device) is the write performance and free space information that can realize the write performance. Furthermore, the free space information is indicated by a unit size that is the size of data that can be written to the non-volatile storage medium and the size of data that is preset between the information processing device 100 (external device).

[0147] The unit size may be changeable, may be arbitrarily selectable from a plurality of values, and may be the block size of a NAND flash memory. The free space information may be notified to the information processing device 100 (external device) in response to a free space notification request from the information processing device 100 (external device). The free space information notified to the information processing device 100 (external device) is based on the free space of the non-volatile storage medium at the time when the free space notification request from the information processing device 100 (external device) is received.

[0148] In addition, the request for free space notification includes information on the free space required to write the data requested (generated by the information processing device 100) by the information processing device 100 (external device), and the free space included in the request for free space notification can be compared with the free space held in the free space management unit at the time the request for free space notification was received, and information determining whether the two compared free spaces are equal or not can be notified as free space information.

[0149] In addition, the request for free space notification includes information on the free space required to write the data requested by the information processing device 100 (external device) (generated by the information processing device 100), and the free space included in the request for free space notification can be compared with the free space held in the free space management unit at the time the request for free space notification was received, and information on whether the free space included in the request for free space notification is larger or not can be notified as free space information.

[0150] Furthermore, the request for free space notification includes information on the free space required to write the data requested by the information processing device 100 (external device) (generated by the information processing device 100), and the free space included in the request for free space notification can be compared with the free space held in the free space management unit at the time the request for free space notification was received, and information on whether the free space included in the request for free space notification is smaller can be notified as free space information.

[0151] Therefore, a request for free space notification from the information processing device 100 (external device) and notification of free space information to the information processing device 100 (external device) can use a command for a dedicated purpose, or can be included in a command for another purpose. Furthermore, notification of free space information to the information processing device 100 (external device) may be performed when a preset condition is satisfied, regardless of the presence or absence of a request for free space notification.

[0152] In addition, a request for notification of available space from the information processing device 100 (external device) and notification of available space information to the information processing device 100 (external device) may use a communication path for transmitting and receiving target data for data read requests and data write requests, or may use a communication path other than the communication path for transmitting and receiving target data for data read requests and data write requests.

[0153] Furthermore, the information processing device 100 (external device) may be able to transition between a write performance guaranteed state in which it is guaranteed that data writing corresponding to the desired write performance is realized and a write performance non-guaranteed state in which it is not guaranteed that data writing corresponding to the desired write performance is realized, and the free space information may be notified to the information processing device 100 (external device) in the write performance guaranteed state. Thus, the free space information may indicate the time during which data writing satisfying the desired write performance of the information processing device 100 (external device) can be realized. [Industrial Applicability]

[0154] The present invention can also be applied to those having other functions added thereto, provided that the purpose is the same as that of the present invention. [Explanation of symbols]

[0155] 100 Information processing device 101 Sensors 102 Sensor control unit 103 User Interface 104 User interface control section 105 Data Buffer 106 Data Control Section 107 Storage device control unit 108 Free Space Management Department 109 Device Drivers 110 Interface 111 Data Bus 112 Control Bus 113 Sideband Interface 114 Sideband Interface Device Driver 200 Storage device 201 Host Interface 202 Command control section 203 Data Management Department 204 Free Space Management Department 205 Media Management Department 206 Device Control Section 207 Data Buffer 208 RAM 209 Media Interface 210 Data Bus 211 Control Bus 212 Media 213 Media Channels 214 Sideband Interface 251 Write performance not guaranteed 252 Write performance guaranteed state 253 Transition from write performance unguaranteed state to write performance guaranteed state 254 Transition from write performance guaranteed state to write performance not guaranteed state 300 Channel 301 Sideband 400 LBA space 1301 Table number (index) of free space unit size 1302 Free space unit size 1701 Write performance 1702 Information on available space that can guarantee write performance

Claims

1. A storage device comprising: a free space management unit that calculates the free space of a storage medium mounted thereon and stores the calculated free space; and a function that is connected to a specified external device and notifies the external device of information about the free space stored in the free space management unit.

2. A storage device as described in claim 1, characterized in that it obtains information regarding the writing performance required by the external device, and the information on free space notified to the external device is free space information that can determine whether the writing performance required by the external device can be realized.

3. 2. The storage device according to claim 1, wherein the information on the free space notified to the external device is information on a write performance and a free space that can realize the write performance.

4. 4. The storage device according to claim 2, wherein the free space information is a size of data that can be written to the external device so as to satisfy a desired write performance.

5. 5. The storage device according to claim 4, wherein the free space information is indicated in a unit size based on a data size previously set between the storage device and the external device.

6. 6. The storage device according to claim 5, wherein the unit size is changeable.

7. 7. The storage device according to claim 6, wherein the unit size is selectable from a plurality of values.

8. 6. The storage device according to claim 5, wherein the unit size is a block size of a NAND flash memory.

9. 4. The storage device according to claim 2, wherein the free space information is notified to the external device in response to a free space notification request from the external device.

10. 10. The storage device according to claim 9, wherein the free space information notified to the external device is information based on the free space of the storage medium at the time when a request for notification of the free space is received from the external device.

11. The storage device according to claim 9, characterized in that the request for notification of free space includes information on the free space required to write the data requested by the external device, and the free space included in the request for notification of free space is compared with the free space held in the free space management unit at the time the request for notification of free space is received, and determination information as to whether the two compared free spaces are equal is notified as the free space information.

12. The storage device according to claim 9, characterized in that the request for free space notification includes information on the free space required to write the data requested by the external device, and the free space included in the request for free space notification is compared with the free space held in the free space management unit at the time the request for free space notification was received, and determination information as to whether the free space included in the request for free space notification is larger is notified as the free space information.

13. The storage device according to claim 9, characterized in that the request for free space notification includes information on the free space required to write the data requested by the external device, and the free space included in the request for free space notification is compared with the free space held in the free space management unit at the time the request for free space notification was received, and determination information as to whether the free space included in the request for free space notification is smaller is notified as the free space information.

14. 10. The storage device according to claim 9, wherein a request for free space notification from said external device and notification of said free space information to said external device are made by using commands for a dedicated purpose.

15. 10. The storage device according to claim 9, wherein a request for notification of free space from said external device and a notification of said free space information to said external device are included in a command for another purpose.

16. 10. The storage device according to claim 9, wherein the notification of the free space information to the external device is performed when a preset condition is satisfied, regardless of whether or not a notification of the free space has been requested.

17. 10. The storage device according to claim 9, wherein a request for notification of free space from the external device and notification of the free space information to the external device are made using a communication path for transmitting and receiving target data for data read requests and data write requests.

18. The storage device according to claim 9, characterized in that the request for notification of the available space from the external device and the notification of the available space information to the external device are made using a communication path other than the communication path for transmitting and receiving target data for data read requests and data write requests.

19. A storage device as described in claim 2 or claim 3, characterized in that it is capable of transitioning between a write performance guaranteed state that guarantees that data writing corresponding to the write performance desired by the external device will be realized, and a write performance non-guaranteed state that does not guarantee that data writing corresponding to the write performance desired by the external device will be realized.

20. 20. The storage device according to claim 19, wherein the notification of the free space information to the external device is performed in the write performance guaranteed state.

21. 4. The storage device according to claim 2, wherein the free space information indicates a time during which data can be written to the external device in a manner that satisfies a desired write performance.

Citation Information

Patent Citations

  • Data recording method and device

    JP2005190331A

  • Recording device

    JP2016009280A