Maximize SMR drive capacity

Systems and methods for maximizing shingled magnetic recording (SMR) drive capacity are described. In one embodiment, the SMR drive may include a main store to store user-accessible data, a media cache and media scratchpad to store internal data temporarily for internal operations, and a storage controller to process read and write requests. In some cases, the main store comprises a shingled media partition and an unshingled media partition. The storage controller may designate one or more data tracks from the shingled media partition as temporary data track guard bands. In some embodiments, a track range is selected based at least in part on at least one of an amount of data in the media cache, a size of the new data in the media cache, and an association between the new data in the media cache and data currently stored within the selected track range.

SUMMARY

The disclosure herein includes methods and systems for maximizing shingled magnetic recording (SMR) drive capacity. In some embodiments, the present systems and methods may configure the shingled data tracks of a shingled media partition and enable the storage device to write to the shingled tracks using temporary, logical guard bands instead of assigning a physical address to a guard band between SMR bands and using slim tracks for each data track instead of using a fat track adjacent to each physical guard band.

A storage device for maximizing SMR drive capacity is described. In one embodiment, the storage device may include a main store to store user-accessible data, a media cache to temporarily store user data, a media scratchpad to store internal data temporarily for internal operations, and a storage controller to write data to data tracks on the shingled media partition of the main store. In some cases, the main store comprises a shingled media partition and an unshingled media partition. The storage controller may designate one or more data tracks from the shingled media partition as temporary guard bands. In some embodiments, the track range is selected based at least in part on at least one of an amount of data in the media cache, a size of the new data in the media cache, and an association between the new data in the media cache and data currently stored within the selected track range.

In one embodiment, the storage controller may identify new data on the media cache to transfer to the main store. In some cases, the storage controller identifies new data on the media cache to transfer to the main store upon detecting the media cache is within a predetermined range of its capacity or detecting a host of the storage device is idle. In some embodiments, the storage controller may select a track range from tracks n to n+m among z total tracks in the shingled media partition of the main store. In some cases, n includes a positive integer from 1 to z, m includes a non-negative integer from 0 to z−1, and z includes a positive integer greater than 1.

In one embodiment, the storage controller is configured to copy the identified new data in the media cache to a data buffer, copy data on tracks n to n+m−1 to the data buffer, and copy data on track n+m to the media cache. In some cases, the storage controller may stitch together the copy of the new data in the data buffer with the copy of the data from tracks n to n+m−1 in the data buffer and copy the stitched data in the data buffer to the media scratchpad. In some embodiments, the storage controller may copy the stitched data in the media scratchpad to tracks n to n+m−1, wherein upon writing the copy of the stitched data in the media scratchpad to tracks n to n+m−1, track n+m−1 overlaps both track n+m−2 and track n+m.

In one embodiment, the storage controller may designate track n+m as a temporary guard band. Upon writing the copy of the stitched data in the media scratchpad to tracks n to n+m−1, track n+m may be overlapped by both track n+m−1 and n+m+1 when track n+m is not track z. If track n+m is the last track in the shingled media partition, then track n+m is overlapped by track n+m−1 only. In some cases, the storage controller may determine whether a track g among tracks n to n+m−1 is designated as a guard band and determine whether the media cache includes a copy of data from track g. Upon determining track g is designated a guard band and the media cache includes a copy of data from track g, the storage controller may copy the data from track g in the media cache to the data buffer. In this case, the storage controller may copy the data on tracks n to n+m−1 other than track g to the data buffer. The storage controller may stitch together the copy of the data from track g in the data buffer with the copy of the new data in the data buffer and the copy of the data from tracks n to n+m−1 other than track g in the data buffer.

In one embodiment, the storage controller may determine whether track n+m contains valid data. Upon determining track n+m contains no valid data, the storage controller may bypass writing track n+m to the media cache. Upon determining track n+m contains valid data, the storage controller may determine whether the media cache includes a copy of the data on track n+m. In some embodiments, upon determining track n+m contains valid data and the media cache includes a copy of the data on track n+m, the storage controller may bypass writing the data of track n+m to the media cache. Upon determining track n+m contains data and the media cache does not include a copy of the data of track n+m, the storage controller may copy the data of track n+m to the media cache.

A method for maximizing SMR drive capacity is described. In one embodiment, the method may include identifying data assigned to be written to a main store of a storage device and writing data to data tracks on the shingled media partition of the main store. In some cases, the storage device includes a main store for user-accessible data, a media cache to temporarily store portions of the user-accessible data, and a media scratch pad to store internal data temporarily for operations internal to the storage device. The main store may include a shingled media partition and an unshingled media partition. The storage controller may designate one or more data tracks from the shingled media partition as temporary guard bands.

An apparatus for maximizing SMR drive capacity is also described. In one embodiment, the apparatus may include a processor, memory in electronic communication with the processor, and instructions stored in the memory, the instructions being executable by the processor to perform the steps of identifying data assigned to be written to a main store of a storage device and writing data to data tracks on the shingled media partition of the main store. In some cases, the storage device includes a main store for user-accessible data, a media cache to temporarily store portions of the user-accessible data, and a media scratch pad to store internal data temporarily for operations internal to the storage device. The main store may include a shingled media partition and an unshingled media partition. The storage controller may designate one or more data tracks from the shingled media partition as temporary guard bands.

DETAILED DESCRIPTION

