# US 9,003,159 B2 · Data caching in non-volatile memory

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 9,003,159 B2
- Document ID: US9003159B2
- Status: Granted
- Kind: B2
- Application number: 12/898,483
- Filed: 2010-10-05
- Published: 2011-04-07
- Granted: 2015-04-07
- Earliest claimed: 2009-10-05
- Assignees: Marvell World Trade Ltd.
- Applicants: Shekhar S. Deshkar; Sandeep Karmarkar; Arvind Pruthi; Ram Kishore Johri
- Inventors: Shekhar S. Deshkar; Sandeep Karmarkar; Arvind Pruthi; Ram Kishore Johri
- Web page: https://patentgrep.com/patent/US9003159B2

## CPC

- G06F 12/0873: Mapping of cache memory to specific storage devices or parts thereof
- G06F 12/0246: {in block erasable memory, e.g. flash memory}
- G06F 12/0292: {using tables or multilevel address translation means (G06F12/023 takes precedence; address translation in virtual memory systems G06F12/10)}
- G06F 2212/222: Non-volatile memory
- G06F 2212/261: Storage comprising a plurality of storage devices
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Methods, systems, and apparatus, including computer programs encoded on a computer storage medium, can perform data caching. In some implementations, a method and system include receiving information that includes a logical address, allocating a physical page in a non-volatile memory structure, mapping the logical address to a physical address of the physical page, and writing, based on the physical address, data to the non-volatile memory structure to cache information associated with the logical address. The logical address can include an identifier of a data storage device and a logical page number.

## Claims

### Claim 1

An apparatus, comprising:
a flash memory structure;
circuitry to receive a command sequence that includes a logical address, wherein the logical address includes (i) information that identifies a data storage device from among two or more separate data storage devices and (ii) a logical page number within the identified data storage device;
circuitry to receive data associated with the logical address;
circuitry to allocate a physical page in the flash memory structure;
circuitry to store a mapping from the logical address to a physical address associated with the physical page;
circuitry to write, based on the physical address, the data associated with the logical address to the flash memory structure to cache the data associated with the logical address; and
circuitry to (i) invalidate the physical page in the flash memory structure based on the logical address being included in an invalidate command sent by an application to indicate caching of the data associated with the logical address is no longer needed and (ii) allow a garbage collector to directly use the physical page when performing an erasure to make the physical page available for re-allocation;
wherein the mapping indicates a cached status of the data associated with the logical address; and
wherein the mapping goes from the logical address to the physical address without an intervening reference to a logical page number (LPN) of the flash memory structure.

### Claim 2 (depends on 1)

The apparatus of claim 1, comprising:
circuitry to receive a read command sequence that includes a logical address;
circuitry to identify a physical address associated with the logical address of the read command sequence; and
circuitry to read, based on the identified physical address, data from the flash memory structure to provide cached data associated with the logical address of the read command sequence.

### Claim 3 (depends on 1)

The apparatus of claim 1, wherein the flash memory structure is used as a write-back cache, has less than 25% of its total capacity reserved specifically for garbage collection, and has less than 40% of its total capacity reserved for both garbage collection and buffer space.

### Claim 4 (depends on 1)

The apparatus of claim 1, wherein the flash memory structure comprises two or more cache devices, and wherein the circuitry to allocate comprises circuitry to select a cache device from among the two or more cache devices based on the logical address.

### Claim 5 (depends on 4)

The apparatus of claim 4, wherein the circuitry to select comprises circuitry to apply a hash function to a {target-ID, offset, length} tuple to produce an identifier of the cache device from among the two or more cache devices.

### Claim 6

A method, comprising:
receiving, from a host system, information that includes a logical address, wherein the logical address comprises (i) a target device identifier for one of two or more separate data storage devices and (ii) a logical block address (LBA) within a single data storage device identified by the target device identifier;
receiving data associated with the logical address from one of the host system or a data storage device of the two or more separate data storage devices;
allocating a physical page in a flash memory structure, wherein the flash memory structure is configured to cache data for the two or more separate data storage devices;
storing a mapping from the logical address to a physical address of the physical page;
writing, based on the physical address, the data associated with the logical address to the flash memory structure to cache the data associated with the logical address;
invalidating the physical page in the flash memory structure based on the logical address being included in an invalidate command sent by an application to indicate caching of the data associated with the logical address is no longer needed; and
allowing a garbage collector to directly use the physical page when performing an erasure to make the physical page available for re-allocation;
wherein the mapping indicates a cached status of the data associated with the logical address; and
wherein the mapping goes directly from the logical address to the physical address.

### Claim 7 (depends on 6)

The method of claim 6, wherein receiving data associated with the logical address comprises reading data from the single data storage device based on the logical address.

### Claim 8 (depends on 6)

The method of claim 6, wherein the flash memory structure is used as a write-back cache, has less than 25% of its total capacity reserved specifically for garbage collection, and has less than 40% of its total capacity reserved for both garbage collection and buffer space.

### Claim 9 (depends on 6)

The method of claim 6, wherein the flash memory structure comprises two or more caching devices, the method comprising:
selecting a caching device from among the two or more caching devices based on the logical address, wherein writing data to the flash memory structure comprises communicating with the selected caching device.

### Claim 10 (depends on 9)

The method of claim 9, wherein selecting the caching device comprises applying a hash function to a {target-ID, offset, length} tuple to produce an identifier of the caching device from among the two or more caching devices.

### Claim 11 (depends on 6)

The method of claim 6, wherein the two or more separate data storage devices comprise two or more hard disk drives.
