]>
Commit | Line | Data |
---|---|---|
1c79356b | 1 | /* |
5d5c5d0d A |
2 | * Copyright (c) 2000-2002 Apple Computer, Inc. All rights reserved. |
3 | * | |
8ad349bb | 4 | * @APPLE_LICENSE_OSREFERENCE_HEADER_START@ |
1c79356b | 5 | * |
8ad349bb A |
6 | * This file contains Original Code and/or Modifications of Original Code |
7 | * as defined in and that are subject to the Apple Public Source License | |
8 | * Version 2.0 (the 'License'). You may not use this file except in | |
9 | * compliance with the License. The rights granted to you under the | |
10 | * License may not be used to create, or enable the creation or | |
11 | * redistribution of, unlawful or unlicensed copies of an Apple operating | |
12 | * system, or to circumvent, violate, or enable the circumvention or | |
13 | * violation of, any terms of an Apple operating system software license | |
14 | * agreement. | |
15 | * | |
16 | * Please obtain a copy of the License at | |
17 | * http://www.opensource.apple.com/apsl/ and read it before using this | |
18 | * file. | |
19 | * | |
20 | * The Original Code and all software distributed under the License are | |
21 | * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER | |
22 | * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, | |
23 | * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, | |
24 | * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. | |
25 | * Please see the License for the specific language governing rights and | |
26 | * limitations under the License. | |
27 | * | |
28 | * @APPLE_LICENSE_OSREFERENCE_HEADER_END@ | |
1c79356b A |
29 | */ |
30 | /* @(#)loadable_fs.h 2.0 26/06/90 (c) 1990 NeXT */ | |
31 | ||
32 | /* XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX | |
33 | * | |
34 | * W I L L D R A S T I C A L L Y C H A N G E S O O N | |
35 | * U S E A T Y O U R O W N R I S K | |
36 | * | |
37 | * XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX */ | |
38 | ||
39 | ||
40 | /* | |
41 | * loadable_fs.h - message struct for loading and initializing loadable | |
42 | * file systems. | |
1c79356b A |
43 | */ |
44 | ||
9bccf70c A |
45 | #ifndef _SYS_LOADABLE_FS_ |
46 | #define _SYS_LOADABLE_FS_ | |
1c79356b A |
47 | |
48 | ||
49 | /* | |
50 | * Constants for Loadabls FS Utilities (in "/System/Library/Filesystems") | |
51 | * | |
52 | * Example of a /usr/filesystems directory | |
53 | * | |
54 | * /usr/filesystems/dos.fs/dos.util utility with which WSM | |
55 | * communicates | |
56 | * /usr/filesystems/dos.fs/dos.name "DOS Floppy" | |
57 | * /usr/filesystems/dos.fs/dos_reloc actual loadable filesystem | |
58 | * /usr/filesystems/dos.fs/dos.openfs.tiff "open folder" icon | |
59 | * /usr/filesystems/dos.fs/dos.fs.tiff "closed folder" icon | |
60 | */ | |
61 | #define FS_DIR_LOCATION "/System/Library/Filesystems" | |
62 | #define FS_DIR_SUFFIX ".fs" | |
63 | #define FS_UTIL_SUFFIX ".util" | |
64 | #define FS_OPEN_SUFFIX ".openfs.tiff" | |
65 | #define FS_CLOSED_SUFFIX ".fs.tiff" | |
66 | #define FS_NAME_SUFFIX ".name" | |
67 | #define FS_LABEL_SUFFIX ".label" | |
68 | ||
69 | /* | |
70 | * .util program commands - all sent in the form "-p" or "-m" ... as argv[1]. | |
71 | */ | |
72 | #define FSUC_PROBE 'p' /* probe FS for mount or init */ | |
73 | /* example usage: foo.util -p fd0 removable writable */ | |
74 | ||
75 | #define FSUC_PROBEFORINIT 'P' /* probe FS for init only */ | |
76 | /* example usage: foo.util -P fd0 removable */ | |
77 | ||
78 | #define FSUC_MOUNT 'm' /* mount FS */ | |
79 | /* example usage: foo.util -m fd0 /bar removable writable */ | |
80 | ||
81 | #define FSUC_REPAIR 'r' /* repair ('fsck') FS */ | |
82 | /* example usage: foo.util -r fd0 removable */ | |
83 | ||
84 | #define FSUC_INITIALIZE 'i' /* initialize FS */ | |
85 | /* example usage: foo.util -i fd0 removable */ | |
86 | ||
87 | #define FSUC_UNMOUNT 'u' /* unmount FS */ | |
88 | /* example usage: foo.util -u fd0 /bar */ | |
89 | ||
90 | /* The following is not used by Workspace Manager */ | |
91 | #define FSUC_MOUNT_FORCE 'M' /* like FSUC_MOUNT, but proceed even on | |
92 | * error. */ | |
93 | /* | |
94 | * Return codes from .util program | |
95 | */ | |
96 | #define FSUR_RECOGNIZED (-1) /* response to FSUC_PROBE; implies that | |
97 | * a mount is possible */ | |
98 | #define FSUR_UNRECOGNIZED (-2) /* negative response to FSUC_PROBE */ | |
99 | #define FSUR_IO_SUCCESS (-3) /* mount, unmount, repair succeeded */ | |
100 | #define FSUR_IO_FAIL (-4) /* unrecoverable I/O error */ | |
101 | #define FSUR_IO_UNCLEAN (-5) /* mount failed, file system not clean | |
102 | */ | |
103 | #define FSUR_INVAL (-6) /* invalid argument */ | |
104 | #define FSUR_LOADERR (-7) /* kern_loader error */ | |
105 | #define FSUR_INITRECOGNIZED (-8) /* response to FSUC_PROBE or | |
106 | * FSUC_PROBEFORINIT, implies that | |
107 | * initialization is possible */ | |
108 | ||
109 | /* | |
110 | * mount parameters passed from WSM to the .util program. | |
111 | */ | |
112 | #define DEVICE_READONLY "readonly" | |
113 | #define DEVICE_WRITABLE "writable" | |
114 | ||
115 | #define DEVICE_REMOVABLE "removable" | |
116 | #define DEVICE_FIXED "fixed" | |
117 | ||
118 | /* | |
119 | * Additional parameters to the mount command - used by WSM when they | |
120 | * appear in the /etc/mtab file. | |
121 | */ | |
122 | #define MNTOPT_FS "filesystem=" /* e.g. "filesystem=DOS" */ | |
123 | #define MNTOPT_REMOVABLE "removable" | |
124 | ||
9bccf70c | 125 | #endif /* _SYS_LOADABLE_FS_ */ |