context
enum context { IN_KERNEL = 1, IN_USER = 2, IN_KERNEL_RECOV = 3 };
struct context {
struct context {
struct context {
typedef enum evict_result (*le_predicate)(struct lru_entry *le, void *context);
static struct lru_entry *lru_evict(struct lru *lru, le_predicate pred, void *context, bool no_sleep)
void *context;
struct evict_wrapper *w = context;
return w->pred(b, w->context);
b_predicate pred, void *context,
struct evict_wrapper w = {.lh = lh, .pred = pred, .context = context};
b = __cache_evict(bc, list_mode, pred, context, &lh);
b_predicate pred, void *context, struct lock_history *lh)
struct evict_wrapper w = {.lh = lh, .pred = pred, .context = context};
__cache_mark_many(bc, old_mode, new_mode, pred, context, &lh);
typedef enum it_action (*iter_fn)(struct dm_buffer *b, void *context);
iter_fn fn, void *context, struct lock_history *lh)
__cache_iterate(bc, list_mode, fn, context, &lh);
struct context {