Lines Matching +full:monitor +full:- +full:interval +full:- +full:ms
1 /* SPDX-License-Identifier: GPL-2.0 */
18 /* Max priority score for DAMON-based operation schemes */
24 return l + prandom_u32_max(r - l); in damon_rand()
28 * struct damon_addr_range - Represents an address region of [@start, @end).
38 * struct damon_region - Represents a monitoring target region.
45 * @age is initially zero, increased for each aggregation interval, and reset
48 * region are set as region size-weighted average of those of the two regions.
62 * struct damon_target - Represents a monitoring target.
63 * @pid: The PID of the virtual address space to monitor.
81 * enum damos_action - Represents an action of a Data Access Monitoring-based
107 * struct damos_quota - Controls the aggressiveness of the given scheme.
108 * @ms: Maximum milliseconds that the scheme can use.
110 * @reset_interval: Charge reset interval in milliseconds.
117 * &struct damos->action to large memory, DAMON allows users to set time and/or
118 * size quotas. The quotas can be set by writing non-zero values to &ms and
120 * &ms milliseconds within &reset_interval for applying the action. If the
129 * target memory regions using the &struct damon_operations->get_scheme_score.
135 unsigned long ms; member
162 * enum damos_wmark_metric - Represents the watermark metric.
175 * struct damos_watermarks - Controls when a given scheme should be activated.
177 * @interval: Watermarks check time interval in microseconds.
185 * least every &interval microseconds and works as below.
193 unsigned long interval; member
203 * struct damos_stat - Statistics on a given scheme.
219 * struct damos_access_pattern - Target access pattern of the given scheme.
222 * @min_nr_accesses: Minimum ``->nr_accesses`` of target regions.
223 * @max_nr_accesses: Maximum ``->nr_accesses`` of target regions.
237 * struct damos - Represents a Data Access Monitoring-based Operation Scheme.
245 * For each aggregation interval, DAMON finds regions which fit in the
271 * enum damon_ops_id - Identifier for each monitoring operations implementation
289 * struct damon_operations - Monitoring operations for given use cases.
292 * @init: Initialize operations-related data structures.
293 * @update: Update operations-related data structures.
298 * @apply_scheme: Apply a DAMON-based operation scheme.
313 * @init should initialize operations-related data structures. For example,
316 * @update should update the operations-related data structures. For example,
329 * DAMON-based operation scheme is found. It should apply the scheme's action
354 * struct damon_callback - Monitoring events notification callbacks.
368 * The monitoring thread calls @after_wmarks_check after each DAMON-based
379 * If any callback returns non-zero, monitoring stops.
392 * struct damon_attrs - Monitoring attributes for accuracy/overhead control.
395 * @aggr_interval: The time between monitor results aggregations.
407 * @ops_update_interval. All time intervals are in micro-seconds.
420 * struct damon_ctx - Represents a context for each monitoring. This is the
469 return container_of(r->list.next, struct damon_region, list); in damon_next_region()
474 return container_of(r->list.prev, struct damon_region, list); in damon_prev_region()
479 return list_last_entry(&t->regions_list, struct damon_region, list); in damon_last_region()
484 return list_first_entry(&t->regions_list, struct damon_region, list); in damon_first_region()
489 return r->ar.end - r->ar.start; in damon_sz_region()
494 list_for_each_entry(r, &t->regions_list, list)
497 list_for_each_entry_from(r, &t->regions_list, list)
500 list_for_each_entry_safe(r, next, &t->regions_list, list)
503 list_for_each_entry(t, &(ctx)->adaptive_targets, list)
506 list_for_each_entry_safe(t, next, &(ctx)->adaptive_targets, list)
509 list_for_each_entry(s, &(ctx)->schemes, list)
512 list_for_each_entry_safe(s, next, &(ctx)->schemes, list)
525 __list_add(&r->list, &prev->list, &next->list); in damon_insert_region()
526 t->nr_regions++; in damon_insert_region()
559 return ctx->ops.id == DAMON_OPS_VADDR || ctx->ops.id == DAMON_OPS_FVADDR; in damon_target_has_pid()