Merge branch master
[unleashed.git] / include / net / af.h
blob8500eb5806043bf0bb33661a0e05a6af856ace71
1 /*
2 * Copyright (c) 1997-1998 by Sun Microsystems, Inc.
3 * All rights reserved.
4 */
6 /*
7 * Copyright (c) 1980, 1986 Regents of the University of California.
8 * All rights reserved. The Berkeley software License Agreement
9 * specifies the terms and conditions for redistribution.
12 #ifndef _NET_AF_H
13 #define _NET_AF_H
15 #pragma ident "%Z%%M% %I% %E% SMI"
16 /* af.h 1.10 88/08/19 SMI; from UCB 7.1 */
18 #ifdef __cplusplus
19 extern "C" {
20 #endif
23 * Address family routines,
24 * used in handling generic sockaddr structures.
26 * Hash routine is called
27 * af_hash(addr, h);
28 * struct sockaddr *addr; struct afhash *h;
29 * producing an afhash structure for addr.
31 * Netmatch routine is called
32 * af_netmatch(addr1, addr2);
33 * where addr1 and addr2 are sockaddr *. Returns 1 if network
34 * values match, 0 otherwise.
36 struct afswitch {
37 int (*af_hash)();
38 int (*af_netmatch)();
41 struct afhash {
42 uint_t afh_hosthash;
43 uint_t afh_nethash;
46 #ifdef __cplusplus
48 #endif
50 #endif /* _NET_AF_H */