The following relates generally to maximizing shingled magnetic recording (SMR) drive capacity. Shingled magnetic recording (SMR) is a magnetic storage data recording technology used in hard disk drives (HDDs) to increase storage density and overall per-drive storage capacity. Conventional hard disk drives record data by writing non-overlapping magnetic tracks parallel to each other. Shingled recording writes a subsequent track that overlap part of a previously written magnetic track, leaving the previous track thinner, but allowing for higher track density. Thus, the tracks partially overlap similar to roof shingles.

In some cases, the overlapping-tracks architecture may slow down the writing process since writing to one track overwrites adjacent tracks, and requires them to be rewritten as well. A device-managed SMR device conceals this complexity by managing the SMR and non-SMR regions of the storage drive via the firmware of the storage drive, presenting an interface like any other hard disk from point of view of the host operating system. On the other hand, SMR devices that are host-managed rely on the operating system to manage the SMR and non-SMR regions of the drive.

In some cases, an SMR drive may be divided into multiple bands. The bands may be physical allocations of the SMR drive. To the host, the user-accessible portion of the SMR drive may appear as a continuous block of storage based on logical block addressing (LBA), but these LBA logical allocations may be physically divided into bands, each band containing a certain number of tracks. Each SMR band includes a set of data tracks, a physically allocated guard band, and a fat track adjacent to the guard band. The guard band is a physical allocation on the drive that separates one band from another. The fat track is a data track that is not overlapped or shingled by any other data track. Thus, the fat track is a data track of typical non-SMR width. The slim tracks are data tracks that are overlapped or shingled by other data tracks. SMR bands are an important concept for SMR drives, but conventional SMR bands also induce some drawbacks. For example, the fat tracks and guard bands of a conventional SMR drive consume the SMR drive's capacity (e.g., 2% of drive capacity with 50 tracks/band). Also, the fat track, slim tracks, and guard band increase the complexity of servo track seeking and other track management functions.

In one embodiment of the present systems and methods, the fat tracks and guard bands are removed from the SMR drive. Removing the fat track and guard band maximizes the SMR drive capacity without trade-offs for performance. Since all of tracks are slim tracks and data tracks, drive capacity is not wasted due to fat tracks and guard bands. Moreover, in conventional SMR drives, the logically allocated space of the drive may be divided into zones. In some cases, the physical bands may be mismatched with the logical zones, resulting in wasted capacity. Removing the fat track and guard band results in the drive capacity not being wasted due to band size and zone size mismatches. Moreover, with these systems and methods, a write operation, or rewrite operation (RO), can start from any track and end at any track, resulting in rewrite operations being more efficient and faster since there is no need to read/write until the end of band when there is no band boundary. Thus, a rewrite operation can cross many of the traditional bands that would exist in a conventional SMR drive. Eliminating the physical SMR bands simplifies track management and data flow. Moreover, removing physical SMR bands reduces the complexity of servo track seeking and other track management functions, further improving device efficiency.

In some embodiments, a physical band may be inserted, for example, a physical guard band may be located around middle diameter (MD) of a hard disk to separate a shingle direction. In some embodiments, an empty data track may be identified and selected as a temporary guard band between a group of tracks. In some cases the present systems and methods may be combined with track usage management (TUM). In some cases, an empty track may be selected as the last track within a range of tracks that are used in a rewrite operation. If the last track contains valid data, the data of the last track may be stored in a media cache, as the rewrite operation of the present systems and methods may result in the last track of the range being overlapped or shingled by the second to last track in the selected range. Thus, in some cases, the last track of the range of tracks may be overlapped twice as a result of the rewrite operation. For example, “track N” may be a track within a group of tracks being recorded on in a first shingled write operation (e.g., a first rewrite operation, etc.), resulting in track N being shingled by a subsequent track, track O. Following this first shingled write operation, track N may be selected as the last track in a selected range of tracks for a second shingled write operation (e.g., a second rewrite operation, etc.). As a result of the second shingled write operation, track N may be shingled by a preceding track, track M. Thus, as a result of both write operations, track N, the last track in the selected range, may be shingled by both a subsequent track, track O, in a first shingled write operation, as well as a previous track, track M, in a second shingled write operation that occurs after the first shingled write operation. However, in the case where the last track is empty or does not contain valid data, then there is nothing valid to copy from the last track, and if there is nothing valid to copy then a read of the last track is bypassed, thus reducing the number of operations performed in the rewrite operation of the present systems and methods.

The guard bands of a conventional SMR drive are assigned to a physical band, a physically addressed portion of the shingled media partition of the SMR drive. The proposed guard bands are virtual and not tied to any physical space, but float from data track to data track. In one embodiment, the proposed temporary guard bands may be dynamically assigned by removing a mapping between a logical block address for a particular data track and designating the data track temporarily as a data track guard band. In some cases, the designation of the data track as a temporary guard band may be recorded in a table of temporary guard bands.

In some embodiments, a rewrite operation may be triggered when a media cache is full and/or reaches a predetermined percentage of its capacity. In some cases, a rewrite operation may be triggered when the storage drive host (e.g., operating system hosting the SMR drive) is idle. In some cases, the present systems and methods may enable an SMR drive without physical SMR bands. Thus, instead of writing to the end of an SMR band with each read/modify/write operation in a conventional SMR drive, any number of tracks from one to the maximum number of tracks may be selected for a rewrite operation. In some cases, a range of tracks may be selected to maximize clearing of the media cache. In some cases, a track may be selected for the track range because the media cache contains data associated with data in that track. For example, the data in media cache may include an update to the data on that track. In some cases, the present systems and methods may identify empty tracks and select empty tracks as the last track in the selected range of tracks in a rewrite operation to improve device performance.

