vfs_init Entry Point

Purpose

Initializes a virtual file system.

Syntax

int vfs_init ( gfsp)
struct gfs *gfsp;

Parameter

Item Description
gfsp Points to a file system's attribute structure.

Description

The vfs_init entry point is invoked to initialize a file system. It is called when a file system implementation is loaded to perform file system-specific initialization.

The vfs_init entry point is not called through the virtual file system switch. Instead, it is called indirectly by the gfsadd kernel service when the vfs_init entry point address is stored in the gfs structure passed to the gfsadd kernel service as a parameter. (The vfs_init address is placed in the gfs_init field of the gfs structure.) The gfs structure is defined in the /usr/include/sys/gfs.h file.

Note: The return value for the vfs_init entry point is passed back as the return value from the gfsadd kernel service.

Execution Environment

The vfs_init entry point can be called from the process environment only.

Return Values

Item Description
0 Indicates success.

Nonzero return values are returned from the /usr/include/sys/errno.h file to indicate failure.