xref: /minix3/sys/fs/udf/udf_osta.h (revision 9f988b79349f9b89ecc822458c30ec8897558560)
1*9f988b79SJean-Baptiste Boric /* $NetBSD: udf_osta.h,v 1.4 2008/05/14 16:49:48 reinoud Exp $ */
2*9f988b79SJean-Baptiste Boric 
3*9f988b79SJean-Baptiste Boric /*
4*9f988b79SJean-Baptiste Boric  * Prototypes for the OSTA functions
5*9f988b79SJean-Baptiste Boric  */
6*9f988b79SJean-Baptiste Boric 
7*9f988b79SJean-Baptiste Boric 
8*9f988b79SJean-Baptiste Boric #ifndef _FS_UDF_OSTA_H_
9*9f988b79SJean-Baptiste Boric #define _FS_UDF_OSTA_H_
10*9f988b79SJean-Baptiste Boric 
11*9f988b79SJean-Baptiste Boric #include <sys/types.h>
12*9f988b79SJean-Baptiste Boric 
13*9f988b79SJean-Baptiste Boric #ifndef _KERNEL
14*9f988b79SJean-Baptiste Boric #include <stdbool.h>
15*9f988b79SJean-Baptiste Boric #endif
16*9f988b79SJean-Baptiste Boric 
17*9f988b79SJean-Baptiste Boric #ifndef UNIX
18*9f988b79SJean-Baptiste Boric #define	UNIX
19*9f988b79SJean-Baptiste Boric #endif
20*9f988b79SJean-Baptiste Boric 
21*9f988b79SJean-Baptiste Boric #ifndef MAXLEN
22*9f988b79SJean-Baptiste Boric #define	MAXLEN	255
23*9f988b79SJean-Baptiste Boric #endif
24*9f988b79SJean-Baptiste Boric 
25*9f988b79SJean-Baptiste Boric 
26*9f988b79SJean-Baptiste Boric /***********************************************************************
27*9f988b79SJean-Baptiste Boric  * The following two typedef's are to remove compiler dependancies.
28*9f988b79SJean-Baptiste Boric  * byte needs to be unsigned 8-bit, and unicode_t needs to be
29*9f988b79SJean-Baptiste Boric  * unsigned 16-bit.
30*9f988b79SJean-Baptiste Boric  */
31*9f988b79SJean-Baptiste Boric typedef uint16_t unicode_t;
32*9f988b79SJean-Baptiste Boric typedef uint8_t    byte;
33*9f988b79SJean-Baptiste Boric 
34*9f988b79SJean-Baptiste Boric 
35*9f988b79SJean-Baptiste Boric int udf_UncompressUnicode(int, byte *, unicode_t *);
36*9f988b79SJean-Baptiste Boric int udf_CompressUnicode(int, int, unicode_t *, byte *);
37*9f988b79SJean-Baptiste Boric unsigned short udf_cksum(unsigned char *, int);
38*9f988b79SJean-Baptiste Boric unsigned short udf_unicode_cksum(unsigned short *, int);
39*9f988b79SJean-Baptiste Boric uint16_t udf_ea_cksum(uint8_t *data);
40*9f988b79SJean-Baptiste Boric int UDFTransName(unicode_t *, unicode_t *, int);
41*9f988b79SJean-Baptiste Boric int UnicodeLength(unicode_t *string);
42*9f988b79SJean-Baptiste Boric 
43*9f988b79SJean-Baptiste Boric 
44*9f988b79SJean-Baptiste Boric #endif /* _FS_UDF_OSTA_H_ */
45