FIG. 1is a block diagram illustrating one embodiment of an environment100in which the present systems and methods may be implemented. The environment may include device105and storage device110. The storage device110may include any combination of hard disk drives, solid state drives, and hybrid drives that include both hard disk and solid state drives. The storage device110may include a volatile cache (e.g., disk buffer, static random access memory (RAM), dynamic RAM, etc.), a main store, a media cache, and/or a media scratch pad. The volatile cache may hold data temporarily such as new data to be stored on the storage device110and/or data already stored at a first storage location of storage device110being transferred to a second storage location. The main store may include media on the storage device110accessible to a user. For example, a user that stores a file on storage device110may store the file in the main store of storage device110. On the other hand, the media cache and media scratch pad may include media on the storage device (e.g., the same media as the main store) that is inaccessible to the user. Instead the media cache and media scratch pad may be accessible to a host processor and memory and/or a storage controller of storage device110to perform internal operations and functions of the storage device110and/or host. In some embodiments, the systems and methods described herein may be performed on a single device (e.g., device105). In some cases, the methods described herein may be performed on multiple storage devices or a network of storage devices. Examples of device105include a storage server, a storage enclosure, a storage controller, storage drives in a distributed storage system, storage drives on a cloud storage system, storage devices on personal computing devices, storage devices on a server, etc. In some configurations, device105may include a shingled magnetic recording (SMR) module130. In one example, the device105may be coupled to storage device110. In some embodiments, device105and storage device110may be components of an SMR drive. Alternatively, device105may be a component of a host (e.g., operating system, host hardware system, etc.) of the storage device110.

In one embodiment, device105may be a computing device with one or more processors, memory, and/or one or more storage devices. In some cases, device105may include a wireless storage device. In some embodiments, device105may include a cloud drive for a home or office setting. In one embodiment, device105may include a network device such as a switch, router, access point, etc. In one example, device105may be operable to receive data streams, store and/or process data, and/or transmit data from, to, or in conjunction with one or more local and/or remote computing devices.

The device105may include a database. In some cases, the database may be internal to device105. For example, storage device110may include a database. Additionally, or alternatively, the database may include a connection to a wired and/or a wireless database. Additionally, as described in further detail herein, software and/or firmware (e.g., stored in memory) may be executed on a processor of device105. Such software and/or firmware executed on the processor may be operable to cause the device105to monitor, process, summarize, present, and/or send a signal associated with the operations described herein.

In some embodiments, storage device110may connect to device105via one or more networks. Examples of networks include cloud networks, local area networks (LAN), wide area networks (WAN), virtual private networks (VPN), a personal area network, near-field communication (NFC), a telecommunications network, wireless networks (using 802.11, for example), and/or cellular networks (using 3G and/or LTE, for example), etc. In some configurations, the network may include the Internet and/or an intranet. The device105may receive and/or send signals over a network via a wireless communication link. In some embodiments, a user may access the functions of device105via a local computing device, remote computing device, and/or network device. For example, in some embodiments, device105may include an application that interfaces with a user. In some cases, device105may include an application that interfaces with one or more functions of a network device, remote computing device, and/or local computing device.

In one embodiment, the storage device110may be internal to device105. As one example, device105may include a storage controller that interfaces with storage media of storage device110. Storage device110may include a hard disk drive (HDD) with an SMR region. SMR module130may maximize SMR drive capacity of storage device110by storing data in the SMR region of storage device110without conventional, physically allocated guard bands or the fat tracks that are adjacent to each guard band in a conventional SMR drive. In some cases SMR module130may use one or more data tracks as temporary, floating guard bands within the SMR region of storage device110. Thus, instead of assigning a physical area or space of a shingled media partition in storage device110, SMR module130may select a data track within the shingled media partition as a temporary data track guard band. When new data is received at storage device110, SMR module130may combine data already written to one or more data tracks of the shingled media partition with the new data and rewrite this combination to a set or range of tracks. In writing this combined data to the second to last track in this range of tracks, the SMR module130may write over a portion (e.g., a leading-in portion) of the last data track in the range of tracks. Another portion (e.g., a leading-out portion) of this last data track may have already been written over from a previous write operation. Thus, the last track may be designated as a temporary data track guard band, and if it contained data this data may be stored temporarily in media cache. During a subsequent rewrite operation, the last track may be converted back to a regular data track where another data track may be selected as a temporary data track guard band. Thus, a temporary guard band may revert to a data track with valid data written to its track. As part of writing this combined data to the shingled media partition, the SMR module130may select a different data track as a new temporary guard band. Thus, the temporary guard bands may float from data track to data track. Thus, each time the SMR module130performs a rewrite operation, a current temporary guard band may revert to a data track and a current data track may be converted to be a temporary guard band.

FIG. 2shows a block diagram200of an apparatus205for use in electronic communication, in accordance with various aspects of this disclosure. The apparatus205may be an example of one or more aspects of device105described with reference toFIG. 1. The apparatus205may include a drive controller210, drive buffer215, host interface logic220, drive media225, and SMR module130-a. Each of these components may be in communication with each other and/or other components directly and/or indirectly.

