|
FreeBSD ZFS
The Zettabyte File System
|
#include <sys/zfs_context.h>

Go to the source code of this file.
Data Structures | |
| struct | zfs_onexit |
| struct | zfs_onexit_action_node |
Typedefs | |
| typedef struct zfs_onexit | zfs_onexit_t |
| typedef struct zfs_onexit_action_node | zfs_onexit_action_node_t |
Functions | |
| void | zfs_onexit_init (zfs_onexit_t **zo) |
| void | zfs_onexit_destroy (zfs_onexit_t *zo) |
| int | zfs_onexit_fd_hold (int fd, minor_t *minorp) |
| Consumers might need to operate by minor number instead of fd, since they might be running in another thread (e.g. | |
| void | zfs_onexit_fd_rele (int fd) |
| int | zfs_onexit_add_cb (minor_t minor, void(*func)(void *), void *data, uint64_t *action_handle) |
| Add a callback to be invoked when the calling process exits. | |
| int | zfs_onexit_del_cb (minor_t minor, uint64_t action_handle, boolean_t fire) |
| Delete the callback. | |
| int | zfs_onexit_cb_data (minor_t minor, uint64_t action_handle, void **data) |
| Return the data associated with this callback. | |
| typedef struct zfs_onexit_action_node zfs_onexit_action_node_t |
| typedef struct zfs_onexit zfs_onexit_t |
| int zfs_onexit_add_cb | ( | minor_t | minor, |
| void(*)(void *) | func, | ||
| void * | data, | ||
| uint64_t * | action_handle | ||
| ) |
Add a callback to be invoked when the calling process exits.
Definition at line 155 of file zfs_onexit.c.
| int zfs_onexit_cb_data | ( | minor_t | minor, |
| uint64_t | action_handle, | ||
| void ** | data | ||
| ) |
Return the data associated with this callback.
This allows consumers of the cleanup-on-exit interfaces to stash kernel data across system calls, knowing that it will be cleaned up if the calling process exits.
Definition at line 236 of file zfs_onexit.c.
| int zfs_onexit_del_cb | ( | minor_t | minor, |
| uint64_t | action_handle, | ||
| boolean_t | fire | ||
| ) |
Delete the callback.
| [in] | fire | trigger the callback if set |
Definition at line 204 of file zfs_onexit.c.
| void zfs_onexit_destroy | ( | zfs_onexit_t * | zo | ) |
Definition at line 87 of file zfs_onexit.c.
| int zfs_onexit_fd_hold | ( | int | fd, |
| minor_t * | minorp | ||
| ) |
Consumers might need to operate by minor number instead of fd, since they might be running in another thread (e.g.
txg_sync_thread). Callers of this function must call zfs_onexit_fd_rele() when they're finished using the minor number.
Definition at line 123 of file zfs_onexit.c.
| void zfs_onexit_fd_rele | ( | int | fd | ) |
Definition at line 146 of file zfs_onexit.c.
| void zfs_onexit_init | ( | zfs_onexit_t ** | zo | ) |
Definition at line 76 of file zfs_onexit.c.
1.7.3