arm_smmu_invs_purge(9)
π arm_smmu_invs_purge β Kernel API Manual β¨
okay so bestie, welcome to the <rainbow>arm_smmu_invs_purge(9)</rainbow> glow-up page β it's a kernel API manual entry and honestly it's giving "tiny function, big responsibilities" energy π
πΈ NAME πΈ
arm_smmu_invs_purge β bestie, this one literally purges all the trash entries in the @invs ποΈβ¨ no cap, that's the whole vibe.
β¨ SYNOPSIS β¨
VISIBLE_IF_KUNIT struct arm_smmu_invs * arm_smmu_invs_purge (struct arm_smmu_invs *invs );
yep, that's the whole signature. VISIBLE_IF_KUNIT included, we do NOT skip the macro around here π
π¦ ARGUMENTS π¦
invsβ the base invalidation array. that's it, that's the argument. she's the main character of this function π«Ά
π RETURN π
so like, on success you get a newly allocated array with all the trash entries removed β slay, clean, iconic π
but also, it returns NULL in two very specific situations, and we're not skipping these:
- if there is no trash entry in the array at all, or
- if the allocation failed π
either way: NULL. don't come for her, she's just being honest.
π₯ DESCRIPTION π₯
okay so here's where the ground rules live, and you need these, bestie:
this function must be locked and serialized with arm_smmu_invs_merge and arm_smmu_invs_unref β like, all three of them, same lock energy, no cutting corners π
but β and this is the fun little exception β do not lockdep on any lock for KUNIT test. that's the rule, okay? KUNIT gets a pass π
and the part everyone forgets: the caller is responsible for freeing the invs and the returned new one. both of them. not one. both. free your stuff, bestie, the kernel is not your mom π
π§ SEE ALSO π§
- the kernel file, right here:
./drivers/iommu/arm/arm-smmu-v3/arm-smmu-v3.c arm_smmu_invs_for_each_entry(9)arm_smmu_invs_for_each_cmp(9)arm_smmu_invs_merge(9)arm_smmu_invs_unref(9)
go read those too, iykyk π
okay and finally, the credits because we always give credit π this page lives under ./drivers/iommu/arm/arm-smmu-v3, dated October 2026, and the manual title is <pink>arm_smmu_invs_purge(9)</pink>. that's the whole footer, folded into a cute little sign-off. periodt. π
β¨πΈ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms