__auxiliary_device_add(9)
πΈ NAME πΈ
__auxiliary_device_add β add an auxiliary bus device. Welcome to the Kernel API Manual page for it, bestie π«Άβ¨
β¨ SYNOPSIS β¨
int __auxiliary_device_add (struct auxiliary_device *auxdev , const char
*modname );
π«Ά ARGUMENTS π«Ά
auxdevβ the auxiliary bus device you're adding to the bus πmodnameβ the name of the parent device's driver module π
π DESCRIPTION π
Okay so this is the third step in the three-step process to register an auxiliary_device. Main character energy only β¨
This function must be called after a successful call to auxiliary_device_init, which is the one that performs the device_initialize. So if this returns an error code, you have to call auxiliary_device_uninit so that the .release callback gets triggered to free the memory associated with the auxiliary_device π
Bestie, do not skip the cleanup. If__auxiliary_device_addhands you an error code, thatauxiliary_device_uninitcall is not optional β it's giving necessary, no cap π
The expectation is that users will call the "auxiliary_device_add" macro, so that the caller's KBUILD_MODNAME is automatically inserted for the modname parameter π Only if a user requires a custom name would this version be called directly π
π SEE ALSO π
- Kernel file
./drivers/base/auxiliary.c PURPOSE(9)USAGE(9)EXAMPLE(9)auxiliary_device_init(9)__auxiliary_driver_register(9)auxiliary_driver_unregister(9)auxiliary_device_create(9)auxiliary_device_destroy(9)__devm_auxiliary_device_create(9)dev_is_auxiliary(9)
Big kiss from the ./drivers/base directory, dated October 2026, on the __auxiliary_device_add(9) page β slay and stay safe out there πβ¨π
π¦ 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