Deleted Added
full compact
atmconfig.h (118824) atmconfig.h (133565)
1/*
2 * Copyright (c) 2001-2003
3 * Fraunhofer Institute for Open Communication Systems (FhG Fokus).
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 12 unchanged lines hidden (view full) ---

21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
25 * SUCH DAMAGE.
26 *
27 * Author: Hartmut Brandt <harti@freebsd.org>
28 *
1/*
2 * Copyright (c) 2001-2003
3 * Fraunhofer Institute for Open Communication Systems (FhG Fokus).
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 12 unchanged lines hidden (view full) ---

21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
25 * SUCH DAMAGE.
26 *
27 * Author: Hartmut Brandt <harti@freebsd.org>
28 *
29 * $FreeBSD: head/sbin/atm/atmconfig/atmconfig.h 118824 2003-08-12 14:25:57Z harti $
29 * $FreeBSD: head/sbin/atm/atmconfig/atmconfig.h 133565 2004-08-12 12:31:43Z harti $
30 */
31#ifndef _ATMCONFIG_H
32#define _ATMCONFIG_H
33
34#include <sys/types.h>
35#include <sys/socket.h>
36#include <sys/queue.h>
37#include <netgraph/ng_message.h>

--- 5 unchanged lines hidden (view full) ---

43 const struct cmdtab *sub;
44 void (*func)(int, char *[]);
45};
46
47/*
48 * client configuration info
49 */
50struct amodule {
30 */
31#ifndef _ATMCONFIG_H
32#define _ATMCONFIG_H
33
34#include <sys/types.h>
35#include <sys/socket.h>
36#include <sys/queue.h>
37#include <netgraph/ng_message.h>

--- 5 unchanged lines hidden (view full) ---

43 const struct cmdtab *sub;
44 void (*func)(int, char *[]);
45};
46
47/*
48 * client configuration info
49 */
50struct amodule {
51 struct cmdtab cmd;
52 const char *help;
51 const struct cmdtab *cmd;
53};
54
52};
53
55#define DEF_MODULE(CMDTAB, HELP) \
56struct amodule amodule_1 = { CMDTAB, HELP };
54#define DEF_MODULE(CMDTAB) \
55struct amodule amodule_1 = { CMDTAB }
57
56
57/* for compiled-in modules */
58void register_module(const struct amodule *);
59
58/* print a message if we are verbose */
59void verb(const char *, ...) __printflike(1, 2);
60
61/* print heading */
62void heading(const char *, ...) __printflike(1, 2);
63
64/* before starting output */
65void heading_init(void);
66
67/* stringify an enumerated value */
68struct penum {
69 int32_t value;
70 const char *str;
71};
72const char *penum(int32_t value, const struct penum *strtab, char *buf);
60/* print a message if we are verbose */
61void verb(const char *, ...) __printflike(1, 2);
62
63/* print heading */
64void heading(const char *, ...) __printflike(1, 2);
65
66/* before starting output */
67void heading_init(void);
68
69/* stringify an enumerated value */
70struct penum {
71 int32_t value;
72 const char *str;
73};
74const char *penum(int32_t value, const struct penum *strtab, char *buf);
75int pparse(int32_t *, const struct penum *, const char *);
73
74enum {
75 OPT_NONE,
76 OPT_UINT,
77 OPT_INT,
78 OPT_UINT32,
79 OPT_INT32,
80 OPT_UINT64,

--- 7 unchanged lines hidden (view full) ---

88 const char *optstr;
89 int opttype;
90 void *optarg;
91};
92
93int parse_options(int *_pargc, char ***_pargv,
94 const struct option *_opts);
95
76
77enum {
78 OPT_NONE,
79 OPT_UINT,
80 OPT_INT,
81 OPT_UINT32,
82 OPT_INT32,
83 OPT_UINT64,

--- 7 unchanged lines hidden (view full) ---

91 const char *optstr;
92 int opttype;
93 void *optarg;
94};
95
96int parse_options(int *_pargc, char ***_pargv,
97 const struct option *_opts);
98
99/* XXX while this is compiled in */
100void device_register(void);
101
96#endif /* _ATMCONFIG_H */
102#endif /* _ATMCONFIG_H */