Lines Matching +full:cache +full:- +full:op +full:- +full:block +full:- +full:size
1 /* SPDX-License-Identifier: GPL-2.0-only */
11 #include "dm-cache-block-types.h"
13 #include <linux/device-mapper.h>
15 /*----------------------------------------------------------------*/
18 * The cache policy makes the important decisions about which blocks get to
19 * live on the faster cache device.
31 enum policy_operation op; member
37 * The cache policy object. It is envisaged that this structure will be
47 * Find the location of a block.
49 * Must not block.
51 * Returns 0 if in cache (cblock will be set), -ENOENT if not, < 0 for
52 * other errors (-EWOULDBLOCK would be typical). data_dir should be
53 * READ or WRITE. fast_copy should be set if migrating this block would
62 * block may be discarded, or the bio may cover an entire block.
66 * This method is optional (policy-internal will fallback to using
75 * Retrieves background work. Returns -ENODATA when there's no
93 * Called when a cache target is first created. Used to load a
102 * Returns -ENODATA if cblock is not mapped.
113 * How full is the cache?
118 * Because of where we sit in the block layer, we can be asked to
119 * map a lot of little bios that are all in the same block (no
144 /*----------------------------------------------------------------*/
170 * Policies may store a hint for each cache block.
171 * Currently the size of this hint must be 0 or 4 bytes but we
185 /*----------------------------------------------------------------*/