In one embodiment, the drive controller210may include a processor230, a buffer manager235, and a media controller240. The drive controller210may process, via processor230, read and write requests in conjunction with the host interface logic220, the interface between the apparatus205and the host of apparatus205(e.g., an operating system, host hardware system, etc.). The driver buffer215may hold data temporarily for internal operations of apparatus205. For example, a host may send data to apparatus205with a request to store the data on the drive media225. The driver controller210may process the request and store the received data in the drive media225. In some cases, a portion of data stored in the drive media225may be copied to the drive buffer215and the processor230may process or modify this copy of data and/or perform an operation in relation to this copy of data held temporarily in the drive buffer215.

In one embodiment, the drive media225may include a media cache245, a media scratch pad250and a main store255. The main store255may include a shingled media partition260and an unshingled media partition265. In one embodiment, the media cache245, media scratch pad250, and main store255may be different partitions of a hard disk drive. For example, the media cache245partition may start at the beginning of the physical disk (e.g., physical LBA0). The media scratch pad may start where the media cache ends. Next, the main store may start where the media scratch pad ends. The start of the main store may coincide with the beginning of storage available to the host of the apparatus205(e.g., Host LBA0). Thus, the main store may represent the capacity of drive media225reported to the host (e.g., Host LBA0to Host LBA Maximum). In one embodiment, the unshingled media partition may start at host LBA0and the shingled media partition may start where the unshingled media partition ends and end at Host LBA Maximum. In some embodiments, a track includes multiple LBAs (e.g., 300 LBAs per track, etc.). In some cases, both the main store255and the media cache245may be allocated Host LBAs.

Although depicted outside of drive controller210, in some embodiments, SMR module130-amay include software, firmware, and/or hardware located within drive controller210. For example, SMR module130-amay include at least a portions of processor230, buffer manager235, and/or media controller240. In one example, SMR module130-amay include one or more instructions executed by processor230, buffer manager235, and/or media controller240. The SMR module130-amay be configured to maximize an SMR drive capacity by removing conventional physical guard bands and the fat tracks next to each physical guard band, and using data tracks as temporary data track guard bands that float from data track to data track as needed.

FIG. 3shows a block diagram300of an SMR module130-b. The SMR module130-bmay include one or more processors, memory, and/or one or more storage devices. The SMR module130-bmay include identification module305, data module310, and track selection module315. The SMR module130-bmay be one example of SMR module130ofFIGS. 1 and/or 2. Each of these components may be in communication with each other.

In one embodiment, identification module305may identify data assigned to be written to a storage device. In some embodiments, data module310may operate in conjunction with a media cache, media scratchpad, and/or main store of a storage device (e.g., storage device110ofFIG. 1and/or apparatus205ofFIG. 2). In one example, the main store may include a shingled media partition and an unshingled media partition (e.g., shingled and unshingled media partitions260and265, respectively, ofFIG. 2). The main store may include shingled media and unshingled media that are both available to store user-accessible data. The media cache and/or media scratchpad may include portions of the device media that are used to store data temporarily for internal operations. In some cases, data module310may write data to data tracks on the shingled media partition of the main store. The track selection module315may designate one or more data tracks from the shingled media partition as temporary, floating guard bands. Thus, instead of assigning a physical area or physically allocated track of a hard disk drive as a guard band between tracks within a zone of tracks and/or tracks from different zones as is done in conventional SMR drives, data module310may assign one or more data tracks as temporary guard bands.

In one embodiment, identification module305may identify new data on the media cache to transfer to the main store. In some cases, the identification module305may identify new data on the media cache to transfer to the main store upon detecting the media cache is within a predetermined range of its storage capacity and/or detecting a host of the storage device is idle. For example, when the storage cache is within a certain percentage of being filled to capacity, track selection module315may assign data from the storage cache to one or more tracks of the storage device and data module310may write the data to the assigned tracks. Likewise, when identification module305detects that a host is idle (e.g., an operating system and/or host processor/memory associated with the storage device is idle), track selection module315may assign data from the storage cache to one or more tracks of the storage device and data module310may write the data to the assigned tracks.

In one embodiment, track selection module315may select a track range from tracks n to n+m among z total tracks in a shingled media partition of the main store. The value “n” may include a positive integer from 1 to z, the value “m” may include a non-negative integer from 0 to z−1, and the value “z” may include a positive integer greater than 1 limited by the number of tracks available on the storage media. Thus, if n=8 is selected by track selection module315as a starting track and m=12 is selected by track selection module315as a range, then tracks 8 through 20 are selected by track selection module315. As another example, if z=30,000 and track selection module315selects all the tracks, then track selection module315selects n=1 as the starting track (i.e., the first available track), and selects m=29,999 as the range, thus selecting all the available tracks. In some cases, the track selection module315may select a track range based at least in part on a size of the new data in the media cache to be written to a track and/or an association between the new data in the media cache and data already written to the selected track range.

In one embodiment, data module310may copy the identified new data in the media cache to a data buffer, data on tracks n to n+m−1 to the data buffer, and data on track n+m to the media cache. Thus, if n=5 and m=20, then the data contained in tracks 5-19 may be written to the data buffer along with the new data in media cache, and valid data in track 20 may be written to the media cache. In some cases, data module310may stitch together the copy of the new data in the data buffer with the copy of the data from tracks n to n+m−1 copied to the data buffer. Thus, the data from tracks n to n+m−1 may be modified to include the new data. Data module310may copy this stitched or combined data in the data buffer to the media scratchpad. The media scratchpad may store the stitched data temporarily. In some embodiments, data module310may copy the stitched data in the media scratchpad to tracks n to n+m−1. Upon writing the copy of the stitched data in the media scratchpad to tracks n to n+m−1, track n+m−1 may overlap both track n+m−2 and track n+m. Thus, if n=5 and m=20, track 24 may overlap both track 23 and track 25 after the portion of the stitched data is written to track 24. Because data module310writes any valid data on track 25 to the media cache as part of combining the new data with the existing data between tracks n and n+m−1, overwriting track 25 does not result in the data from track 25 being lost.

In some embodiments, track selection module315may designate track n+m as a temporary guard band. Using the example of n=5 and m=20, track selection module315may designate track 25 as a temporary guard band. Upon writing the copy of the stitched data in the media scratchpad to tracks n to n+m−1, track n+m may be overlapped by both track n+m−1 and n+m+1 when track n+m is not track z. Thus, if n=5, m=20, and z=30,000 and the stitched data is written to tracks n to n+m−1, then track 25 may be overlapped by both track 24 and track 26 as long as track n+m is not the last available track. If track n+m is the last available track, then track n+m is only overlapped by track n+m−1 after writing the stitched data to tracks n to n+m−1. With the example where n=5 and m=20, it is noted that at least a portion of these tracks may be empty. For example, a storage device may receive an update to a file stored within tracks 5-20, the original file may using tracks 5-20. After receiving the update, the track selection module315may determine that at least four additional tracks are needed to update the existing file with the update, then track selection module315may select tracks 5-25 to merge the update with the existing file, track 25 being used as a temporary guard band. In some cases, the identification module305may determine whether a track within a selected track range is empty (e.g., contains no data, contains invalid data, etc.). Upon the identification module305identifying a data track within the selected track range as empty, the data module310may bypass performing a read operation on the empty data track.

In some cases, a prior writing operation may designate a certain track “g” as a temporary guard band. Subsequent to this designation, track selection module315may select a track range that includes the track g within the range of tracks. Thus, in one embodiment, identification module305may determine whether a track g among tracks n to n+m−1 is designated as a guard band. For example, in a first write operation where n=5 and m=10, track n+m, or track 15, is designated as a temporary guard band. Assuming track 15 contains valid data, the data module310writes the data from track 15 to media cache. In a second write operation n=5 and m=15. Thus, in the second write operation track n+m, or track 20, is designated as a temporary guard band, and track 15 (i.e., track “g”=track 15), the temporary guard band in the first write operation, is written back to track 15 in the second write operation based on the data from track 15 in the media cache, since track 15 would have been overwritten as part of the first writing operation. Upon determining track g is designated a guard band from a prior write operation and the media cache includes a copy of data from track g, data module310may copy the data from track g in the media cache to the data buffer, as track g would have been overwritten by track g−1 in the prior writing operation. Accordingly, data module310may copy all valid data from tracks n to n+m−1, except track g, to the data buffer. Data module310may stitch together the copy of the data from track g copied from the media cache to the data buffer with the copy of the new data in the data buffer and the copy of the data from tracks n to n+m−1 other than track g copied from their respective track to the data buffer. Thus, data module310merges this data with the data from the other tracks and the new data, and writes this data to tracks n to n+m−1 in the second write operation. Accordingly, during each write operation, the identification module305may determine whether the media cache includes a copy of the data for one or more tracks within the selected track range.

As described in the embodiments above, data from tracks n to n+m−1 may be copied to a drive buffer and combined with a copy of new data in the data buffer. This combination of data may be written to data tracks n to n+m−1. Track n+m is overlapped or shingled as data is written to track n+m−1. Thus, data module310stores a copy of data from track n+m in the media cache and track n+m is designated as a temporary guard band. The data from track n+m remains in the media cache until this data is written once more to track n+m in a subsequent write operation. But if track n+m does not contain data, then there is no need to store a backup track n+m in media cache. Thus, in some embodiments, identification module305may determine whether track n+m contains valid data. Upon determining track n+m contains no valid data, data module310may bypass writing track n+m to the media cache. On the other hand, upon determining track n+m contains valid data, data module310may write a copy of this valid data to media cache. In some embodiments, the data from track n+m may already be written to media cache. Upon determining track n+m contains valid data and the media cache includes a copy of the data on track n+m, data module310may bypass writing the data of track n+m to the media cache. On the other hand, upon determining track n+m contains data and the media cache does not include a copy of the data of track n+m, data module310may copy the data of track n+m to the media cache.

FIG. 4shows a system400for maximizing SMR drive capacity, in accordance with various examples. System400may include an apparatus445, which may be an example of any one of device105ofFIG. 1and/or apparatus205ofFIG. 2.

Apparatus445may include components for bi-directional voice and data communications including components for transmitting communications and components for receiving communications. For example, apparatus445may communicate bi-directionally with one or more storage devices and/or client systems. This bi-directional communication may be direct (e.g., apparatus445communicating directly with a storage system) and/or indirect (e.g., apparatus445communicating indirectly with a client device through a server).

Apparatus445may also include a processor module405, and memory410(including software/firmware code (SW)415), an input/output controller module420, a user interface module425, a network adapter430, and a storage adapter435. The software/firmware code415may be one example of a software application executing on apparatus445. The network adapter430may communicate bi-directionally—via one or more wired links and/or wireless links—with one or more networks and/or client devices. In some embodiments, network adapter430may provide a direct connection to a client device via a direct network link to the Internet via a POP (point of presence). In some embodiments, network adapter430of apparatus445may provide a connection using wireless techniques, including digital cellular telephone connection, Cellular Digital Packet Data (CDPD) connection, digital satellite data connection, and/or another connection. The apparatus445may include an SMR module130-b, which may perform the functions described above for the SMR modules130ofFIGS. 1, and/or2.

