]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - sys/fs/fuse/fuse_param.h
MFV r316876: 7542 zfs_unmount failed with EZFS_UNSHARENFSFAILED
[FreeBSD/FreeBSD.git] / sys / fs / fuse / fuse_param.h
1 /*-
2  * SPDX-License-Identifier: BSD-3-Clause
3  *
4  * Copyright (c) 2007-2009 Google Inc. and Amit Singh
5  * All rights reserved.
6  * 
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions are
9  * met:
10  * 
11  * * Redistributions of source code must retain the above copyright
12  *   notice, this list of conditions and the following disclaimer.
13  * * Redistributions in binary form must reproduce the above
14  *   copyright notice, this list of conditions and the following disclaimer
15  *   in the documentation and/or other materials provided with the
16  *   distribution.
17  * * Neither the name of Google Inc. nor the names of its
18  *   contributors may be used to endorse or promote products derived from
19  *   this software without specific prior written permission.
20  * 
21  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
22  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
23  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
24  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
25  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
26  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
27  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
28  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
29  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
30  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
31  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
32  *
33  * $FreeBSD$ 
34  */
35
36 #ifndef _FUSE_PARAM_H_
37 #define _FUSE_PARAM_H_
38
39 /*
40  * This is the prefix ("fuse" by default) of the name of a FUSE device node
41  * in devfs. The suffix is the device number. "/dev/fuse0" is the first FUSE
42  * device by default. If you change the prefix from the default to something
43  * else, the user-space FUSE library will need to know about it too.
44  */
45 #define FUSE_DEVICE_BASENAME               "fuse"
46
47 /*
48  * This is the number of /dev/fuse<n> nodes we will create. <n> goes from
49  * 0 to (FUSE_NDEVICES - 1).
50  */
51 #define FUSE_NDEVICES                      16
52
53 /*
54  * This is the default block size of the virtual storage devices that are
55  * implicitly implemented by the FUSE kernel extension. This can be changed
56  * on a per-mount basis (there's one such virtual device for each mount).
57  */
58 #define FUSE_DEFAULT_BLOCKSIZE             4096
59
60 /*
61  * This is default I/O size used while accessing the virtual storage devices.
62  * This can be changed on a per-mount basis.
63  */
64 #define FUSE_DEFAULT_IOSIZE                4096
65
66 #ifdef KERNEL
67
68 /*
69  * This is the soft upper limit on the number of "request tickets" FUSE's
70  * user-kernel IPC layer can have for a given mount. This can be modified
71  * through the fuse.* sysctl interface.
72  */
73 #define FUSE_DEFAULT_MAX_FREE_TICKETS      1024
74
75 #define FUSE_DEFAULT_IOV_PERMANENT_BUFSIZE (1L << 19)
76 #define FUSE_DEFAULT_IOV_CREDIT            16
77
78 #endif
79
80 #define FUSE_LINK_MAX                      UINT32_MAX
81
82 #endif /* _FUSE_PARAM_H_ */