STRUCT KUNIT_ATTR(9)
π struct kunit_attr(9) π
okay bestie, welcome to the Kernel API Manual entry for struct kunit_attr β it's giving βrepresents a test attribute and holds flexible helper functions to interact with attribute.β π
No cap, this is the lilβ struct bundle for test-attribute vibes and helper functions. β¨
β¨ SYNOPSIS β¨
struct kunit_attr {
const char *name;
void *(*get_attr)(void *test_or_suite, bool is_test);
const char *(*to_string)(void *attr, bool *to_free);
int (*filter)(void *attr, const char *input, int *err);
void *attr_default;
enum print_ops print;
};
π Members π
nameβ name of test attribute, eg.speedπββοΈπ¨get_attrβ function to return attribute value given a test πto_stringβ function to return string representation of given attribute value π‘filterβ function to indicate whether a given attribute value passes a filter π§attr_defaultβ default attribute value used during filtering πprintβ value ofenum print_opsto indicate when to print attribute π¨οΈβ¨
π¦ SEE ALSO π¦
Kernel file ./lib/kunit/attributes.c β bestie, thatβs the spot. π«Ά
mwah π β sourced from ./lib/kunit, version/date: October 2026. ππ
π¦ 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