The signals associated with system400may include wireless communication signals such as radio frequency, electromagnetics, local area network (LAN), wide area network (WAN), virtual private network (VPN), wireless network (using 802.11, for example), cellular network (using 3G and/or LTE, for example), and/or other signals. The network adapter430may enable one or more of WWAN (GSM, CDMA, and WCDMA), WLAN (including BLUETOOTH® and Wi-Fi), WMAN (WiMAX) for mobile communications, antennas for Wireless Personal Area Network (WPAN) applications (including RFID and UWB), etc.

One or more buses440may allow data communication between one or more elements of apparatus445(e.g., processor module405, memory410, I/O controller module420, user interface module425, network adapter430, and storage adapter435, etc.).

The memory410may include random access memory (RAM), read only memory (ROM), flash RAM, and/or other types. The memory410may store computer-readable, computer-executable software/firmware code415including instructions that, when executed, cause the processor module405to perform various functions described in this disclosure. Alternatively, the software/firmware code415may not be directly executable by the processor module405but may cause a computer (e.g., when compiled and executed) to perform functions described herein. Alternatively, the computer-readable, computer-executable software/firmware code415may not be directly executable by the processor module405, but may be configured to cause a computer (e.g., when compiled and executed) to perform functions described herein. The processor module405may include an intelligent hardware device, e.g., a central processing unit (CPU), a microcontroller, an application-specific integrated circuit (ASIC), etc.

In some embodiments, the memory410may contain, among other things, the Basic Input-Output system (BIOS) which may control basic hardware and/or software operation such as the interaction with peripheral components or devices. For example, at least a portion of the SMR module130-bto implement the present systems and methods may be stored within the system memory410. Applications resident with system400are generally stored on and accessed via a non-transitory computer readable medium, such as a hard disk drive or other storage medium. Additionally, applications can be in the form of electronic signals modulated in accordance with the application and data communication technology when accessed via a network interface (e.g., network adapter430, etc.).

Many other devices and/or subsystems may be connected to one or may be included as one or more elements of system400(e.g., personal computing device, mobile computing device, smart phone, server, internet-connected device, cell radio module, and so on). In some embodiments, all of the elements shown inFIG. 4need not be present to practice the present systems and methods. The devices and subsystems can be interconnected in different ways from that shown inFIG. 4. In some embodiments, an aspect of some operation of a system, such as that shown inFIG. 4, may be readily known in the art and are not discussed in detail in this application. Code to implement the present disclosure can be stored in a non-transitory computer-readable medium such as one or more of system memory410or other memory. The operating system provided on I/O controller module420may be a mobile device operation system, a desktop/laptop operating system, or another known operating system.

The I/O controller module420may operate in conjunction with network adapter430and/or storage adapter435. The network adapter430may enable apparatus445with the ability to communicate with client devices (e.g., device105ofFIG. 1), and/or other devices such as the apparatus205ofFIG. 2. Network adapter430may provide wired and/or wireless network connections. In some cases, network adapter430may include an Ethernet adapter or Fibre Channel adapter. Storage adapter435may enable apparatus445to access one or more data storage devices (e.g., storage device110). The one or more data storage devices may include two or more data tiers each. The storage adapter may include one or more of an Ethernet adapter, a Fibre Channel adapter, Fibre Channel Protocol (FCP) adapter, a SCSI adapter, and iSCSI protocol adapter.

As depicted, environment500depicts one embodiment of data tracks from a shingled media partition (e.g., shingled media partition260ofFIG. 2), where track n+1 is shingled over track n, track n+2 over track n+1, and so forth. In one embodiment, the environment500depicts one embodiment of a proposed track layout of an SMR drive. As depicted, tracks n through n+14 are data tracks without a guard band and fat track that precedes each guard band in a conventional SMR drive.

Although environment500depicts15shingled tracks, from track n to track n+14. In one embodiment, tracks n to n+14 represent a portion of a total number of tracks on a shingled media partition. In some embodiments, tracks n to n+14 represent the total number of tracks of a shingled media partition. For example, a shingled media partition may include 50,000 tracks. Thus, in some embodiments, tracks n to n+14 are a representation of the total number of tracks in a shingled media partition, whether the total number of tracks numbers in the tens, hundreds, or thousands, etc.

In one embodiment, environment500may depict one example of a new, formatted, or trimmed SMR drive prior to any data being written to the tracks. Alternatively, environment500may depict an SMR drive with all of the tracks containing data, where tracks n to n+14 represent a total set of tracks in a shingled media partition. In some embodiments, tracks n to n+14 may represent shingled tracks from a portion of the total number of tracks in a shingled media partition. Thus, tracks n to n+14 may represent data written to all the tracks of this portion of the total number of tracks in the shingled media partition.

The value “n” from environment500(e.g., track “n”) may be any non-negative integer from 0 to a value representing a final track within a shingled media partition. For example, if there are 256 tracks in a shingled media partition, then “n” may be any value between 0 and 255. It is noted that if “n” were set to 255, then the depicted tracks following track n would not exist, as track n would be the last track. Thus, if ten tracks are selected among 256 total tracks, then “n” would be any value between 0 and 246. If “n” were 246 and ten tracks were selected, then track n to track n+9 would be selected, where n=246 would be the first track of the ten selected tracks and n+9=255 would be the final track selected of the ten selected tracks, as well as the final track among the 256 total tracks.

