1a38a92c9SIngo Weinhold/*
2dec78bb2SIngo Weinhold * Copyright 2007-2014, Ingo Weinhold, ingo_weinhold@gmx.de.
3a38a92c9SIngo Weinhold * Distributed under the terms of the MIT License.
4a38a92c9SIngo Weinhold */
5a38a92c9SIngo Weinhold#ifndef _FSSH_API_WRAPPER_H
6a38a92c9SIngo Weinhold#define _FSSH_API_WRAPPER_H
7a38a92c9SIngo Weinhold
8318cb33fSIngo Weinhold
998731302SPulkoMandy#include <string.h>
1098731302SPulkoMandy#ifdef __cplusplus
1198731302SPulkoMandy#include <new>
1298731302SPulkoMandy#endif
13a38a92c9SIngo Weinhold#include <stdlib.h>
14a38a92c9SIngo Weinhold
15a38a92c9SIngo Weinhold#include "fssh_dirent.h"
16a38a92c9SIngo Weinhold#include "fssh_errno.h"
17a38a92c9SIngo Weinhold#include "fssh_fcntl.h"
18a38a92c9SIngo Weinhold#include "fssh_stat.h"
19a38a92c9SIngo Weinhold#include "fssh_stdio.h"
20a38a92c9SIngo Weinhold#include "fssh_string.h"
21a38a92c9SIngo Weinhold#include "fssh_time.h"
22a38a92c9SIngo Weinhold#include "fssh_uio.h"
23a38a92c9SIngo Weinhold#include "fssh_unistd.h"
24a38a92c9SIngo Weinhold
25a38a92c9SIngo Weinhold#include "fssh_atomic.h"
26a38a92c9SIngo Weinhold#include "fssh_byte_order.h"
27a38a92c9SIngo Weinhold#include "fssh_defs.h"
28a38a92c9SIngo Weinhold#include "fssh_disk_device_defs.h"
29a38a92c9SIngo Weinhold#include "fssh_disk_device_manager.h"
30eedc1553SIngo Weinhold#include "fssh_driver_settings.h"
31a38a92c9SIngo Weinhold#include "fssh_drivers.h"
32a38a92c9SIngo Weinhold#include "fssh_errors.h"
33a38a92c9SIngo Weinhold#include "fssh_fs_attr.h"
34a38a92c9SIngo Weinhold#include "fssh_fs_cache.h"
35a38a92c9SIngo Weinhold#include "fssh_fs_index.h"
36a38a92c9SIngo Weinhold#include "fssh_fs_info.h"
37a38a92c9SIngo Weinhold#include "fssh_fs_interface.h"
38a38a92c9SIngo Weinhold#include "fssh_fs_query.h"
39a38a92c9SIngo Weinhold#include "fssh_fs_volume.h"
40a38a92c9SIngo Weinhold#include "fssh_kernel_export.h"
41589f1a91SAxel Dörfler#include "fssh_lock.h"
42a38a92c9SIngo Weinhold#include "fssh_module.h"
43a38a92c9SIngo Weinhold#include "fssh_node_monitor.h"
44a38a92c9SIngo Weinhold#include "fssh_os.h"
45a38a92c9SIngo Weinhold#include "fssh_type_constants.h"
46a38a92c9SIngo Weinhold#include "fssh_types.h"
47a38a92c9SIngo Weinhold
48a38a92c9SIngo Weinhold#include "DoublyLinkedList.h"
49f9ae4297SAxel Dörfler#include "SinglyLinkedList.h"
50a38a92c9SIngo Weinhold#include "Stack.h"
51a38a92c9SIngo Weinhold
52a38a92c9SIngo Weinhold
53a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
54a38a92c9SIngo Weinhold// #pragma mark - fssh_atomic.h
55a38a92c9SIngo Weinhold
56a38a92c9SIngo Weinhold#define atomic_set			fssh_atomic_set
57077c84ebSPawel Dziepak#define atomic_get_and_Set	fssh_atomic_get_and_set
58a38a92c9SIngo Weinhold#define atomic_test_and_set	fssh_atomic_test_and_set
59a38a92c9SIngo Weinhold#define atomic_add			fssh_atomic_add
60a38a92c9SIngo Weinhold#define atomic_and			fssh_atomic_and
61a38a92c9SIngo Weinhold#define atomic_or			fssh_atomic_or
62a38a92c9SIngo Weinhold#define atomic_get			fssh_atomic_get
63a38a92c9SIngo Weinhold
64a38a92c9SIngo Weinhold
65a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
66a38a92c9SIngo Weinhold// #pragma mark - fssh_bytes_order.h
67a38a92c9SIngo Weinhold
68a38a92c9SIngo Weinhold// swap directions
69a38a92c9SIngo Weinhold#define B_SWAP_HOST_TO_LENDIAN	FSSH_B_SWAP_HOST_TO_LENDIAN
70a38a92c9SIngo Weinhold#define B_SWAP_HOST_TO_BENDIAN	FSSH_B_SWAP_HOST_TO_BENDIAN
71a38a92c9SIngo Weinhold#define B_SWAP_LENDIAN_TO_HOST	FSSH_B_SWAP_LENDIAN_TO_HOST
72a38a92c9SIngo Weinhold#define B_SWAP_BENDIAN_TO_HOST	FSSH_B_SWAP_BENDIAN_TO_HOST
73a38a92c9SIngo Weinhold#define B_SWAP_ALWAYS			FSSH_B_SWAP_ALWAYS
74a38a92c9SIngo Weinhold
75a38a92c9SIngo Weinhold#define swap_action	fssh_swap_action
76a38a92c9SIngo Weinhold
77a38a92c9SIngo Weinhold// BSD/networking macros
78a38a92c9SIngo Weinhold#define htonl(x)	fssh_htonl(x)
79a38a92c9SIngo Weinhold#define ntohl(x)	fssh_ntohl(x)
80a38a92c9SIngo Weinhold#define htons(x)	fssh_htons(x)
81a38a92c9SIngo Weinhold#define ntohs(x)	fssh_ntohs(x)
82a38a92c9SIngo Weinhold
83a38a92c9SIngo Weinhold// always swap macros
84a38a92c9SIngo Weinhold#define B_SWAP_DOUBLE(arg)	FSSH_B_SWAP_DOUBLE(arg)
85a38a92c9SIngo Weinhold#define B_SWAP_FLOAT(arg)	FSSH_B_SWAP_FLOAT(arg)
86a38a92c9SIngo Weinhold#define B_SWAP_INT64(arg)	FSSH_B_SWAP_INT64(arg)
87a38a92c9SIngo Weinhold#define B_SWAP_INT32(arg)	FSSH_B_SWAP_INT32(arg)
88a38a92c9SIngo Weinhold#define B_SWAP_INT16(arg)	FSSH_B_SWAP_INT16(arg)
89a38a92c9SIngo Weinhold
90a38a92c9SIngo Weinhold#define B_HOST_IS_LENDIAN	FSSH_B_HOST_IS_LENDIAN
91a38a92c9SIngo Weinhold#define B_HOST_IS_BENDIAN	FSSH_B_HOST_IS_BENDIAN
92a38a92c9SIngo Weinhold
93a38a92c9SIngo Weinhold// Host native to little endian
94a38a92c9SIngo Weinhold#define B_HOST_TO_LENDIAN_DOUBLE(arg)	FSSH_B_HOST_TO_LENDIAN_DOUBLE(arg)
95a38a92c9SIngo Weinhold#define B_HOST_TO_LENDIAN_FLOAT(arg)	FSSH_B_HOST_TO_LENDIAN_FLOAT(arg)
96a38a92c9SIngo Weinhold#define B_HOST_TO_LENDIAN_INT64(arg)	FSSH_B_HOST_TO_LENDIAN_INT64(arg)
97a38a92c9SIngo Weinhold#define B_HOST_TO_LENDIAN_INT32(arg)	FSSH_B_HOST_TO_LENDIAN_INT32(arg)
98a38a92c9SIngo Weinhold#define B_HOST_TO_LENDIAN_INT16(arg)	FSSH_B_HOST_TO_LENDIAN_INT16(arg)
99a38a92c9SIngo Weinhold
100a38a92c9SIngo Weinhold// Little endian to host native
101a38a92c9SIngo Weinhold#define B_LENDIAN_TO_HOST_DOUBLE(arg)	FSSH_B_LENDIAN_TO_HOST_DOUBLE(arg)
102a38a92c9SIngo Weinhold#define B_LENDIAN_TO_HOST_FLOAT(arg)	FSSH_B_LENDIAN_TO_HOST_FLOAT(arg)
103a38a92c9SIngo Weinhold#define B_LENDIAN_TO_HOST_INT64(arg)	FSSH_B_LENDIAN_TO_HOST_INT64(arg)
104a38a92c9SIngo Weinhold#define B_LENDIAN_TO_HOST_INT32(arg)	FSSH_B_LENDIAN_TO_HOST_INT32(arg)
105a38a92c9SIngo Weinhold#define B_LENDIAN_TO_HOST_INT16(arg)	FSSH_B_LENDIAN_TO_HOST_INT16(arg)
106a38a92c9SIngo Weinhold
107a38a92c9SIngo Weinhold// Host native to big endian
108a38a92c9SIngo Weinhold#define B_HOST_TO_BENDIAN_DOUBLE(arg)	FSSH_B_HOST_TO_BENDIAN_DOUBLE(arg)
109a38a92c9SIngo Weinhold#define B_HOST_TO_BENDIAN_FLOAT(arg)	FSSH_B_HOST_TO_BENDIAN_FLOAT(arg)
110a38a92c9SIngo Weinhold#define B_HOST_TO_BENDIAN_INT64(arg)	FSSH_B_HOST_TO_BENDIAN_INT64(arg)
111a38a92c9SIngo Weinhold#define B_HOST_TO_BENDIAN_INT32(arg)	FSSH_B_HOST_TO_BENDIAN_INT32(arg)
112a38a92c9SIngo Weinhold#define B_HOST_TO_BENDIAN_INT16(arg)	FSSH_B_HOST_TO_BENDIAN_INT16(arg)
113a38a92c9SIngo Weinhold
114a38a92c9SIngo Weinhold// Big endian to host native
115a38a92c9SIngo Weinhold#define B_BENDIAN_TO_HOST_DOUBLE(arg)	FSSH_B_BENDIAN_TO_HOST_DOUBLE(arg)
116a38a92c9SIngo Weinhold#define B_BENDIAN_TO_HOST_FLOAT(arg)	FSSH_B_BENDIAN_TO_HOST_FLOAT(arg)
117a38a92c9SIngo Weinhold#define B_BENDIAN_TO_HOST_INT64(arg)	FSSH_B_BENDIAN_TO_HOST_INT64(arg)
118a38a92c9SIngo Weinhold#define B_BENDIAN_TO_HOST_INT32(arg)	FSSH_B_BENDIAN_TO_HOST_INT32(arg)
119a38a92c9SIngo Weinhold#define B_BENDIAN_TO_HOST_INT16(arg)	FSSH_B_BENDIAN_TO_HOST_INT16(arg)
120a38a92c9SIngo Weinhold
1219c20d5cbSAxel Dörfler#define swap_data			fssh_swap_data
1229c20d5cbSAxel Dörfler#define is_type_swapped		fssh_is_type_swapped
123a38a92c9SIngo Weinhold
124a38a92c9SIngo Weinhold
125a38a92c9SIngo Weinhold// Private implementations
1269c20d5cbSAxel Dörfler#define __swap_double		__fssh_swap_double
1279c20d5cbSAxel Dörfler#define __swap_float		__fssh_swap_float
1289c20d5cbSAxel Dörfler#define __swap_int64		__fssh_swap_int64
1299c20d5cbSAxel Dörfler#define __swap_int32		__fssh_swap_int32
1309c20d5cbSAxel Dörfler#define __swap_int16		__fssh_swap_int16
131a38a92c9SIngo Weinhold
132a38a92c9SIngo Weinhold
133a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
134a38a92c9SIngo Weinhold// #pragma mark - fssh_defs.h
135a38a92c9SIngo Weinhold
136d1456cc2SIngo Weinhold// 32/64 bitness
137318cb33fSIngo Weinhold#undef B_HAIKU_32_BIT
138318cb33fSIngo Weinhold#undef B_HAIKU_64_BIT
139d1456cc2SIngo Weinhold#ifdef FSSH_B_HAIKU_64_BIT
140d1456cc2SIngo Weinhold#	define B_HAIKU_64_BIT		FSSH_B_HAIKU_64_BIT
141d1456cc2SIngo Weinhold#endif
142d1456cc2SIngo Weinhold#ifdef FSSH_B_HAIKU_32_BIT
143d1456cc2SIngo Weinhold#	define B_HAIKU_32_BIT		FSSH_B_HAIKU_32_BIT
144d1456cc2SIngo Weinhold#endif
145d1456cc2SIngo Weinhold
146a38a92c9SIngo Weinhold// Limits
147a38a92c9SIngo Weinhold#define B_DEV_NAME_LENGTH	FSSH_B_DEV_NAME_LENGTH
148a38a92c9SIngo Weinhold#define B_FILE_NAME_LENGTH	FSSH_B_FILE_NAME_LENGTH
149a38a92c9SIngo Weinhold#define B_PATH_NAME_LENGTH	FSSH_B_PATH_NAME_LENGTH
150a38a92c9SIngo Weinhold#define B_ATTR_NAME_LENGTH	FSSH_B_ATTR_NAME_LENGTH
151a38a92c9SIngo Weinhold#define B_MIME_TYPE_LENGTH	FSSH_B_MIME_TYPE_LENGTH
152a38a92c9SIngo Weinhold#define B_MAX_SYMLINKS		FSSH_B_MAX_SYMLINKS
153a38a92c9SIngo Weinhold
154a38a92c9SIngo Weinhold// Open Modes
155a38a92c9SIngo Weinhold#define B_READ_ONLY			FSSH_B_READ_ONLY
156a38a92c9SIngo Weinhold#define B_WRITE_ONLY		FSSH_B_WRITE_ONLY
157a38a92c9SIngo Weinhold#define B_READ_WRITE		FSSH_B_READ_WRITE
158a38a92c9SIngo Weinhold
159a38a92c9SIngo Weinhold#define	B_FAIL_IF_EXISTS	FSSH_B_FAIL_IF_EXISTS
160a38a92c9SIngo Weinhold#define B_CREATE_FILE		FSSH_B_CREATE_FILE
161a38a92c9SIngo Weinhold#define B_ERASE_FILE		FSSH_B_ERASE_FILE
162a38a92c9SIngo Weinhold#define B_OPEN_AT_END		FSSH_B_OPEN_AT_END
163a38a92c9SIngo Weinhold
164a38a92c9SIngo Weinhold// Node Flavors
165a38a92c9SIngo Weinhold#define node_flavor			fssh_node_flavor
166a38a92c9SIngo Weinhold#define	B_FILE_NODE			FSSH_B_FILE_NODE
167a38a92c9SIngo Weinhold#define	B_SYMLINK_NODE		FSSH_B_SYMLINK_NODE
168a38a92c9SIngo Weinhold#define	B_DIRECTORY_NODE	FSSH_B_DIRECTORY_NODE
169a38a92c9SIngo Weinhold#define	B_ANY_NODE			FSSH_B_ANY_NODE
170a38a92c9SIngo Weinhold
171a4d337d5SIngo Weinhold#undef	offsetof
172a38a92c9SIngo Weinhold#define offsetof(type,member)	fssh_offsetof(type,member)
173a38a92c9SIngo Weinhold
174a38a92c9SIngo Weinhold#define min_c(a,b)				fssh_min_c(a,b)
175a38a92c9SIngo Weinhold#define max_c(a,b)				fssh_max_c(a,b)
176a38a92c9SIngo Weinhold
177a4d337d5SIngo Weinhold#undef	_PACKED
178a38a92c9SIngo Weinhold#define _PACKED	_FSSH_PACKED
179a38a92c9SIngo Weinhold
180a38a92c9SIngo Weinhold
181a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
182a38a92c9SIngo Weinhold// #pragma mark - fssh_dirent.h
183a38a92c9SIngo Weinhold
184a38a92c9SIngo Weinhold#define dirent		fssh_dirent
185a38a92c9SIngo Weinhold#define dirent_t	fssh_dirent_t
186a38a92c9SIngo Weinhold
187a38a92c9SIngo Weinhold#define DIR			fssh_DIR
188a38a92c9SIngo Weinhold
189a38a92c9SIngo Weinhold
190a38a92c9SIngo Weinhold
191a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
192a38a92c9SIngo Weinhold// #pragma mark - fssh_disk_device_defs.h
193a38a92c9SIngo Weinhold
194a38a92c9SIngo Weinhold#define partition_id	fssh_partition_id
195a38a92c9SIngo Weinhold#define disk_system_id	fssh_disk_system_id
196a38a92c9SIngo Weinhold#define disk_job_id		fssh_disk_job_id
197a38a92c9SIngo Weinhold
198a38a92c9SIngo Weinhold// partition flags
199a38a92c9SIngo Weinhold#define B_PARTITION_IS_DEVICE			FSSH_B_PARTITION_IS_DEVICE
200a38a92c9SIngo Weinhold#define B_PARTITION_FILE_SYSTEM			FSSH_B_PARTITION_FILE_SYSTEM
201a38a92c9SIngo Weinhold#define B_PARTITION_PARTITIONING_SYSTEM	FSSH_B_PARTITION_PARTITIONING_SYSTEM
202a38a92c9SIngo Weinhold#define B_PARTITION_READ_ONLY			FSSH_B_PARTITION_READ_ONLY
203a38a92c9SIngo Weinhold#define B_PARTITION_MOUNTED				FSSH_B_PARTITION_MOUNTED
204a38a92c9SIngo Weinhold#define B_PARTITION_BUSY				FSSH_B_PARTITION_BUSY
205a38a92c9SIngo Weinhold#define B_PARTITION_DESCENDANT_BUSY		FSSH_B_PARTITION_DESCENDANT_BUSY
206a38a92c9SIngo Weinhold
207a38a92c9SIngo Weinhold// partition statuses
208a38a92c9SIngo Weinhold#define B_PARTITION_VALID			FSSH_B_PARTITION_VALID
209a38a92c9SIngo Weinhold#define B_PARTITION_CORRUPT			FSSH_B_PARTITION_CORRUPT
210a38a92c9SIngo Weinhold#define B_PARTITION_UNRECOGNIZED	FSSH_B_PARTITION_UNRECOGNIZED
211a38a92c9SIngo Weinhold#define B_PARTITION_UNINITIALIZED	FSSH_B_PARTITION_UNINITIALIZED
212a38a92c9SIngo Weinhold
213a38a92c9SIngo Weinhold// partition change flags
214a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_OFFSET				FSSH_B_PARTITION_CHANGED_OFFSET
215a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_SIZE				FSSH_B_PARTITION_CHANGED_SIZE
216a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_CONTENT_SIZE		FSSH_B_PARTITION_CHANGED_CONTENT_SIZE
217a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_BLOCK_SIZE			FSSH_B_PARTITION_CHANGED_BLOCK_SIZE
218a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_STATUS				FSSH_B_PARTITION_CHANGED_STATUS
219a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_FLAGS				FSSH_B_PARTITION_CHANGED_FLAGS
220a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_VOLUME				FSSH_B_PARTITION_CHANGED_VOLUME
221a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_NAME				FSSH_B_PARTITION_CHANGED_NAME
222a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_CONTENT_NAME		FSSH_B_PARTITION_CHANGED_CONTENT_NAME
223a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_TYPE				FSSH_B_PARTITION_CHANGED_TYPE
224a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_CONTENT_TYPE		FSSH_B_PARTITION_CHANGED_CONTENT_TYPE
225a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_PARAMETERS			FSSH_B_PARTITION_CHANGED_PARAMETERS
226a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_CONTENT_PARAMETERS	FSSH_B_PARTITION_CHANGED_CONTENT_PARAMETERS
227a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_CHILDREN			FSSH_B_PARTITION_CHANGED_CHILDREN
228a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_DESCENDANTS			FSSH_B_PARTITION_CHANGED_DESCENDANTS
229a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_DEFRAGMENTATION		FSSH_B_PARTITION_CHANGED_DEFRAGMENTATION
230a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_CHECK				FSSH_B_PARTITION_CHANGED_CHECK
231a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_REPAIR				FSSH_B_PARTITION_CHANGED_REPAIR
232a38a92c9SIngo Weinhold#define B_PARTITION_CHANGED_INITIALIZATION		FSSH_B_PARTITION_CHANGED_INITIALIZATION
233a38a92c9SIngo Weinhold
234a38a92c9SIngo Weinhold// disk device flags
235a38a92c9SIngo Weinhold#define B_DISK_DEVICE_REMOVABLE		FSSH_B_DISK_DEVICE_REMOVABLE
236a38a92c9SIngo Weinhold#define B_DISK_DEVICE_HAS_MEDIA		FSSH_B_DISK_DEVICE_HAS_MEDIA
237a38a92c9SIngo Weinhold#define B_DISK_DEVICE_READ_ONLY		FSSH_B_DISK_DEVICE_READ_ONLY
238a38a92c9SIngo Weinhold#define B_DISK_DEVICE_WRITE_ONCE	FSSH_B_DISK_DEVICE_WRITE_ONCE
239a38a92c9SIngo Weinhold
240a38a92c9SIngo Weinhold// disk system flags
241a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_IS_FILE_SYSTEM	FSSH_B_DISK_SYSTEM_IS_FILE_SYSTEM
242a38a92c9SIngo Weinhold
243a38a92c9SIngo Weinhold// flags common for both file and partitioning systems
244a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_CHECKING						FSSH_B_DISK_SYSTEM_SUPPORTS_CHECKING
245a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_REPAIRING					FSSH_B_DISK_SYSTEM_SUPPORTS_REPAIRING
246a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_RESIZING						FSSH_B_DISK_SYSTEM_SUPPORTS_RESIZING
247a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_MOVING						FSSH_B_DISK_SYSTEM_SUPPORTS_MOVING
248a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_NAME			FSSH_B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_NAME
249a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_PARAMETERS	FSSH_B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_PARAMETERS
25076a8ec23SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_INITIALIZING					FSSH_B_DISK_SYSTEM_SUPPORTS_INITIALIZING
25176a8ec23SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_CONTENT_NAME					FSSH_B_DISK_SYSTEM_SUPPORTS_CONTENT_NAME
252a38a92c9SIngo Weinhold
253a38a92c9SIngo Weinhold// file system specific flags
254a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_DEFRAGMENTING							FSSH_B_DISK_SYSTEM_SUPPORTS_DEFRAGMENTING
255a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_DEFRAGMENTING_WHILE_MOUNTED				FSSH_B_DISK_SYSTEM_SUPPORTS_DEFRAGMENTING_WHILE_MOUNTED
256a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_CHECKING_WHILE_MOUNTED					FSSH_B_DISK_SYSTEM_SUPPORTS_CHECKING_WHILE_MOUNTED
257a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_REPAIRING_WHILE_MOUNTED					FSSH_B_DISK_SYSTEM_SUPPORTS_REPAIRING_WHILE_MOUNTED
258a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_RESIZING_WHILE_MOUNTED					FSSH_B_DISK_SYSTEM_SUPPORTS_RESIZING_WHILE_MOUNTED
259a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_MOVING_WHILE_MOUNTED						FSSH_B_DISK_SYSTEM_SUPPORTS_MOVING_WHILE_MOUNTED
260a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_NAME_WHILE_MOUNTED		FSSH_B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_NAME_WHILE_MOUNTED
261a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_PARAMETERS_WHILE_MOUNTED	FSSH_B_DISK_SYSTEM_SUPPORTS_SETTING_CONTENT_PARAMETERS_WHILE_MOUNTED
262057f999dSAxel Dörfler#define B_DISK_SYSTEM_SUPPORTS_WRITING									FSSH_B_DISK_SYSTEM_SUPPORTS_WRITING
263a38a92c9SIngo Weinhold
264a38a92c9SIngo Weinhold// partitioning system specific flags
265a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_RESIZING_CHILD		FSSH_B_DISK_SYSTEM_SUPPORTS_RESIZING_CHILD
266a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_MOVING_CHILD			FSSH_B_DISK_SYSTEM_SUPPORTS_MOVING_CHILD
267a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_SETTING_NAME			FSSH_B_DISK_SYSTEM_SUPPORTS_SETTING_NAME
268a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_SETTING_TYPE			FSSH_B_DISK_SYSTEM_SUPPORTS_SETTING_TYPE
269a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_SETTING_PARAMETERS	FSSH_B_DISK_SYSTEM_SUPPORTS_SETTING_PARAMETERS
270a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_CREATING_CHILD		FSSH_B_DISK_SYSTEM_SUPPORTS_CREATING_CHILD
271a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_DELETING_CHILD		FSSH_B_DISK_SYSTEM_SUPPORTS_DELETING_CHILD
27276a8ec23SIngo Weinhold#define B_DISK_SYSTEM_SUPPORTS_NAME					FSSH_B_DISK_SYSTEM_SUPPORTS_NAME
273a38a92c9SIngo Weinhold
274a38a92c9SIngo Weinhold// disk device job types
275a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_BAD_TYPE				FSSH_B_DISK_DEVICE_JOB_BAD_TYPE
276a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_DEFRAGMENT			FSSH_B_DISK_DEVICE_JOB_DEFRAGMENT
277a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_REPAIR				FSSH_B_DISK_DEVICE_JOB_REPAIR
278a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_RESIZE				FSSH_B_DISK_DEVICE_JOB_RESIZE
279a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_MOVE					FSSH_B_DISK_DEVICE_JOB_MOVE
280a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SET_NAME				FSSH_B_DISK_DEVICE_JOB_SET_NAME
281a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SET_CONTENT_NAME		FSSH_B_DISK_DEVICE_JOB_SET_CONTENT_NAME
282a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SET_TYPE				FSSH_B_DISK_DEVICE_JOB_SET_TYPE
283a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SET_PARMETERS			FSSH_B_DISK_DEVICE_JOB_SET_PARMETERS
284a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SET_CONTENT_PARMETERS	FSSH_B_DISK_DEVICE_JOB_SET_CONTENT_PARMETERS
285a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_INITIALIZE			FSSH_B_DISK_DEVICE_JOB_INITIALIZE
286a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_UNINITIALIZE			FSSH_B_DISK_DEVICE_JOB_UNINITIALIZE
287a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_CREATE				FSSH_B_DISK_DEVICE_JOB_CREATE
288a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_DELETE				FSSH_B_DISK_DEVICE_JOB_DELETE
289a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SCAN					FSSH_B_DISK_DEVICE_JOB_SCAN
290a38a92c9SIngo Weinhold
291a38a92c9SIngo Weinhold// disk device job statuses
292a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_UNINITIALIZED	FSSH_B_DISK_DEVICE_JOB_UNINITIALIZED
293a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SCHEDULED		FSSH_B_DISK_DEVICE_JOB_SCHEDULED
294a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_IN_PROGRESS	FSSH_B_DISK_DEVICE_JOB_IN_PROGRESS
295a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_SUCCEEDED		FSSH_B_DISK_DEVICE_JOB_SUCCEEDED
296a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_FAILED		FSSH_B_DISK_DEVICE_JOB_FAILED
297a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_CANCELED		FSSH_B_DISK_DEVICE_JOB_CANCELED
298a38a92c9SIngo Weinhold
299a38a92c9SIngo Weinhold#define disk_device_job_progress_info	fssh_disk_device_job_progress_info
300a38a92c9SIngo Weinhold
301a38a92c9SIngo Weinhold// disk device job interrupt properties
302a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_CAN_CANCEL		FSSH_B_DISK_DEVICE_JOB_CAN_CANCEL
303a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_STOP_ON_CANCEL	FSSH_B_DISK_DEVICE_JOB_STOP_ON_CANCEL
304a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_REVERSE_ON_CANCEL	FSSH_B_DISK_DEVICE_JOB_REVERSE_ON_CANCEL
305a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_CAN_PAUSE			FSSH_B_DISK_DEVICE_JOB_CAN_PAUSE
306a38a92c9SIngo Weinhold
307a38a92c9SIngo Weinhold// string length constants, all of which include the NULL terminator
308a38a92c9SIngo Weinhold#define B_DISK_DEVICE_TYPE_LENGTH	FSSH_B_DISK_DEVICE_TYPE_LENGTH
309a38a92c9SIngo Weinhold#define B_DISK_DEVICE_NAME_LENGTH	FSSH_B_DISK_DEVICE_NAME_LENGTH
310a38a92c9SIngo Weinhold#define B_DISK_SYSTEM_NAME_LENGTH	FSSH_B_DISK_SYSTEM_NAME_LENGTH
311a38a92c9SIngo Weinhold
312a38a92c9SIngo Weinhold// max size of parameter string buffers, including NULL terminator
313a38a92c9SIngo Weinhold#define B_DISK_DEVICE_MAX_PARAMETER_SIZE	FSSH_B_DISK_DEVICE_MAX_PARAMETER_SIZE
314a38a92c9SIngo Weinhold
315a38a92c9SIngo Weinhold
316a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
317a38a92c9SIngo Weinhold// #pragma mark - fssh_disk_device_manager.h
318a38a92c9SIngo Weinhold
319a38a92c9SIngo Weinhold#define partition_data				fssh_partition_data
320a38a92c9SIngo Weinhold#define disk_device_data			fssh_disk_device_data
321a38a92c9SIngo Weinhold#define partitionable_space_data	fssh_partitionable_space_data
322a38a92c9SIngo Weinhold
323a38a92c9SIngo Weinhold// operations on partitions
324a38a92c9SIngo Weinhold#define B_PARTITION_DEFRAGMENT				FSSH_B_PARTITION_DEFRAGMENT
325a38a92c9SIngo Weinhold#define B_PARTITION_REPAIR					FSSH_B_PARTITION_REPAIR
326a38a92c9SIngo Weinhold#define B_PARTITION_RESIZE					FSSH_B_PARTITION_RESIZE
327a38a92c9SIngo Weinhold#define B_PARTITION_RESIZE_CHILD			FSSH_B_PARTITION_RESIZE_CHILD
328a38a92c9SIngo Weinhold#define B_PARTITION_MOVE					FSSH_B_PARTITION_MOVE
329a38a92c9SIngo Weinhold#define B_PARTITION_MOVE_CHILD				FSSH_B_PARTITION_MOVE_CHILD
330a38a92c9SIngo Weinhold#define B_PARTITION_SET_NAME				FSSH_B_PARTITION_SET_NAME
331a38a92c9SIngo Weinhold#define B_PARTITION_SET_CONTENT_NAME		FSSH_B_PARTITION_SET_CONTENT_NAME
332a38a92c9SIngo Weinhold#define B_PARTITION_SET_TYPE				FSSH_B_PARTITION_SET_TYPE
333a38a92c9SIngo Weinhold#define B_PARTITION_SET_PARAMETERS			FSSH_B_PARTITION_SET_PARAMETERS
334a38a92c9SIngo Weinhold#define B_PARTITION_SET_CONTENT_PARAMETERS	FSSH_B_PARTITION_SET_CONTENT_PARAMETERS
335a38a92c9SIngo Weinhold#define B_PARTITION_INITIALIZE				FSSH_B_PARTITION_INITIALIZE
336a38a92c9SIngo Weinhold#define B_PARTITION_CREATE_CHILD			FSSH_B_PARTITION_CREATE_CHILD
337a38a92c9SIngo Weinhold#define B_PARTITION_DELETE_CHILD			FSSH_B_PARTITION_DELETE_CHILD
338a38a92c9SIngo Weinhold
339a38a92c9SIngo Weinhold// disk device job cancel status
340a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_CONTINUE	FSSH_B_DISK_DEVICE_JOB_CONTINUE
341a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_CANCEL	FSSH_B_DISK_DEVICE_JOB_CANCEL
342a38a92c9SIngo Weinhold#define B_DISK_DEVICE_JOB_REVERSE	FSSH_B_DISK_DEVICE_JOB_REVERSE
343a38a92c9SIngo Weinhold
344a38a92c9SIngo Weinhold// disk device locking
345a38a92c9SIngo Weinhold#define write_lock_disk_device		fssh_write_lock_disk_device
346a38a92c9SIngo Weinhold#define write_unlock_disk_device	fssh_write_unlock_disk_device
347a38a92c9SIngo Weinhold#define read_lock_disk_device		fssh_read_lock_disk_device
348a38a92c9SIngo Weinhold#define read_unlock_disk_device		fssh_read_unlock_disk_device
349a38a92c9SIngo Weinhold
350a38a92c9SIngo Weinhold// getting disk devices/partitions by path
351a38a92c9SIngo Weinhold#define find_disk_device	fssh_find_disk_device
352a38a92c9SIngo Weinhold#define find_partition		fssh_find_partition
353a38a92c9SIngo Weinhold
354a38a92c9SIngo Weinhold// disk device/partition read access
355a38a92c9SIngo Weinhold#define get_disk_device			fssh_get_disk_device
356a38a92c9SIngo Weinhold#define get_partition			fssh_get_partition
357a38a92c9SIngo Weinhold#define get_parent_partition	fssh_get_parent_partition
358a38a92c9SIngo Weinhold#define get_child_partition		fssh_get_child_partition
359a38a92c9SIngo Weinhold
360a38a92c9SIngo Weinhold// partition write access
361a38a92c9SIngo Weinhold#define create_child_partition	fssh_create_child_partition
362a38a92c9SIngo Weinhold#define delete_partition		fssh_delete_partition
363a38a92c9SIngo Weinhold#define partition_modified		fssh_partition_modified
364a38a92c9SIngo Weinhold
3658c8f8c84SIngo Weinhold#define scan_partition			fssh_scan_partition
3668c8f8c84SIngo Weinhold
367a38a92c9SIngo Weinhold// disk systems
368a38a92c9SIngo Weinhold#define find_disk_system		fssh_find_disk_system
369a38a92c9SIngo Weinhold
370a38a92c9SIngo Weinhold// jobs
371a38a92c9SIngo Weinhold#define update_disk_device_job_progress				fssh_update_disk_device_job_progress
372a38a92c9SIngo Weinhold#define update_disk_device_job_extra_progress		fssh_update_disk_device_job_extra_progress
373a38a92c9SIngo Weinhold#define set_disk_device_job_error_message			fssh_set_disk_device_job_error_message
374a38a92c9SIngo Weinhold#define update_disk_device_job_interrupt_properties	fssh_update_disk_device_job_interrupt_properties
375a38a92c9SIngo Weinhold
376a38a92c9SIngo Weinhold
377eedc1553SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
378eedc1553SIngo Weinhold// #pragma mark - fssh_driver_settings.h
379eedc1553SIngo Weinhold
380eedc1553SIngo Weinhold#define driver_parameter	fssh_driver_parameter
381eedc1553SIngo Weinhold#define driver_settings		fssh_driver_settings
382eedc1553SIngo Weinhold
383eedc1553SIngo Weinhold#define load_driver_settings			fssh_load_driver_settings
384eedc1553SIngo Weinhold#define unload_driver_settings			fssh_unload_driver_settings
385eedc1553SIngo Weinhold#define parse_driver_settings_string	fssh_parse_driver_settings_string
386eedc1553SIngo Weinhold#define get_driver_settings_string		fssh_get_driver_settings_string
387eedc1553SIngo Weinhold#define delete_driver_settings			fssh_delete_driver_settings
388eedc1553SIngo Weinhold#define get_driver_parameter			fssh_get_driver_parameter
389eedc1553SIngo Weinhold#define get_driver_boolean_parameter	fssh_get_driver_boolean_parameter
390eedc1553SIngo Weinhold#define get_driver_settings				fssh_get_driver_settings
391eedc1553SIngo Weinhold
392eedc1553SIngo Weinhold#define B_SAFEMODE_DRIVER_SETTINGS	FSSH_B_SAFEMODE_DRIVER_SETTINGS
393eedc1553SIngo Weinhold#define B_SAFEMODE_SAFE_MODE		FSSH_B_SAFEMODE_SAFE_MODE
394eedc1553SIngo Weinhold
395a38a92c9SIngo Weinhold
396a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
397a38a92c9SIngo Weinhold// #pragma mark - fssh_drivers.h
398a38a92c9SIngo Weinhold
399a38a92c9SIngo Weinhold#define device_open_hook		fssh_device_open_hook
400a38a92c9SIngo Weinhold#define device_close_hook		fssh_device_close_hook
401a38a92c9SIngo Weinhold#define device_free_hook		fssh_device_free_hook
402a38a92c9SIngo Weinhold#define device_control_hook		fssh_device_control_hook
403a38a92c9SIngo Weinhold#define device_read_hook		fssh_device_read_hook
404a38a92c9SIngo Weinhold#define device_write_hook		fssh_device_write_hook
405a38a92c9SIngo Weinhold#define device_select_hook		fssh_device_select_hook
406a38a92c9SIngo Weinhold#define device_deselect_hook	fssh_device_deselect_hook
407a38a92c9SIngo Weinhold#define device_read_pages_hook	fssh_device_read_pages_hook
408a38a92c9SIngo Weinhold#define device_write_pages_hook	fssh_device_write_pages_hook
409a38a92c9SIngo Weinhold
410a38a92c9SIngo Weinhold#define B_CUR_DRIVER_API_VERSION	FSSH_B_CUR_DRIVER_API_VERSION
411a38a92c9SIngo Weinhold
412a38a92c9SIngo Weinhold#define device_hooks	fssh_device_hooks
413a38a92c9SIngo Weinhold
414a38a92c9SIngo Weinhold#define init_hardware	fssh_init_hardware
415a38a92c9SIngo Weinhold#define publish_devices	fssh_publish_devices
416a38a92c9SIngo Weinhold#define find_device		fssh_find_device
417a38a92c9SIngo Weinhold#define init_driver		fssh_init_driver
418a38a92c9SIngo Weinhold#define uninit_driver	fssh_uninit_driver
419a38a92c9SIngo Weinhold
420a38a92c9SIngo Weinhold#define api_version		fssh_api_version
421a38a92c9SIngo Weinhold
422a38a92c9SIngo Weinhold#define B_GET_DEVICE_SIZE			FSSH_B_GET_DEVICE_SIZE
423a38a92c9SIngo Weinhold#define B_SET_DEVICE_SIZE			FSSH_B_SET_DEVICE_SIZE
424a38a92c9SIngo Weinhold#define B_SET_NONBLOCKING_IO		FSSH_B_SET_NONBLOCKING_IO
425a38a92c9SIngo Weinhold#define B_SET_BLOCKING_IO			FSSH_B_SET_BLOCKING_IO
426a38a92c9SIngo Weinhold#define B_GET_READ_STATUS			FSSH_B_GET_READ_STATUS
427a38a92c9SIngo Weinhold#define B_GET_WRITE_STATUS			FSSH_B_GET_WRITE_STATUS
428a38a92c9SIngo Weinhold#define B_GET_GEOMETRY				FSSH_B_GET_GEOMETRY
429a38a92c9SIngo Weinhold#define B_GET_DRIVER_FOR_DEVICE		FSSH_B_GET_DRIVER_FOR_DEVICE
430a38a92c9SIngo Weinhold#define B_GET_PARTITION_INFO		FSSH_B_GET_PARTITION_INFO
431a38a92c9SIngo Weinhold#define B_SET_PARTITION				FSSH_B_SET_PARTITION
432a38a92c9SIngo Weinhold#define B_FORMAT_DEVICE				FSSH_B_FORMAT_DEVICE
433a38a92c9SIngo Weinhold#define B_EJECT_DEVICE				FSSH_B_EJECT_DEVICE
434a38a92c9SIngo Weinhold#define B_GET_ICON					FSSH_B_GET_ICON
435a38a92c9SIngo Weinhold#define B_GET_BIOS_GEOMETRY			FSSH_B_GET_BIOS_GEOMETRY
436a38a92c9SIngo Weinhold#define B_GET_MEDIA_STATUS			FSSH_B_GET_MEDIA_STATUS
437a38a92c9SIngo Weinhold#define B_LOAD_MEDIA				FSSH_B_LOAD_MEDIA
438a38a92c9SIngo Weinhold#define B_GET_BIOS_DRIVE_ID			FSSH_B_GET_BIOS_DRIVE_ID
439a38a92c9SIngo Weinhold#define B_SET_UNINTERRUPTABLE_IO	FSSH_B_SET_UNINTERRUPTABLE_IO
440a38a92c9SIngo Weinhold#define B_SET_INTERRUPTABLE_IO		FSSH_B_SET_INTERRUPTABLE_IO
441a38a92c9SIngo Weinhold#define B_FLUSH_DRIVE_CACHE			FSSH_B_FLUSH_DRIVE_CACHE
442a38a92c9SIngo Weinhold#define B_GET_PATH_FOR_DEVICE		FSSH_B_GET_PATH_FOR_DEVICE
44329a84508SAxel Dörfler#define B_GET_ICON_NAME				FSSH_B_GET_ICON_NAME
44429a84508SAxel Dörfler#define B_GET_VECTOR_ICON			FSSH_B_GET_VECTOR_ICON
44529a84508SAxel Dörfler#define B_GET_DEVICE_NAME			FSSH_B_GET_DEVICE_NAME
44629a84508SAxel Dörfler#define B_TRIM_DEVICE				FSSH_B_TRIM_DEVICE
447a38a92c9SIngo Weinhold#define B_GET_NEXT_OPEN_DEVICE		FSSH_B_GET_NEXT_OPEN_DEVICE
448a38a92c9SIngo Weinhold#define B_ADD_FIXED_DRIVER			FSSH_B_ADD_FIXED_DRIVER
449a38a92c9SIngo Weinhold#define B_REMOVE_FIXED_DRIVER		FSSH_B_REMOVE_FIXED_DRIVER
450a38a92c9SIngo Weinhold#define B_AUDIO_DRIVER_BASE			FSSH_B_AUDIO_DRIVER_BASE
451a38a92c9SIngo Weinhold#define B_MIDI_DRIVER_BASE			FSSH_B_MIDI_DRIVER_BASE
452a38a92c9SIngo Weinhold#define B_JOYSTICK_DRIVER_BASE		FSSH_B_JOYSTICK_DRIVER_BASE
453a38a92c9SIngo Weinhold#define B_GRAPHIC_DRIVER_BASE		FSSH_B_GRAPHIC_DRIVER_BASE
454a38a92c9SIngo Weinhold#define B_DEVICE_OP_CODES_END		FSSH_B_DEVICE_OP_CODES_END
455a38a92c9SIngo Weinhold
456a38a92c9SIngo Weinhold#define device_geometry	fssh_device_geometry
457a38a92c9SIngo Weinhold
458a38a92c9SIngo Weinhold#define B_DISK		FSSH_B_DISK
459a38a92c9SIngo Weinhold#define B_TAPE		FSSH_B_TAPE
460a38a92c9SIngo Weinhold#define B_PRINTER	FSSH_B_PRINTER
461a38a92c9SIngo Weinhold#define B_CPU		FSSH_B_CPU
462a38a92c9SIngo Weinhold#define B_WORM		FSSH_B_WORM
463a38a92c9SIngo Weinhold#define B_CD		FSSH_B_CD
464a38a92c9SIngo Weinhold#define B_SCANNER	FSSH_B_SCANNER
465a38a92c9SIngo Weinhold#define B_OPTICAL	FSSH_B_OPTICAL
466a38a92c9SIngo Weinhold#define B_JUKEBOX	FSSH_B_JUKEBOX
467a38a92c9SIngo Weinhold#define B_NETWORK	FSSH_B_NETWORK
468a38a92c9SIngo Weinhold
469a38a92c9SIngo Weinhold
470a38a92c9SIngo Weinhold#define partition_info			fssh_partition_info
471a38a92c9SIngo Weinhold#define driver_path				fssh_driver_path
472a38a92c9SIngo Weinhold#define open_device_iterator	fssh_open_device_iterator
473a38a92c9SIngo Weinhold#define device_icon				fssh_device_icon
47429a84508SAxel Dörfler#define fs_trim_data			fssh_fs_trim_data
475a38a92c9SIngo Weinhold
476a38a92c9SIngo Weinhold
477a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
478a38a92c9SIngo Weinhold// #pragma mark - fssh_errors.h
479a38a92c9SIngo Weinhold
480a38a92c9SIngo Weinhold/* Error baselines */
481a38a92c9SIngo Weinhold#define B_GENERAL_ERROR_BASE		FSSH_B_GENERAL_ERROR_BASE
482a38a92c9SIngo Weinhold#define B_OS_ERROR_BASE				FSSH_B_OS_ERROR_BASE
483a38a92c9SIngo Weinhold#define B_APP_ERROR_BASE			FSSH_B_APP_ERROR_BASE
484a38a92c9SIngo Weinhold#define B_INTERFACE_ERROR_BASE		FSSH_B_INTERFACE_ERROR_BASE
485a38a92c9SIngo Weinhold#define B_MEDIA_ERROR_BASE			FSSH_B_MEDIA_ERROR_BASE
486a38a92c9SIngo Weinhold#define B_TRANSLATION_ERROR_BASE	FSSH_B_TRANSLATION_ERROR_BASE
487a38a92c9SIngo Weinhold#define B_MIDI_ERROR_BASE			FSSH_B_MIDI_ERROR_BASE
488a38a92c9SIngo Weinhold#define B_STORAGE_ERROR_BASE		FSSH_B_STORAGE_ERROR_BASE
489a38a92c9SIngo Weinhold#define B_POSIX_ERROR_BASE			FSSH_B_POSIX_ERROR_BASE
490a38a92c9SIngo Weinhold#define B_MAIL_ERROR_BASE			FSSH_B_MAIL_ERROR_BASE
491a38a92c9SIngo Weinhold#define B_PRINT_ERROR_BASE			FSSH_B_PRINT_ERROR_BASE
492a38a92c9SIngo Weinhold#define B_DEVICE_ERROR_BASE			FSSH_B_DEVICE_ERROR_BASE
493a38a92c9SIngo Weinhold
494a38a92c9SIngo Weinhold/* Developer-defined errors start at (B_ERRORS_END+1) */
495a38a92c9SIngo Weinhold#define B_ERRORS_END				FSSH_B_ERRORS_END
496a38a92c9SIngo Weinhold
497a38a92c9SIngo Weinhold/* General Errors */
498a38a92c9SIngo Weinhold#define B_NO_MEMORY			FSSH_B_NO_MEMORY
499a38a92c9SIngo Weinhold#define B_IO_ERROR			FSSH_B_IO_ERROR
500a38a92c9SIngo Weinhold#define B_PERMISSION_DENIED	FSSH_B_PERMISSION_DENIED
501a38a92c9SIngo Weinhold#define B_BAD_INDEX			FSSH_B_BAD_INDEX
502a38a92c9SIngo Weinhold#define B_BAD_TYPE			FSSH_B_BAD_TYPE
503a38a92c9SIngo Weinhold#define B_BAD_VALUE			FSSH_B_BAD_VALUE
504a38a92c9SIngo Weinhold#define B_MISMATCHED_VALUES	FSSH_B_MISMATCHED_VALUES
505a38a92c9SIngo Weinhold#define B_NAME_NOT_FOUND	FSSH_B_NAME_NOT_FOUND
506a38a92c9SIngo Weinhold#define B_NAME_IN_USE		FSSH_B_NAME_IN_USE
507a38a92c9SIngo Weinhold#define B_TIMED_OUT			FSSH_B_TIMED_OUT
508a38a92c9SIngo Weinhold#define B_INTERRUPTED		FSSH_B_INTERRUPTED
509a38a92c9SIngo Weinhold#define B_WOULD_BLOCK		FSSH_B_WOULD_BLOCK
510a38a92c9SIngo Weinhold#define B_CANCELED			FSSH_B_CANCELED
511a38a92c9SIngo Weinhold#define B_NO_INIT			FSSH_B_NO_INIT
512a38a92c9SIngo Weinhold#define B_BUSY				FSSH_B_BUSY
513a38a92c9SIngo Weinhold#define B_NOT_ALLOWED		FSSH_B_NOT_ALLOWED
514a38a92c9SIngo Weinhold#define B_BAD_DATA			FSSH_B_BAD_DATA
515a38a92c9SIngo Weinhold#define B_DONT_DO_THAT		FSSH_B_DONT_DO_THAT
516a38a92c9SIngo Weinhold
517a38a92c9SIngo Weinhold#define B_ERROR				FSSH_B_ERROR
518a38a92c9SIngo Weinhold#define B_OK				FSSH_B_OK
519a38a92c9SIngo Weinhold#define B_NO_ERROR			FSSH_B_NO_ERROR
520a38a92c9SIngo Weinhold
521a38a92c9SIngo Weinhold/* Kernel Kit Errors */
522a38a92c9SIngo Weinhold#define B_BAD_SEM_ID		FSSH_B_BAD_SEM_ID
523a38a92c9SIngo Weinhold#define B_NO_MORE_SEMS		FSSH_B_NO_MORE_SEMS
524a38a92c9SIngo Weinhold
525a38a92c9SIngo Weinhold#define B_BAD_THREAD_ID		FSSH_B_BAD_THREAD_ID
526a38a92c9SIngo Weinhold#define B_NO_MORE_THREADS	FSSH_B_NO_MORE_THREADS
527a38a92c9SIngo Weinhold#define B_BAD_THREAD_STATE	FSSH_B_BAD_THREAD_STATE
528a38a92c9SIngo Weinhold#define B_BAD_TEAM_ID		FSSH_B_BAD_TEAM_ID
529a38a92c9SIngo Weinhold#define B_NO_MORE_TEAMS		FSSH_B_NO_MORE_TEAMS
530a38a92c9SIngo Weinhold
531a38a92c9SIngo Weinhold#define B_BAD_PORT_ID		FSSH_B_BAD_PORT_ID
532a38a92c9SIngo Weinhold#define B_NO_MORE_PORTS		FSSH_B_NO_MORE_PORTS
533a38a92c9SIngo Weinhold
534a38a92c9SIngo Weinhold#define B_BAD_IMAGE_ID		FSSH_B_BAD_IMAGE_ID
535a38a92c9SIngo Weinhold#define B_BAD_ADDRESS		FSSH_B_BAD_ADDRESS
536a38a92c9SIngo Weinhold#define B_NOT_AN_EXECUTABLE	FSSH_B_NOT_AN_EXECUTABLE
537a38a92c9SIngo Weinhold#define B_MISSING_LIBRARY	FSSH_B_MISSING_LIBRARY
538a38a92c9SIngo Weinhold#define B_MISSING_SYMBOL	FSSH_B_MISSING_SYMBOL
539a38a92c9SIngo Weinhold
540a38a92c9SIngo Weinhold#define B_DEBUGGER_ALREADY_INSTALLED	FSSH_B_DEBUGGER_ALREADY_INSTALLED
541a38a92c9SIngo Weinhold
542a38a92c9SIngo Weinhold/* Application Kit Errors */
543a38a92c9SIngo Weinhold#define B_BAD_REPLY							FSSH_B_BAD_REPLY
544a38a92c9SIngo Weinhold#define B_DUPLICATE_REPLY					FSSH_B_DUPLICATE_REPLY
545a38a92c9SIngo Weinhold#define B_MESSAGE_TO_SELF					FSSH_B_MESSAGE_TO_SELF
546a38a92c9SIngo Weinhold#define B_BAD_HANDLER						FSSH_B_BAD_HANDLER
547a38a92c9SIngo Weinhold#define B_ALREADY_RUNNING					FSSH_B_ALREADY_RUNNING
548a38a92c9SIngo Weinhold#define B_LAUNCH_FAILED						FSSH_B_LAUNCH_FAILED
549a38a92c9SIngo Weinhold#define B_AMBIGUOUS_APP_LAUNCH				FSSH_B_AMBIGUOUS_APP_LAUNCH
550a38a92c9SIngo Weinhold#define B_UNKNOWN_MIME_TYPE					FSSH_B_UNKNOWN_MIME_TYPE
551a38a92c9SIngo Weinhold#define B_BAD_SCRIPT_SYNTAX					FSSH_B_BAD_SCRIPT_SYNTAX
552a38a92c9SIngo Weinhold#define B_LAUNCH_FAILED_NO_RESOLVE_LINK		FSSH_B_LAUNCH_FAILED_NO_RESOLVE_LINK
553a38a92c9SIngo Weinhold#define B_LAUNCH_FAILED_EXECUTABLE			FSSH_B_LAUNCH_FAILED_EXECUTABLE
554a38a92c9SIngo Weinhold#define B_LAUNCH_FAILED_APP_NOT_FOUND		FSSH_B_LAUNCH_FAILED_APP_NOT_FOUND
555a38a92c9SIngo Weinhold#define B_LAUNCH_FAILED_APP_IN_TRASH		FSSH_B_LAUNCH_FAILED_APP_IN_TRASH
556a38a92c9SIngo Weinhold#define B_LAUNCH_FAILED_NO_PREFERRED_APP	FSSH_B_LAUNCH_FAILED_NO_PREFERRED_APP
557a38a92c9SIngo Weinhold#define B_LAUNCH_FAILED_FILES_APP_NOT_FOUND	FSSH_B_LAUNCH_FAILED_FILES_APP_NOT_FOUND
558a38a92c9SIngo Weinhold#define B_BAD_MIME_SNIFFER_RULE				FSSH_B_BAD_MIME_SNIFFER_RULE
559a38a92c9SIngo Weinhold#define B_NOT_A_MESSAGE						FSSH_B_NOT_A_MESSAGE
560a38a92c9SIngo Weinhold#define B_SHUTDOWN_CANCELLED				FSSH_B_SHUTDOWN_CANCELLED
561a38a92c9SIngo Weinhold#define B_SHUTTING_DOWN						FSSH_B_SHUTTING_DOWN
562a38a92c9SIngo Weinhold
563a38a92c9SIngo Weinhold/* Storage Kit/File System Errors */
564a38a92c9SIngo Weinhold#define B_FILE_ERROR			FSSH_B_FILE_ERROR
565a38a92c9SIngo Weinhold#define B_FILE_NOT_FOUND		FSSH_B_FILE_NOT_FOUND
566a38a92c9SIngo Weinhold#define B_FILE_EXISTS			FSSH_B_FILE_EXISTS
567a38a92c9SIngo Weinhold#define B_ENTRY_NOT_FOUND		FSSH_B_ENTRY_NOT_FOUND
568a38a92c9SIngo Weinhold#define B_NAME_TOO_LONG			FSSH_B_NAME_TOO_LONG
569a38a92c9SIngo Weinhold#define B_NOT_A_DIRECTORY		FSSH_B_NOT_A_DIRECTORY
570a38a92c9SIngo Weinhold#define B_DIRECTORY_NOT_EMPTY	FSSH_B_DIRECTORY_NOT_EMPTY
571a38a92c9SIngo Weinhold#define B_DEVICE_FULL			FSSH_B_DEVICE_FULL
572a38a92c9SIngo Weinhold#define B_READ_ONLY_DEVICE		FSSH_B_READ_ONLY_DEVICE
573a38a92c9SIngo Weinhold#define B_IS_A_DIRECTORY		FSSH_B_IS_A_DIRECTORY
574a38a92c9SIngo Weinhold#define B_NO_MORE_FDS			FSSH_B_NO_MORE_FDS
575a38a92c9SIngo Weinhold#define B_CROSS_DEVICE_LINK		FSSH_B_CROSS_DEVICE_LINK
576a38a92c9SIngo Weinhold#define B_LINK_LIMIT			FSSH_B_LINK_LIMIT
577a38a92c9SIngo Weinhold#define B_BUSTED_PIPE			FSSH_B_BUSTED_PIPE
578a38a92c9SIngo Weinhold#define B_UNSUPPORTED			FSSH_B_UNSUPPORTED
579a38a92c9SIngo Weinhold#define B_PARTITION_TOO_SMALL	FSSH_B_PARTITION_TOO_SMALL
580dec78bb2SIngo Weinhold#define B_PARTIAL_READ			FSSH_B_PARTIAL_READ
581dec78bb2SIngo Weinhold#define B_PARTIAL_WRITE			FSSH_B_PARTIAL_WRITE
582a38a92c9SIngo Weinhold
583a38a92c9SIngo Weinhold/* POSIX Errors */
584a38a92c9SIngo Weinhold#define E2BIG			FSSH_E2BIG
585a38a92c9SIngo Weinhold#define ECHILD			FSSH_ECHILD
586a38a92c9SIngo Weinhold#define EDEADLK			FSSH_EDEADLK
587a38a92c9SIngo Weinhold#define EFBIG			FSSH_EFBIG
588a38a92c9SIngo Weinhold#define EMLINK			FSSH_EMLINK
589a38a92c9SIngo Weinhold#define ENFILE			FSSH_ENFILE
590a38a92c9SIngo Weinhold#define ENODEV			FSSH_ENODEV
591a38a92c9SIngo Weinhold#define ENOLCK			FSSH_ENOLCK
592a38a92c9SIngo Weinhold#define ENOSYS			FSSH_ENOSYS
593a38a92c9SIngo Weinhold#define ENOTTY			FSSH_ENOTTY
594a38a92c9SIngo Weinhold#define ENXIO			FSSH_ENXIO
595a38a92c9SIngo Weinhold#define ESPIPE			FSSH_ESPIPE
596a38a92c9SIngo Weinhold#define ESRCH			FSSH_ESRCH
597a38a92c9SIngo Weinhold#define EFPOS			FSSH_EFPOS
598a38a92c9SIngo Weinhold#define ESIGPARM		FSSH_ESIGPARM
599a38a92c9SIngo Weinhold#define EDOM			FSSH_EDOM
600a38a92c9SIngo Weinhold#define ERANGE			FSSH_ERANGE
601a38a92c9SIngo Weinhold#define EPROTOTYPE		FSSH_EPROTOTYPE
602a38a92c9SIngo Weinhold#define EPROTONOSUPPORT	FSSH_EPROTONOSUPPORT
603a38a92c9SIngo Weinhold#define EPFNOSUPPORT	FSSH_EPFNOSUPPORT
604a38a92c9SIngo Weinhold#define EAFNOSUPPORT	FSSH_EAFNOSUPPORT
605a38a92c9SIngo Weinhold#define EADDRINUSE		FSSH_EADDRINUSE
606a38a92c9SIngo Weinhold#define EADDRNOTAVAIL	FSSH_EADDRNOTAVAIL
607a38a92c9SIngo Weinhold#define ENETDOWN		FSSH_ENETDOWN
608a38a92c9SIngo Weinhold#define ENETUNREACH		FSSH_ENETUNREACH
609a38a92c9SIngo Weinhold#define ENETRESET		FSSH_ENETRESET
610a38a92c9SIngo Weinhold#define ECONNABORTED	FSSH_ECONNABORTED
611a38a92c9SIngo Weinhold#define ECONNRESET		FSSH_ECONNRESET
612a38a92c9SIngo Weinhold#define EISCONN			FSSH_EISCONN
613a38a92c9SIngo Weinhold#define ENOTCONN		FSSH_ENOTCONN
614a38a92c9SIngo Weinhold#define ESHUTDOWN		FSSH_ESHUTDOWN
615a38a92c9SIngo Weinhold#define ECONNREFUSED	FSSH_ECONNREFUSED
616a38a92c9SIngo Weinhold#define EHOSTUNREACH	FSSH_EHOSTUNREACH
617a38a92c9SIngo Weinhold#define ENOPROTOOPT		FSSH_ENOPROTOOPT
618a38a92c9SIngo Weinhold#define ENOBUFS			FSSH_ENOBUFS
619a38a92c9SIngo Weinhold#define EINPROGRESS		FSSH_EINPROGRESS
620a38a92c9SIngo Weinhold#define EALREADY		FSSH_EALREADY
621a38a92c9SIngo Weinhold#define EILSEQ			FSSH_EILSEQ
622a38a92c9SIngo Weinhold#define ENOMSG			FSSH_ENOMSG
623a38a92c9SIngo Weinhold#define ESTALE			FSSH_ESTALE
624a38a92c9SIngo Weinhold#define EOVERFLOW		FSSH_EOVERFLOW
625a38a92c9SIngo Weinhold#define EMSGSIZE		FSSH_EMSGSIZE
626a38a92c9SIngo Weinhold#define EOPNOTSUPP		FSSH_EOPNOTSUPP
627a38a92c9SIngo Weinhold#define ENOTSOCK		FSSH_ENOTSOCK
628a38a92c9SIngo Weinhold#define EHOSTDOWN		FSSH_EHOSTDOWN
629a38a92c9SIngo Weinhold#define EBADMSG			FSSH_EBADMSG
630a38a92c9SIngo Weinhold#define ECANCELED		FSSH_ECANCELED
631a38a92c9SIngo Weinhold#define EDESTADDRREQ	FSSH_EDESTADDRREQ
632a38a92c9SIngo Weinhold#define EDQUOT			FSSH_EDQUOT
633a38a92c9SIngo Weinhold#define EIDRM			FSSH_EIDRM
634a38a92c9SIngo Weinhold#define EMULTIHOP		FSSH_EMULTIHOP
635a38a92c9SIngo Weinhold#define ENODATA			FSSH_ENODATA
636a38a92c9SIngo Weinhold#define ENOLINK			FSSH_ENOLINK
637a38a92c9SIngo Weinhold#define ENOSR			FSSH_ENOSR
638a38a92c9SIngo Weinhold#define ENOSTR			FSSH_ENOSTR
639a38a92c9SIngo Weinhold#define ENOTSUP			FSSH_ENOTSUP
640a38a92c9SIngo Weinhold#define EPROTO			FSSH_EPROTO
641a38a92c9SIngo Weinhold#define ETIME			FSSH_ETIME
642a38a92c9SIngo Weinhold#define ETXTBSY			FSSH_ETXTBSY
643a38a92c9SIngo Weinhold
644a38a92c9SIngo Weinhold/* POSIX errors that can be mapped to BeOS error codes */
645a38a92c9SIngo Weinhold#define ENOMEM			FSSH_ENOMEM
646a38a92c9SIngo Weinhold#define EACCES			FSSH_EACCES
647a38a92c9SIngo Weinhold#define EINTR			FSSH_EINTR
648a38a92c9SIngo Weinhold#define EIO				FSSH_EIO
649a38a92c9SIngo Weinhold#define EBUSY			FSSH_EBUSY
650a38a92c9SIngo Weinhold#define EFAULT			FSSH_EFAULT
651a38a92c9SIngo Weinhold#define ETIMEDOUT		FSSH_ETIMEDOUT
652a38a92c9SIngo Weinhold#define EAGAIN			FSSH_EAGAIN
653a38a92c9SIngo Weinhold#define EWOULDBLOCK		FSSH_EWOULDBLOCK
654a38a92c9SIngo Weinhold#define EBADF			FSSH_EBADF
655a38a92c9SIngo Weinhold#define EEXIST			FSSH_EEXIST
656a38a92c9SIngo Weinhold#define EINVAL			FSSH_EINVAL
657a38a92c9SIngo Weinhold#define ENAMETOOLONG	FSSH_ENAMETOOLONG
658a38a92c9SIngo Weinhold#define ENOENT			FSSH_ENOENT
659a38a92c9SIngo Weinhold#define EPERM			FSSH_EPERM
660a38a92c9SIngo Weinhold#define ENOTDIR			FSSH_ENOTDIR
661a38a92c9SIngo Weinhold#define EISDIR			FSSH_EISDIR
662a38a92c9SIngo Weinhold#define ENOTEMPTY		FSSH_ENOTEMPTY
663a38a92c9SIngo Weinhold#define ENOSPC			FSSH_ENOSPC
664a38a92c9SIngo Weinhold#define EROFS			FSSH_EROFS
665a38a92c9SIngo Weinhold#define EMFILE			FSSH_EMFILE
666a38a92c9SIngo Weinhold#define EXDEV			FSSH_EXDEV
667a38a92c9SIngo Weinhold#define ELOOP			FSSH_ELOOP
668a38a92c9SIngo Weinhold#define ENOEXEC			FSSH_ENOEXEC
669a38a92c9SIngo Weinhold#define EPIPE			FSSH_EPIPE
670a38a92c9SIngo Weinhold
671a38a92c9SIngo Weinhold/* new error codes that can be mapped to POSIX errors */
672a38a92c9SIngo Weinhold#define B_BUFFER_OVERFLOW			FSSH_B_BUFFER_OVERFLOW
673a38a92c9SIngo Weinhold#define B_TOO_MANY_ARGS				FSSH_B_TOO_MANY_ARGS
674a38a92c9SIngo Weinhold#define	B_FILE_TOO_LARGE			FSSH_B_FILE_TOO_LARGE
675a38a92c9SIngo Weinhold#define B_RESULT_NOT_REPRESENTABLE	FSSH_B_RESULT_NOT_REPRESENTABLE
676a38a92c9SIngo Weinhold#define	B_DEVICE_NOT_FOUND			FSSH_B_DEVICE_NOT_FOUND
677a38a92c9SIngo Weinhold#define B_NOT_SUPPORTED				FSSH_B_NOT_SUPPORTED
678a38a92c9SIngo Weinhold
679a38a92c9SIngo Weinhold/* Media Kit Errors */
680a38a92c9SIngo Weinhold#define B_STREAM_NOT_FOUND			FSSH_B_STREAM_NOT_FOUND
681a38a92c9SIngo Weinhold#define B_SERVER_NOT_FOUND			FSSH_B_SERVER_NOT_FOUND
682a38a92c9SIngo Weinhold#define B_RESOURCE_NOT_FOUND		FSSH_B_RESOURCE_NOT_FOUND
683a38a92c9SIngo Weinhold#define B_RESOURCE_UNAVAILABLE		FSSH_B_RESOURCE_UNAVAILABLE
684a38a92c9SIngo Weinhold#define B_BAD_SUBSCRIBER			FSSH_B_BAD_SUBSCRIBER
685a38a92c9SIngo Weinhold#define B_SUBSCRIBER_NOT_ENTERED	FSSH_B_SUBSCRIBER_NOT_ENTERED
686a38a92c9SIngo Weinhold#define B_BUFFER_NOT_AVAILABLE		FSSH_B_BUFFER_NOT_AVAILABLE
687a38a92c9SIngo Weinhold#define B_LAST_BUFFER_ERROR			FSSH_B_LAST_BUFFER_ERROR
688a38a92c9SIngo Weinhold
689a38a92c9SIngo Weinhold/* Mail Kit Errors */
690a38a92c9SIngo Weinhold#define B_MAIL_NO_DAEMON		FSSH_B_MAIL_NO_DAEMON
691a38a92c9SIngo Weinhold#define B_MAIL_UNKNOWN_USER		FSSH_B_MAIL_UNKNOWN_USER
692a38a92c9SIngo Weinhold#define B_MAIL_WRONG_PASSWORD	FSSH_B_MAIL_WRONG_PASSWORD
693a38a92c9SIngo Weinhold#define B_MAIL_UNKNOWN_HOST		FSSH_B_MAIL_UNKNOWN_HOST
694a38a92c9SIngo Weinhold#define B_MAIL_ACCESS_ERROR		FSSH_B_MAIL_ACCESS_ERROR
695a38a92c9SIngo Weinhold#define B_MAIL_UNKNOWN_FIELD	FSSH_B_MAIL_UNKNOWN_FIELD
696a38a92c9SIngo Weinhold#define B_MAIL_NO_RECIPIENT		FSSH_B_MAIL_NO_RECIPIENT
697a38a92c9SIngo Weinhold#define B_MAIL_INVALID_MAIL		FSSH_B_MAIL_INVALID_MAIL
698a38a92c9SIngo Weinhold
699a38a92c9SIngo Weinhold/* Printing Errors */
700a38a92c9SIngo Weinhold#define B_NO_PRINT_SERVER		FSSH_B_NO_PRINT_SERVER
701a38a92c9SIngo Weinhold
702a38a92c9SIngo Weinhold/* Device Kit Errors */
703a38a92c9SIngo Weinhold#define B_DEV_INVALID_IOCTL				FSSH_B_DEV_INVALID_IOCTL
704a38a92c9SIngo Weinhold#define B_DEV_NO_MEMORY					FSSH_B_DEV_NO_MEMORY
705a38a92c9SIngo Weinhold#define B_DEV_BAD_DRIVE_NUM				FSSH_B_DEV_BAD_DRIVE_NUM
706a38a92c9SIngo Weinhold#define B_DEV_NO_MEDIA					FSSH_B_DEV_NO_MEDIA
707a38a92c9SIngo Weinhold#define B_DEV_UNREADABLE				FSSH_B_DEV_UNREADABLE
708a38a92c9SIngo Weinhold#define B_DEV_FORMAT_ERROR				FSSH_B_DEV_FORMAT_ERROR
709a38a92c9SIngo Weinhold#define B_DEV_TIMEOUT					FSSH_B_DEV_TIMEOUT
710a38a92c9SIngo Weinhold#define B_DEV_RECALIBRATE_ERROR			FSSH_B_DEV_RECALIBRATE_ERROR
711a38a92c9SIngo Weinhold#define B_DEV_SEEK_ERROR				FSSH_B_DEV_SEEK_ERROR
712a38a92c9SIngo Weinhold#define B_DEV_ID_ERROR					FSSH_B_DEV_ID_ERROR
713a38a92c9SIngo Weinhold#define B_DEV_READ_ERROR				FSSH_B_DEV_READ_ERROR
714a38a92c9SIngo Weinhold#define B_DEV_WRITE_ERROR				FSSH_B_DEV_WRITE_ERROR
715a38a92c9SIngo Weinhold#define B_DEV_NOT_READY					FSSH_B_DEV_NOT_READY
716a38a92c9SIngo Weinhold#define B_DEV_MEDIA_CHANGED				FSSH_B_DEV_MEDIA_CHANGED
717a38a92c9SIngo Weinhold#define B_DEV_MEDIA_CHANGE_REQUESTED	FSSH_B_DEV_MEDIA_CHANGE_REQUESTED
718a38a92c9SIngo Weinhold#define B_DEV_RESOURCE_CONFLICT			FSSH_B_DEV_RESOURCE_CONFLICT
719a38a92c9SIngo Weinhold#define B_DEV_CONFIGURATION_ERROR		FSSH_B_DEV_CONFIGURATION_ERROR
720a38a92c9SIngo Weinhold#define B_DEV_DISABLED_BY_USER			FSSH_B_DEV_DISABLED_BY_USER
721a38a92c9SIngo Weinhold#define B_DEV_DOOR_OPEN					FSSH_B_DEV_DOOR_OPEN
722a38a92c9SIngo Weinhold
723a38a92c9SIngo Weinhold#define B_DEV_INVALID_PIPE				FSSH_B_DEV_INVALID_PIPE
724a38a92c9SIngo Weinhold#define B_DEV_CRC_ERROR					FSSH_B_DEV_CRC_ERROR
725a38a92c9SIngo Weinhold#define B_DEV_STALLED					FSSH_B_DEV_STALLED
726a38a92c9SIngo Weinhold#define B_DEV_BAD_PID					FSSH_B_DEV_BAD_PID
727a38a92c9SIngo Weinhold#define B_DEV_UNEXPECTED_PID			FSSH_B_DEV_UNEXPECTED_PID
728a38a92c9SIngo Weinhold#define B_DEV_DATA_OVERRUN				FSSH_B_DEV_DATA_OVERRUN
729a38a92c9SIngo Weinhold#define B_DEV_DATA_UNDERRUN				FSSH_B_DEV_DATA_UNDERRUN
730a38a92c9SIngo Weinhold#define B_DEV_FIFO_OVERRUN				FSSH_B_DEV_FIFO_OVERRUN
731a38a92c9SIngo Weinhold#define B_DEV_FIFO_UNDERRUN				FSSH_B_DEV_FIFO_UNDERRUN
732a38a92c9SIngo Weinhold#define B_DEV_PENDING					FSSH_B_DEV_PENDING
733a38a92c9SIngo Weinhold#define B_DEV_MULTIPLE_ERRORS			FSSH_B_DEV_MULTIPLE_ERRORS
734a38a92c9SIngo Weinhold#define B_DEV_TOO_LATE					FSSH_B_DEV_TOO_LATE
735a38a92c9SIngo Weinhold
736a38a92c9SIngo Weinhold
737a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
738a38a92c9SIngo Weinhold// #pragma mark - fssh_errno.h
739a38a92c9SIngo Weinhold
740a38a92c9SIngo Weinhold#define ENOERR	FSSH_ENOERR
741a38a92c9SIngo Weinhold#define EOK		FSSH_EOK
742a38a92c9SIngo Weinhold
743a38a92c9SIngo Weinhold#define errno	fssh_errno
744a38a92c9SIngo Weinhold
745a38a92c9SIngo Weinhold
746a38a92c9SIngo Weinhold////////////////////////////////////////////////////////////////////////////////
747a38a92c9SIngo Weinhold// #pragma mark - fssh_fcntl.h
748a38a92c9SIngo Weinhold
749a38a92c9SIngo Weinhold/* commands that can be passed to fcntl() */
750a38a92c9SIngo Weinhold#define F_DUPFD		FSSH_F_DUPFD
751a38a92c9SIngo Weinhold#define F_GETFD		FSSH_F_GETFD
752a38a92c9SIngo Weinhold#define F_SETFD		FSSH_F_SETFD
753a38a92c9SIngo Weinhold#define F_GETFL		FSSH_F_GETFL
754a38a92c9SIngo Weinhold#define F_SETFL		FSSH_F_SETFL
755a38a92c9SIngo Weinhold#define F_GETLK		FSSH_F_GETLK
756a38a92c9SIngo Weinhold#define F_SETLK		FSSH_F_SETLK
757a38a92c9SIngo Weinhold#define F_SETLKW	FSSH_F_SETLKW
758a38a92c9SIngo Weinhold
759a38a92c9SIngo Weinhold/* advisory locking types */
760a38a92c9SIngo Weinhold#define F_RDLCK	FSSH_F_RDLCK
761a38a92c9SIngo Weinhold#define F_UNLCK	FSSH_F_UNLCK
762a38a92c9SIngo Weinhold#define