Disk drive employing allocation-based scan reporting
AssigneeWestern Digital Corporation
InventorsSteven M. Howe, Daniel John Sokolov
Life of this patent
Estimating the term…
Abstract
A method is provided for managing a cache in a disk drive having an intelligent interface for communicating with a host. The drive includes a magnetic disk, and the cache is divisible into a number of segments, and employs a cache control structure including cache parameters. The drive receives a first command and a second command. The method comprises the steps of: performing a scan of the cache to assign the first command to a segment; compensating the cache parameters in response to the scan; and performing a scan to assign the second command to a cache segment prior to caching of data requested in the first command.
Claims18
In a disk drive having an intelligent interface for communicating with a host, a magnetic disk, and a cache wherein the cache is divisible into a number of segments, wherein the cache employs a cache control structure including cache parameters, wherein the disk drive receives a first command and a second command, a method of managing the cache comprising the steps of:
- (a) performing a scan of the cache to assign the first command to a segment;
- (b) compensating the cache parameters in response to the scan;
- and
- (c) performing a scan to assign the second command to a cache segment prior to caching of data requested in the first command,
- wherein the first command has a request with a request logical block address range and a request first logical block address, and wherein each segment of the cache has a segment logical block address range, wherein the step of performing a scan of the cache to assign the first command to a segment comprises the steps of:
- (a1) checking each segment of the cache to determine if the request logical block address range overlaps the segment logical block address range;
- (a2) is true for a segment checking if the request first logical block address is in the segment logical block address range;
- and
- (a3) if step (a2) is true of the segment, assigningly the first command to this segment.
In a disk drive having an intelligent interface for communicating with a host, a magnetic disk, and a cache wherein the cache is divisible into a number of segments, wherein the cache employs a cache control structure including cache parameters, wherein the disk drive receives a first command and a second command, a method of managing the cache comprising the steps of:
- (a) performing scan of the cache to assign the first command to a segment;
- (b) compensating the cache parameters in response to the scan;
- and
- (c) performing a scan to assign the second command to a cache segment prior to caching of data requested in the first command, wherein the step of performing a scan of the cache to assign the first command to a segment further comprises the steps of:
- (a1) waiting for a write operation to complete in the segment;
- (a2) determining if there is a cache hit in the segment and if there is not a cache hit in the segment aborting any prefetch, waiting for any write to complete, setting the cache parameters with an access type for the first command, and designating an active segment;
- and
- (a3) if there is a cache hit in the segment, determining whether the cache hit is a virtual cache hit, setting sequential access mode or repeat access mode and designating an active segment.
In a disk drive having an intelligent interface for communicating with a host, a magnetic disk, and a cache wherein the cache is divisible into a number of segments, wherein the cache employs a cache control structure including cache parameters, wherein the disk drive receives a first command and a second command, a method for managing the cache comprising the steps of:
- (a) performing a scan to assign the first command to a segment;
- (b) initiating a read to prefetch data associated with the first command;
- (c) compensating the cache parameters in response to the scan;
- and
- (d) performing a scan to assign the second command to a segment prior to caching of prefetch data associated with the first command;
- wherein the first command has a request with a request logical block address range and a request first logical block address, and wherein each segment of the cache has a segment logical block address range, wherein the step of performing a scan of the cache to assign the first command to a segment comprises the steps of:
- (a1) checking each segment of the cache to determine if the request logical block address range overlaps the segment logical block address range;
- (a2) if step (a1) is true for a segment, checking if the request first logical block address is in the segment logical block address range;
- and
- (a3) if step (a2) is true of the segment assigning the first command to this segment.
Dependencies are inferred from the claim text.