Tomato 1.28
[tomato.git] / release / src / router / ppp / svr4 / ppp_comp_mod.c
blobacef63d8cac07bb81b6b7705467210125062480e
1 /*
2 * ppp_comp_mod.c - modload support for PPP compression STREAMS module.
4 * Copyright (c) 1994 The Australian National University.
5 * All rights reserved.
7 * Permission to use, copy, modify, and distribute this software and its
8 * documentation is hereby granted, provided that the above copyright
9 * notice appears in all copies. This software is provided without any
10 * warranty, express or implied. The Australian National University
11 * makes no representations about the suitability of this software for
12 * any purpose.
14 * IN NO EVENT SHALL THE AUSTRALIAN NATIONAL UNIVERSITY BE LIABLE TO ANY
15 * PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
16 * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF
17 * THE AUSTRALIAN NATIONAL UNIVERSITY HAVE BEEN ADVISED OF THE POSSIBILITY
18 * OF SUCH DAMAGE.
20 * THE AUSTRALIAN NATIONAL UNIVERSITY SPECIFICALLY DISCLAIMS ANY WARRANTIES,
21 * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
22 * AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
23 * ON AN "AS IS" BASIS, AND THE AUSTRALIAN NATIONAL UNIVERSITY HAS NO
24 * OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS,
25 * OR MODIFICATIONS.
27 * $Id: ppp_comp_mod.c,v 1.1.1.4 2003/10/14 08:09:54 sparq Exp $
31 * This file is used under Solaris 2.
33 #include <sys/types.h>
34 #include <sys/param.h>
35 #include <sys/conf.h>
36 #include <sys/modctl.h>
37 #include <sys/sunddi.h>
39 extern struct streamtab ppp_compinfo;
41 static struct fmodsw fsw = {
42 "ppp_comp",
43 &ppp_compinfo,
44 D_NEW | D_MP | D_MTQPAIR
47 extern struct mod_ops mod_strmodops;
49 static struct modlstrmod modlstrmod = {
50 &mod_strmodops,
51 "PPP compression module",
52 &fsw
55 static struct modlinkage modlinkage = {
56 MODREV_1,
57 (void *) &modlstrmod,
58 NULL
62 * Entry points for modloading.
64 int
65 _init(void)
67 return mod_install(&modlinkage);
70 int
71 _fini(void)
73 return mod_remove(&modlinkage);
76 int
77 _info(mip)
78 struct modinfo *mip;
80 return mod_info(&modlinkage, mip);