xref: /dflybsd-src/lib/i18n_module/mapper_std/citrus_mapper_std_file.h (revision 0d5acd7467c4e95f792ef49fceb3ab8e917ce86b)
1*0d5acd74SJohn Marino /* $FreeBSD: head/lib/libiconv_modules/mapper_std/citrus_mapper_std_file.h 219019 2011-02-25 00:04:39Z gabor $ */
2*0d5acd74SJohn Marino /*	$NetBSD: citrus_mapper_std_file.h,v 1.3 2006/09/09 14:35:17 tnozaki Exp $	*/
3*0d5acd74SJohn Marino 
4*0d5acd74SJohn Marino /*-
5*0d5acd74SJohn Marino  * Copyright (c)2003, 2006 Citrus Project,
6*0d5acd74SJohn Marino  * All rights reserved.
7*0d5acd74SJohn Marino  *
8*0d5acd74SJohn Marino  * Redistribution and use in source and binary forms, with or without
9*0d5acd74SJohn Marino  * modification, are permitted provided that the following conditions
10*0d5acd74SJohn Marino  * are met:
11*0d5acd74SJohn Marino  * 1. Redistributions of source code must retain the above copyright
12*0d5acd74SJohn Marino  *    notice, this list of conditions and the following disclaimer.
13*0d5acd74SJohn Marino  * 2. Redistributions in binary form must reproduce the above copyright
14*0d5acd74SJohn Marino  *    notice, this list of conditions and the following disclaimer in the
15*0d5acd74SJohn Marino  *    documentation and/or other materials provided with the distribution.
16*0d5acd74SJohn Marino  *
17*0d5acd74SJohn Marino  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18*0d5acd74SJohn Marino  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19*0d5acd74SJohn Marino  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
20*0d5acd74SJohn Marino  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
21*0d5acd74SJohn Marino  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
22*0d5acd74SJohn Marino  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23*0d5acd74SJohn Marino  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24*0d5acd74SJohn Marino  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25*0d5acd74SJohn Marino  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26*0d5acd74SJohn Marino  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27*0d5acd74SJohn Marino  * SUCH DAMAGE.
28*0d5acd74SJohn Marino  */
29*0d5acd74SJohn Marino 
30*0d5acd74SJohn Marino #ifndef _CITRUS_MAPPER_STD_FILE_H_
31*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_FILE_H_
32*0d5acd74SJohn Marino 
33*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_MAGIC		"MAPPER\0\0"
34*0d5acd74SJohn Marino 
35*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_SYM_TYPE		"type"
36*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_SYM_INFO		"info"
37*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_SYM_TABLE		"table"
38*0d5acd74SJohn Marino 
39*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_TYPE_ROWCOL		"rowcol"
40*0d5acd74SJohn Marino struct _citrus_mapper_std_rowcol_info_x {
41*0d5acd74SJohn Marino 	uint32_t		rcx_src_rowcol_bits;
42*0d5acd74SJohn Marino 	uint32_t		rcx_dst_invalid;
43*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_ROWCOL_MAX			4
44*0d5acd74SJohn Marino 	struct {
45*0d5acd74SJohn Marino 		uint32_t		begin;
46*0d5acd74SJohn Marino 		uint32_t		end;
47*0d5acd74SJohn Marino 	} __packed		rcx_src_rowcol[_CITRUS_MAPPER_STD_ROWCOL_MAX];
48*0d5acd74SJohn Marino 	uint32_t		rcx_dst_unit_bits;
49*0d5acd74SJohn Marino 	uint32_t		rcx_src_rowcol_len;
50*0d5acd74SJohn Marino } __packed;
51*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_ROWCOL_INFO_SIZE		48
52*0d5acd74SJohn Marino 
53*0d5acd74SJohn Marino /* old file layout */
54*0d5acd74SJohn Marino struct _citrus_mapper_std_rowcol_info_compat_x {
55*0d5acd74SJohn Marino 	uint32_t		rcx_src_col_bits;
56*0d5acd74SJohn Marino 	uint32_t		rcx_dst_invalid;
57*0d5acd74SJohn Marino 	uint32_t		rcx_src_row_begin;
58*0d5acd74SJohn Marino 	uint32_t		rcx_src_row_end;
59*0d5acd74SJohn Marino 	uint32_t		rcx_src_col_begin;
60*0d5acd74SJohn Marino 	uint32_t		rcx_src_col_end;
61*0d5acd74SJohn Marino 	uint32_t		rcx_dst_unit_bits;
62*0d5acd74SJohn Marino 	uint32_t		rcx_pad;
63*0d5acd74SJohn Marino } __packed;
64*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_ROWCOL_INFO_COMPAT_SIZE	32
65*0d5acd74SJohn Marino 
66*0d5acd74SJohn Marino /* rowcol oob extension info */
67*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_SYM_ROWCOL_EXT_ILSEQ		"rowcol_ext_ilseq"
68*0d5acd74SJohn Marino struct _citrus_mapper_std_rowcol_ext_ilseq_info_x {
69*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_OOB_NONIDENTICAL	0
70*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_OOB_ILSEQ		1
71*0d5acd74SJohn Marino 	uint32_t		eix_oob_mode;
72*0d5acd74SJohn Marino 	uint32_t		eix_dst_ilseq;
73*0d5acd74SJohn Marino } __packed;
74*0d5acd74SJohn Marino #define _CITRUS_MAPPER_STD_ROWCOL_EXT_ILSEQ_SIZE	8
75*0d5acd74SJohn Marino 
76*0d5acd74SJohn Marino #endif
77