2
2
* Copyright (c) 2000 Silicon Graphics, Inc. All Rights Reserved.
4
4
* This program is free software; you can redistribute it and/or modify it
5
5
* under the terms of version 2 of the GNU General Public License as
6
6
* published by the Free Software Foundation.
8
8
* This program is distributed in the hope that it would be useful, but
9
9
* WITHOUT ANY WARRANTY; without even the implied warranty of
10
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12
12
* Further, this software is distributed without any warranty that it is
13
13
* free of the rightful claim of any third person regarding infringement
14
14
* or the like. Any license provided herein, whether implied or
15
15
* otherwise, applies only to this software file. Patent licenses, if
16
16
* any, provided herein do not apply to combinations of this program with
17
17
* other software, or any other product whatsoever.
19
19
* You should have received a copy of the GNU General Public License along
20
20
* with this program; if not, write the Free Software Foundation, Inc., 59
21
21
* Temple Place - Suite 330, Boston MA 02111-1307, USA.
23
23
* Contact information: Silicon Graphics, Inc., 1600 Amphitheatre Pkwy,
24
24
* Mountain View, CA 94043, or:
28
* For further information regarding this notice, see:
28
* For further information regarding this notice, see:
30
30
* http://oss.sgi.com/projects/GenInfo/SGIGPLNoticeExplan/
32
32
#ifndef __XFS_DIR_SF_H__
46
46
* be calculated on the fly.
48
48
* Entries are packed toward the top as tight as possible. The header
49
* and the elements much be bcopy()'d out into a work area to get correct
49
* and the elements much be memcpy'd out into a work area to get correct
50
50
* alignment for the inode number fields.
52
52
typedef struct xfs_dir_shortform {
82
82
#define XFS_DIR_SF_GET_DIRINO_ARCH(from,to,arch) xfs_dir_sf_get_dirino_arch(from, to, arch)
83
83
#define XFS_DIR_SF_GET_DIRINO(from,to) xfs_dir_sf_get_dirino(from, to)
85
#define XFS_DIR_SF_GET_DIRINO_ARCH(from,to,arch) DIRINO_COPY_ARCH(from,to,arch)
85
#define XFS_DIR_SF_GET_DIRINO_ARCH(from,to,arch) DIRINO_COPY_ARCH(from,to,arch)
86
86
#define XFS_DIR_SF_GET_DIRINO(from,to) DIRINO_COPY_ARCH(from,to,ARCH_NOCONVERT)
88
88
#if XFS_WANT_FUNCS || (XFS_WANT_SPACE && XFSSO_XFS_DIR_SF_PUT_DIRINO)
144
138
struct xfs_dir_leafblock;
145
139
struct xfs_dir_leaf_entry;
147
#define XFS_DIR_TRACE_SIZE 4096 /* size of global trace buffer */
141
#define XFS_DIR_TRACE_SIZE 4096 /* size of global trace buffer */
142
extern ktrace_t *xfs_dir_trace_buf;
150
145
* Trace record types.
156
151
#define XFS_DIR_KTRACE_G_DUE 5 /* dp, uio, leaf entry */
157
152
#define XFS_DIR_KTRACE_G_DUC 6 /* dp, uio, cookie */
159
#if defined(XFS_DIR_TRACE)
161
154
void xfs_dir_trace_g_du(char *where, struct xfs_inode *dp, struct uio *uio);
162
155
void xfs_dir_trace_g_dub(char *where, struct xfs_inode *dp, struct uio *uio,
163
156
xfs_dablk_t bno);
170
163
void xfs_dir_trace_g_duc(char *where, struct xfs_inode *dp, struct uio *uio,
171
164
xfs_off_t cookie);
172
165
void xfs_dir_trace_enter(int type, char *where,
173
__psunsigned_t a0, __psunsigned_t a1,
174
__psunsigned_t a2, __psunsigned_t a3,
175
__psunsigned_t a4, __psunsigned_t a5,
176
__psunsigned_t a6, __psunsigned_t a7,
177
__psunsigned_t a8, __psunsigned_t a9,
178
__psunsigned_t a10, __psunsigned_t a11);
166
void *a0, void *a1, void *a2, void *a3,
167
void *a4, void *a5, void *a6, void *a7,
168
void *a8, void *a9, void *a10, void *a11);
180
170
#define xfs_dir_trace_g_du(w,d,u)
181
171
#define xfs_dir_trace_g_dub(w,d,u,b)