FIG. 6shows an environment600for maximizing SMR drive capacity, in accordance with various examples. Environment600may be one example of environment500ofFIG. 5. At least one aspect of environment600may be implemented in conjunction with device105ofFIG. 1, apparatus205ofFIG. 2, and/or SMR module130depicted inFIGS. 1, 2, 3, and/or4.

As depicted, environment600depicts one embodiment of data tracks from a shingled media partition (e.g., shingled media partition260ofFIG. 2). In one embodiment, the environment600depicts one embodiment of a proposed track layout of an SMR drive. As depicted, tracks n through n+14 are data tracks without guard bands and the fat tracks that precede each guard band in a conventional SMR drive.

In one embodiment, environment600depicts the results of a first rewrite operation (RO) in accordance with the systems and methods described herein. According to these systems and methods, a track range for the first rewrite operation is selected. For example, a head track “n” may be selected among available tracks along with a range “m,” giving a range from track n to track n+m. In some embodiments, the track head (“n”) and track range (“m”) may be selected to maximize clearing the media cache, where at least a portion of the data temporarily stored on the media cache is removed and/or marked as invalid to allow different data to be written where the invalidated data is written.

Data from tracks n to n+m may be read, with data from tracks n to n+m−1 being read into a data buffer and data from track n+m being written to media cache. If the media cache already includes the data from track n+m or track n+m is empty (i.e., no valid data on track n+m), then track n+m is not read. If the data from one or more tracks between track n and n+m−1 is already written to the media cache, then the data from these one or more tracks is not read from the track. In some cases, the copies of the data from these one or more tracks may be copied from media cache to the data buffer. In some cases, the data from the one or more tracks in media cache is copied from the media cache and written to the media scratch pad and/or copied back to their respective tracks from media cache.

In some embodiments, new data associated with the data on tracks n to n+m is also written to the data buffer. In one embodiment, the data from tracks n to n+m−1 is modified (i.e., stitched together) with the new data and this modified data is written to the media scratch pad. The stitched data is then written from the media scratch pad to the tracks n to n+m−1 on the main store.

As one example, depicted in environment600, a track range may be selected for a first rewrite operation, where track n is selected as the head track and track n+8 (i.e., m=8) is selected as the last track in the selected track range. Data from tracks n to n+7 (i.e., track n+m−1) may be read and copied to a data buffer. New data associated with at least one of the tracks n to n+8 and/or the data on at least one of the tracks n to n+8 may be read from media cache to the data buffer. The data from track n+8 may be copied into media cache if track n+8 contains valid data and the data in track n+8 is not already written to media cache. The new data is stitched with the data from tracks n to n+7. The stitched data is written to the media scratchpad to protect this data in case of device failure and/or power loss, etc. The stitched data in the media scratchpad is copied to the tracks n to n+7. During the first rewrite operation, a portion of the stitched data is written to track n+7, resulting in track n+8 being overlapped by track n+7. Thus, as depicted inFIG. 6, both tracks n+7 and n+9 overlap track n+8 (i.e., the cross-hatched track) following the first rewrite operation, track n+9 having overlapped track n+8 in a previous write operation and track n+7 overlapping track n+8 during the first rewrite operation. In one embodiment, if a request is received that includes a request for the data from tracks n to n+8, the data on tracks n to n+7 are read and the data from track n+8 in media cache is read and these two sets of data are provided together in reply to the request. Track n+8 is designated as a temporary guard band.

As depicted, environment700includes data tracks from a shingled media partition (e.g., shingled media partition260ofFIG. 2). Environment700may depict one example of proposed track layout of an SMR drive. As depicted, tracks n through n+14 are data tracks without guard bands and the fat tracks that precede each guard band in a conventional SMR drive.

In one embodiment, environment700depicts the results of a second rewrite operation subsequent to the first rewrite operation depicted ofFIG. 6. New data is written to the media cache. Based on this new data (i.e., size of the new data, association of the new data to the track data, etc.), a track range is selected from track n+5 to track n+11. The present systems and methods may determine whether data from tracks n+5 to track n+11 is written to media cache. Since data from track n+8 was previously written to the media cache in the first rewrite operation, the present systems and methods copies data from tracks n+5, n+6, n+7, n+8, n+9, and n+10 to the data buffer. The data from track n+8 is copied from media cache to the data buffer. The present systems and methods then determine whether track n+11, the last track in the track range, contains valid data. If track n+11 is empty, no more is reads are performed in relation to the track data. If track n+11 does contain valid data and this data is already in media cache, again no more reads are performed for the track data. If track n+11 contains valid data and the data is not already in media cache, the present systems and methods copies the data from track n+11 to media cache.

In one embodiment, the new data in the data buffer is stitched with the data from tracks n+5 to n+10 in the data buffer. The stitched data is written to the media scratchpad and then copied from the media scratchpad from track n+5 to track n+10. During the second rewrite operation, a portion of this stitched data is written to track n+10, resulting in track n+11 being overlapped by track n+10. Thus, as depicted inFIG. 7, both tracks n+10 and n+12 overlap track n+11 (i.e., the cross-hatched track) following the second rewrite operation, track n+12 having overlapped track n+11 in a previous write operation and track n+10 overlapping track n+11 during the second rewrite operation. As depicted, data belonging to track n+8 is written to track n+8 during the second rewrite operation. Thus, as part of the second rewrite operation, track n+8, the previous temporary guard band from the first rewrite operation, is converted back to a regular data track just as it was before the first rewrite operation, and track n+11 is designated as a temporary guard band.

