]>
Commit | Line | Data |
---|---|---|
959ef981 | 1 | // SPDX-License-Identifier: LGPL-2.1 |
2bd0ea18 | 2 | /* |
f302e9e4 NS |
3 | * Copyright (c) 2000-2002, 2005 Silicon Graphics, Inc. |
4 | * All Rights Reserved. | |
2bd0ea18 NS |
5 | */ |
6 | #ifndef __JDM_H__ | |
7 | #define __JDM_H__ | |
8 | ||
9 | typedef int intgen_t; | |
89184fbc AG |
10 | typedef void jdm_fshandle_t; /* filesystem handle */ |
11 | typedef void jdm_filehandle_t; /* filehandle */ | |
2bd0ea18 NS |
12 | |
13 | struct xfs_bstat; | |
14290264 | 14 | struct attrlist_cursor; |
258b00ea | 15 | struct parent; |
89184fbc AG |
16 | |
17 | extern jdm_fshandle_t * | |
18 | jdm_getfshandle( char *mntpnt); | |
19 | ||
20 | extern void | |
21 | jdm_new_filehandle( jdm_filehandle_t **handlep, /* new filehandle */ | |
22 | size_t *hlen, /* new filehandle size */ | |
23 | jdm_fshandle_t *fshandlep, /* filesystem filehandle */ | |
24 | struct xfs_bstat *sp); /* bulkstat info */ | |
dfc130f3 | 25 | |
89184fbc AG |
26 | extern void |
27 | jdm_delete_filehandle( jdm_filehandle_t *handlep,/* filehandle to delete */ | |
28 | size_t hlen); /* filehandle size */ | |
29 | ||
30 | extern intgen_t | |
31 | jdm_open( jdm_fshandle_t *fshandlep, | |
32 | struct xfs_bstat *sp, | |
33 | intgen_t oflags); | |
34 | ||
35 | extern intgen_t | |
36 | jdm_readlink( jdm_fshandle_t *fshandlep, | |
37 | struct xfs_bstat *sp, | |
38 | char *bufp, | |
39 | size_t bufsz); | |
2bd0ea18 | 40 | |
14290264 NS |
41 | extern intgen_t |
42 | jdm_attr_multi( jdm_fshandle_t *fshp, | |
b46789e2 | 43 | struct xfs_bstat *statp, |
14290264 NS |
44 | char *bufp, int rtrvcnt, int flags); |
45 | ||
46 | extern intgen_t | |
47 | jdm_attr_list( jdm_fshandle_t *fshp, | |
b46789e2 | 48 | struct xfs_bstat *statp, |
14290264 NS |
49 | char *bufp, size_t bufsz, int flags, |
50 | struct attrlist_cursor *cursor); | |
51 | ||
258b00ea | 52 | extern int |
60ac13e8 | 53 | jdm_parents( jdm_fshandle_t *fshp, |
b46789e2 | 54 | struct xfs_bstat *statp, |
258b00ea | 55 | struct parent *bufp, size_t bufsz, |
60ac13e8 | 56 | unsigned int *count); |
258b00ea TS |
57 | |
58 | extern int | |
60ac13e8 | 59 | jdm_parentpaths( jdm_fshandle_t *fshp, |
b46789e2 | 60 | struct xfs_bstat *statp, |
258b00ea | 61 | struct parent *bufp, size_t bufsz, |
60ac13e8 | 62 | unsigned int *count); |
258b00ea | 63 | |
2bd0ea18 NS |
64 | /* macro for determining the size of a structure member */ |
65 | #define sizeofmember( t, m ) sizeof( ( ( t * )0 )->m ) | |
66 | ||
67 | /* macro for calculating the offset of a structure member */ | |
68 | #define offsetofmember( t, m ) ( ( size_t )( char * )&( ( ( t * )0 )->m ) ) | |
69 | ||
70 | #endif /* __JDM_H__ */ |