can_parent_afford_sla(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

✨ can_parent_afford_sla(9) β€” the "can ur parent actually afford this" check πŸŽ€

okay bestie, so this one lives in the Kernel API Manual (section 9, kernel developer vibes πŸ’…) and it's literally the bouncer at the club door for SLA creation. Let's get into it πŸ¦‹


🌸 NAME 🌸

can_parent_afford_sla β€” verifies if parent allows to create an SLA ✨


🫢 SYNOPSIS 🫢

bool can_parent_afford_sla (struct adf_rl_sla_input_data *sla_in ,
struct rl_sla *sla_parent , u32 sla_cir , bool is_update );

πŸ’– ARGUMENTS πŸ’–

  • sla_in β€” pointer to user input data for a new SLA
  • sla_parent β€” pointer to parent SLA object
  • sla_cir β€” current child CIR value (only for update)
  • is_update β€” request is a update

πŸ‘‘ DESCRIPTION πŸ‘‘

So the algorithm verifies if parent has enough remaining budget to take assignment of a child with provided parameters. Like, does the parent's wallet stretch that far? πŸ’Έ

In update case current CIR value must be returned to budget first β€” gotta put the old money back before you spend the new money, iykyk.

And no cap: PIR value cannot exceed the PIR assigned to parent. That's a hard limit, bestie. 🚫


πŸ”₯ RETURN πŸ”₯

  • true β€” SLA can be created βœ… slay
  • false β€” SLA cannot be created πŸ’€

⭐ SEE ALSO ⭐

Kernel file ./drivers/crypto/intel/qat/qat_common/adf_rl.c

Also go say hi to the whole friend group: find_parent(9), adf_rl_get_sla_arr_of_type(9), prepare_rp_ids(9), can_node_afford_update(9), get_next_free_sla_id(9), get_next_free_node_id(9), add_new_sla_entry(9), add_update_sla(9), adf_rl_add_sla(9), adf_rl_update_sla(9), adf_rl_get_sla(9), adf_rl_get_capability_remaining(9), adf_rl_remove_sla(9), adf_rl_remove_sla_all(9) 🫢


ngl, the source is ./drivers/crypto/intel/qat/qat... and this page is dated October 2026 β€” and it's been can_parent_afford_sla(9) the whole time. periodt. β­πŸ’œ
πŸ“¦ where this page comes from