FIG. 8is a flow chart illustrating an example of a method800for maximizing SMR drive capacity, in accordance with various aspects of the present disclosure. One or more aspects of the method800may be implemented in conjunction with device105ofFIG. 1, apparatus205ofFIG. 2, and/or SMR module130depicted inFIGS. 1, 2, 3, and/or4. In some examples, a backend server, computing device, and/or storage device may execute one or more sets of codes to control the functional elements of the backend server, computing device, and/or storage device to perform one or more of the functions described below. Additionally or alternatively, the backend server, computing device, and/or storage device may perform one or more of the functions described below using special-purpose hardware.

At block805, the method800may include identifying data assigned to be written to a shingled media partition of a storage device. At block810, the method800may include writing data to a set of data tracks on the shingled media partition of the main store. At block815, the method800may include designating a data track from the set of data tracks as a temporary guard band. The operation(s) at block805-815may be performed using the SMR module130described with reference toFIGS. 1-4and/or another module.

Thus, the method800may provide for maximizing SMR drive capacity relating to maximizing SMR drive capacity. It should be noted that the method800is just one implementation and that the operations of the method800may be rearranged, omitted, and/or otherwise modified such that other implementations are possible and contemplated.

FIG. 9is a flow chart illustrating an example of a method900for maximizing SMR drive capacity, in accordance with various aspects of the present disclosure. One or more aspects of the method900may be implemented in conjunction with device105ofFIG. 1, apparatus205ofFIG. 2, and/or SMR module130depicted inFIGS. 1, 2, 3, and/or4. In some examples, a backend server, computing device, and/or storage device may execute one or more sets of codes to control the functional elements of the backend server, computing device, and/or storage device to perform one or more of the functions described below. Additionally or alternatively, the backend server, computing device, and/or storage device may perform one or more of the functions described below using special-purpose hardware.

At block905, the method900may include copying new data from a media cache of a storage device to a data buffer of the storage device. At block910, the method900may include selecting a range of tracks in a shingled media partition of the storage device based on an aspect of the new data. At block915, the method900may include copying data from all the tracks except the last track in the range of tracks to the data buffer. At block920, the method900may include copying data from the last track in the range of tracks to the media cache. At block925, the method900may include stitching together the track data in the data buffer (i.e., the copy of the data from all the tracks except the last track in the range of tracks) with the copy of new data in the data buffer. At block930, the method900may include copying the stitched data back to all the tracks except the last track in the range of tracks. At block935, the method900may include designating the last track as a temporary guard band. The operations at blocks905-935may be performed using the SMR module130described with reference toFIGS. 1-4and/or another module.

Thus, the method900may provide for maximizing SMR drive capacity relating to maximizing SMR drive capacity. It should be noted that the method900is just one implementation and that the operations of the method900may be rearranged, omitted, and/or otherwise modified such that other implementations are possible and contemplated.

In some examples, aspects from two or more of the methods800and900may be combined and/or separated. It should be noted that the methods800and900are just example implementations, and that the operations of the methods800and900may be rearranged or otherwise modified such that other implementations are possible.

The various illustrative blocks and components described in connection with this disclosure may be implemented or performed with a general-purpose processor, a digital signal processor (DSP), an ASIC, an FPGA or other programmable logic device, discrete gate or transistor logic, discrete hardware components, or any combination thereof designed to perform the functions described herein. A general-purpose processor may be a microprocessor, but in the alternative, the processor may be any conventional processor, controller, microcontroller, and/or state machine. A processor may also be implemented as a combination of computing devices, e.g., a combination of a DSP and a microprocessor, multiple microprocessors, one or more microprocessors in conjunction with a DSP core, and/or any other such configuration.

In addition, any disclosure of components contained within other components or separate from other components should be considered exemplary because multiple other architectures may potentially be implemented to achieve the same functionality, including incorporating all, most, and/or some elements as part of one or more unitary structures and/or separate structures.

This disclosure may specifically apply to security system applications. This disclosure may specifically apply to storage system applications. In some embodiments, the concepts, the technical descriptions, the features, the methods, the ideas, and/or the descriptions may specifically apply to storage and/or data security system applications. Distinct advantages of such systems for these specific applications are apparent from this disclosure.

The process parameters, actions, and steps described and/or illustrated in this disclosure are given by way of example only and can be varied as desired. For example, while the steps illustrated and/or described may be shown or discussed in a particular order, these steps do not necessarily need to be performed in the order illustrated or discussed. The various exemplary methods described and/or illustrated here may also omit one or more of the steps described or illustrated here or include additional steps in addition to those disclosed.

Furthermore, while various embodiments have been described and/or illustrated here in the context of fully functional computing systems, one or more of these exemplary embodiments may be distributed as a program product in a variety of forms, regardless of the particular type of computer-readable media used to actually carry out the distribution. The embodiments disclosed herein may also be implemented using software modules that perform certain tasks. These software modules may include script, batch, or other executable files that may be stored on a computer-readable storage medium or in a computing system. In some embodiments, these software modules may permit and/or instruct a computing system to perform one or more of the exemplary embodiments disclosed here.

This description, for purposes of explanation, has been described with reference to specific embodiments. The illustrative discussions above, however, are not intended to be exhaustive or limit the present systems and methods to the precise forms discussed. Many modifications and variations are possible in view of the above teachings. The embodiments were chosen and described in order to explain the principles of the present systems and methods and their practical applications, to enable others skilled in the art to utilize the present systems, apparatus, and methods and various embodiments with various modifications as may be suited to the particular use contemplated.