Print this page
7127  remove -Wno-missing-braces from Makefile.uts


   6  * You may not use this file except in compliance with the License.
   7  *
   8  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9  * or http://www.opensolaris.org/os/licensing.
  10  * See the License for the specific language governing permissions
  11  * and limitations under the License.
  12  *
  13  * When distributing Covered Code, include this CDDL HEADER in each
  14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15  * If applicable, add the following below this CDDL HEADER, with the
  16  * fields enclosed by brackets "[]" replaced with your own identifying
  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 /*
  22  * Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
  23  * Use is subject to license terms.
  24  */
  25 
  26 #pragma ident   "%Z%%M% %I%     %E% SMI"
  27 
  28 #include <sys/types.h>
  29 #include <sys/param.h>
  30 #include <sys/sysmacros.h>
  31 #include <sys/systm.h>
  32 #include <sys/debug.h>
  33 #include <sys/kmem.h>
  34 #include <sys/sunddi.h>
  35 #include <sys/byteorder.h>
  36 #include <sys/errno.h>
  37 #include <sys/modctl.h>
  38 #include <sys/kiconv.h>
  39 #include <sys/u8_textprep.h>
  40 #include <sys/kiconv_cck_common.h>
  41 #include <sys/kiconv_sc.h>
  42 #include <sys/kiconv_gb18030_utf8.h>
  43 #include <sys/kiconv_gb2312_utf8.h>
  44 #include <sys/kiconv_utf8_gb18030.h>
  45 #include <sys/kiconv_utf8_gb2312.h>
  46 
  47 static int8_t gb2312_to_utf8(uchar_t byte1, uchar_t byte2, uchar_t *ob,


 948 };
 949 
 950 static kiconv_module_info_t kiconv_sc_info = {
 951         "kiconv_sc",            /* module name */
 952         sizeof (kiconv_sc_ops_tbl) / sizeof (kiconv_sc_ops_tbl[0]),
 953         kiconv_sc_ops_tbl,
 954         0,
 955         NULL,
 956         NULL,
 957         0
 958 };
 959 
 960 static struct modlkiconv modlkiconv_sc = {
 961         &mod_kiconvops,
 962         "kiconv Simplified Chinese module 1.0",
 963         &kiconv_sc_info
 964 };
 965 
 966 static struct modlinkage modlinkage = {
 967         MODREV_1,
 968         (void *)&modlkiconv_sc,
 969         NULL
 970 };
 971 
 972 int
 973 _init(void)
 974 {
 975         int err;
 976 
 977         err = mod_install(&modlinkage);
 978         if (err)
 979                 cmn_err(CE_WARN, "kiconv_sc: failed to load kernel module");
 980 
 981         return (err);
 982 }
 983 
 984 int
 985 _fini(void)
 986 {
 987         int err;
 988 
 989         /*




   6  * You may not use this file except in compliance with the License.
   7  *
   8  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
   9  * or http://www.opensolaris.org/os/licensing.
  10  * See the License for the specific language governing permissions
  11  * and limitations under the License.
  12  *
  13  * When distributing Covered Code, include this CDDL HEADER in each
  14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15  * If applicable, add the following below this CDDL HEADER, with the
  16  * fields enclosed by brackets "[]" replaced with your own identifying
  17  * information: Portions Copyright [yyyy] [name of copyright owner]
  18  *
  19  * CDDL HEADER END
  20  */
  21 /*
  22  * Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
  23  * Use is subject to license terms.
  24  */
  25 


  26 #include <sys/types.h>
  27 #include <sys/param.h>
  28 #include <sys/sysmacros.h>
  29 #include <sys/systm.h>
  30 #include <sys/debug.h>
  31 #include <sys/kmem.h>
  32 #include <sys/sunddi.h>
  33 #include <sys/byteorder.h>
  34 #include <sys/errno.h>
  35 #include <sys/modctl.h>
  36 #include <sys/kiconv.h>
  37 #include <sys/u8_textprep.h>
  38 #include <sys/kiconv_cck_common.h>
  39 #include <sys/kiconv_sc.h>
  40 #include <sys/kiconv_gb18030_utf8.h>
  41 #include <sys/kiconv_gb2312_utf8.h>
  42 #include <sys/kiconv_utf8_gb18030.h>
  43 #include <sys/kiconv_utf8_gb2312.h>
  44 
  45 static int8_t gb2312_to_utf8(uchar_t byte1, uchar_t byte2, uchar_t *ob,


 946 };
 947 
 948 static kiconv_module_info_t kiconv_sc_info = {
 949         "kiconv_sc",            /* module name */
 950         sizeof (kiconv_sc_ops_tbl) / sizeof (kiconv_sc_ops_tbl[0]),
 951         kiconv_sc_ops_tbl,
 952         0,
 953         NULL,
 954         NULL,
 955         0
 956 };
 957 
 958 static struct modlkiconv modlkiconv_sc = {
 959         &mod_kiconvops,
 960         "kiconv Simplified Chinese module 1.0",
 961         &kiconv_sc_info
 962 };
 963 
 964 static struct modlinkage modlinkage = {
 965         MODREV_1,
 966         { (void *)&modlkiconv_sc, NULL }

 967 };
 968 
 969 int
 970 _init(void)
 971 {
 972         int err;
 973 
 974         err = mod_install(&modlinkage);
 975         if (err)
 976                 cmn_err(CE_WARN, "kiconv_sc: failed to load kernel module");
 977 
 978         return (err);
 979 }
 980 
 981 int
 982 _fini(void)
 983 {
 984         int err;
 985 
 986         /*