- NetBSD Manual Pages
PUFFS_SUSPEND(3) NetBSD Library Functions Manual PUFFS_SUSPEND(3)
Powered by man-cgi (2020-09-24).
Maintained for NetBSD
by Kimmo Suominen.
Based on man-cgi by Panagiotis Christias.
puffs_suspend -- puffs file system suspension and snapshotting
puffs Convenience Library (libpuffs, -lpuffs)
puffs_fs_suspend(struct puffs_usermount *pu);
The function puffs_fs_suspend() requests the kernel to suspend operations
to the file system indicated by pu. There are several possible outcomes:
nothing, an error or success. These will be indicated through the call-
back of the same name. The file system must set this callback if it
wants to be notified of file system suspension. The interface call
itself returns 0 on success or -1 on error and sets errno. In case an
error is returned, the callback will never be called. However, the con-
verse does not hold and the callback may never be called even if the
library call is successful.
In case the kernel is successful to start suspending the file system, the
callback is called with status PUFFS_SUSPEND START. The file system
implementation may use this as a hint on how to handle following opera-
tions. Once the file system has successfully been suspended, the status
PUFFS_SUSPEND_SUSPENDED will be delivered. In case there was an error
while suspending, PUFFS_SUSPEND_ERROR is given. This effectively nulli-
fies any PUFFS_SUSPEND_START given earlier. Operation will automatically
resume after suspension and the status PUFFS_SUSPEND_RESUME is delivered
to the callback. Error or success is always provided in case start is
The file system is supposed to do a file system specific snapshotting
routine when it receives PUFFS_SUSPEND_SUSPENDED.
Currently the implementation works only for single-threaded file systems
which do not use puffs_cc.
File system data and metadata are not always totally correctly synchro-
nized at suspend.
NetBSD 5.1 January 27, 2007 NetBSD 5.1