Rechercher une page de manuel
sysfs_schedule_callback
Langue: en
Version: June 2009 (debian - 07/07/09)
Section: 9 (Appels noyau Linux)
NAME
sysfs_schedule_callback - helper to schedule a callback for a kobjectSYNOPSIS
- int sysfs_schedule_callback(struct kobject * kobj, void (*func) (void *), void * data, struct module * owner);
ARGUMENTS
kobj
- object we're acting for.
func
- callback function to invoke later.
data
- argument to pass to func.
owner
- module owning the callback code
DESCRIPTION
sysfs attribute methods must not unregister themselves or their parent kobject (which would amount to the same thing). Attempts to do so will deadlock, since unregistration is mutually exclusive with driver callbacks.
Instead methods can call this routine, which will attempt to allocate and schedule a workqueue request to call back func with data as its argument in the workqueue's process context. kobj will be pinned until func returns.
Returns 0 if the request was submitted, -ENOMEM if storage could not be allocated, -ENODEV if a reference to owner isn't available.
COPYRIGHT
Contenus ©2006-2024 Benjamin Poulain
Design ©2006-2024 Maxime Vantorre