1fstyp_mod_init(3FFiSlTeYPS)ystem Type Identification Library Fufnscttyipo_nmsod_init(3FSTYP)
2
3
4

NAME

6       fstyp_mod_init,  fstyp_mod_fini,  fstyp_mod_ident,  fstyp_mod_get_attr,
7       fstyp_mod_dump - libfstyp module interface
8

SYNOPSIS

10       cc [ flag... ] file... -lfstyp  -lnvpair  [ library... ]
11       #include <libnvpair.h>
12       #include <libfstyp.h>
13
14       int fstyp_mod_init(int fd, off64_t **offset, fstyp_mod_handle_t *handle);
15
16
17       void fstyp_mod_fini(fstyp_mod_handle_t handle);
18
19
20       int fstyp_mod_ident(fstyp_mod_handle_t handle);
21
22
23       int fstyp_mod_get_attr(fstyp_mod_handle_t handle, nvlist_t **attr);
24
25
26       int fstyp_mod_dump(fstyp_mod_handle_t handle, FILE *fout, FILE *ferr);
27
28

PARAMETERS

30       fd        Open file descriptor of a block or a raw device that contains
31                 the file system to be identified.
32
33
34       offset    Offset from the beginning of the device where the file system
35                 is located.
36
37
38       handle    Opaque handle that the module returns in fstyp_mod_init() and
39                 is used with other module functions.
40
41
42       fout      Output stream.
43
44
45       ferr      Error stream.
46
47

DESCRIPTION

49       A  libfstyp  module  implements  heuristics required to identify a file
50       system type. The modules are shared objects  loaded  by  libfstyp.  The
51       libfstyp modules are located in /usr/lib/fs subdirectories. A subdirec‐
52       tory name defines the name of the file system.
53
54
55       Each   module   exports   the    fstyp_mod_init(),    fstyp_mod_fini(),
56       fstyp_mod_ident(),  and  fstyp_mod_get_attr()  functions.  All of these
57       functions map directly to the respective libfstyp interfaces.
58
59
60       The fstyp_mod_dump() function is optional. It can  be  used  to  output
61       unformatted information about the file system. This function is used by
62       the  fstyp(1M)  command  when  the  -v   option   is   specified.   The
63       fstyp_mod_dump() function is not recommended and should be used only in
64       legacy modules.
65

FILES

67       /usr/lib/fs/
68
69           Default module directory.
70
71
72       /usr/lib/fs/fstype/fstyp.so.1
73
74           Default path to a libfstyp module for an fstype file system.
75
76

ATTRIBUTES

78       See attributes(5) for descriptions of the following attributes:
79
80
81
82
83       ┌─────────────────────────────┬─────────────────────────────┐
84       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
85       ├─────────────────────────────┼─────────────────────────────┤
86       │Interface Stability          │Evolving                     │
87       ├─────────────────────────────┼─────────────────────────────┤
88       │MT-Level                     │MT-Safe                      │
89       └─────────────────────────────┴─────────────────────────────┘
90

SEE ALSO

92       fstyp(1M), fstyp_strerror(3FSTYP), libfstyp(3LIB), attributes(5)
93
94
95
96SunOS 5.11                        29 Jun 2006           fstyp_mod_init(3FSTYP)
Impressum