STRUCT DAMON_FILTER(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– struct damon_filter(9) πŸ’–

okay so bestie, welcome to the Kernel API Manual page for struct damon_filter(9) β€” yes that's the manual name, we're being fancy today. This is the DAMON region filter for &struct damon_probe, and it's genuinely iconic, let me tell you everything ✨


🌸 NAME 🌸

struct damon_filter β€” the DAMON region filter for &struct damon_probe. That's the whole vibe. Short, sweet, main character energy πŸŽ€


✨ SYNOPSIS ✨

here's the whole struct, copypasta-exact because we do NOT play with code:

struct damon_filter {
    enum damon_filter_type type;
    bool matching;
    bool allow;
    union {
      u64 memcg_id;
    };
 };

look at her. flawless. no notes πŸ’…


πŸ¦‹ Members πŸ¦‹

okay so let's meet the members one by one, they all have lore:

  • type β€” Type of the region. that's it, that's the job πŸ’œ
  • matching β€” Whether this filter is for the type-matching ones. iykyk 🧚
  • allow β€” Whether the type-matching ones should pass this filter. gatekeeping queen πŸ‘‘
  • {unnamed_union} β€” anonymous. yeah she's mysterious, she doesn't need a name πŸ™ˆ
  • memcg_id β€” Memcg id of the question if type is DAMON_FILTER_MEMCG. conditional icon ⭐

🌈 SEE ALSO 🌈

go read the kernel file ./include/linux/damon.h bestie, and while you're at it, the whole friend group:

  • struct damon_addr_range(9)
  • struct damon_size_range(9)
  • struct damon_region(9)
  • struct damon_target(9)
  • enum damos_action(9)
  • enum damos_quota_goal_metric(9)
  • struct damos_quota_goal(9)
  • enum damos_quota_goal_tuner(9)
  • struct damos_quota(9)
  • enum damos_wmark_metric(9)
  • struct damos_watermarks(9)
  • struct damos_stat(9)
  • enum damos_filter_type(9)
  • struct damos_filter(9)
  • struct damos_walk_control(9)
  • struct damos_access_pattern(9)
  • struct damos_migrate_dests(9)
  • struct damos(9)
  • enum damon_ops_id(9)
  • struct damon_operations(9)
  • struct damon_intervals_goal(9)
  • enum damon_filter_type(9)
  • struct damon_probe(9)
  • struct damon_attrs(9)
  • struct damon_ctx(9)

like, the entire extended universe fr fr πŸ”₯


okay that's the page!! sourced straight from ./include/linux, dated October 2026 β€” shoutout to the kernel docs girlies, mwah πŸ«ΆπŸ’– slay and read your headers, periodt ✨
πŸ“¦ where this page comes from