Mercurial > illumos > illumos-gate
changeset 3479:d6bf78626206
6509782 protocols/ndpd.h is in the wrong place
author | apersson |
---|---|
date | Wed, 24 Jan 2007 15:13:27 -0800 |
parents | 16569328edf5 |
children | fa45699c47ff |
files | usr/src/cmd/cmd-inet/usr.lib/in.ndpd/tables.h usr/src/head/Makefile usr/src/head/ndpd.h usr/src/head/protocols/ndpd.h usr/src/pkgdefs/SUNWhea/prototype_com usr/src/tools/scripts/bfu.sh |
diffstat | 6 files changed, 160 insertions(+), 154 deletions(-) [+] |
line wrap: on
line diff
--- a/usr/src/cmd/cmd-inet/usr.lib/in.ndpd/tables.h Wed Jan 24 15:11:28 2007 -0800 +++ b/usr/src/cmd/cmd-inet/usr.lib/in.ndpd/tables.h Wed Jan 24 15:13:27 2007 -0800 @@ -32,7 +32,7 @@ extern "C" { #endif -#include <protocols/ndpd.h> +#include <ndpd.h> enum adv_states { NO_ADV = 0, REG_ADV, INIT_ADV, SOLICIT_ADV, FINAL_ADV }; enum adv_events { ADV_OFF, START_INIT_ADV, START_FINAL_ADV, RECEIVED_SOLICIT,
--- a/usr/src/head/Makefile Wed Jan 24 15:11:28 2007 -0800 +++ b/usr/src/head/Makefile Wed Jan 24 15:13:27 2007 -0800 @@ -107,6 +107,7 @@ mqueue.h \ nan.h \ ndbm.h \ + ndpd.h \ netconfig.h \ netdb.h \ netdir.h \ @@ -309,7 +310,7 @@ RPCSVCHDRS= $(RPCSVC_SRC_HDRS) $(RPCSVC_GEN_HDRS) -PROTOHDRS= dumprestore.h ndpd.h routed.h ripngd.h rwhod.h timed.h +PROTOHDRS= dumprestore.h routed.h ripngd.h rwhod.h timed.h ROOTHDRS= $(HDRS:%=$(ROOT)/usr/include/%) \ $(KRB5HDRS:%=$(ROOT)/usr/include/kerberosv5/%) \
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/usr/src/head/ndpd.h Wed Jan 24 15:13:27 2007 -0800 @@ -0,0 +1,151 @@ +/* + * CDDL HEADER START + * + * The contents of this file are subject to the terms of the + * Common Development and Distribution License (the "License"). + * You may not use this file except in compliance with the License. + * + * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE + * or http://www.opensolaris.org/os/licensing. + * See the License for the specific language governing permissions + * and limitations under the License. + * + * When distributing Covered Code, include this CDDL HEADER in each + * file and include the License file at usr/src/OPENSOLARIS.LICENSE. + * If applicable, add the following below this CDDL HEADER, with the + * fields enclosed by brackets "[]" replaced with your own identifying + * information: Portions Copyright [yyyy] [name of copyright owner] + * + * CDDL HEADER END + */ +/* + * Copyright 2007 Sun Microsystems, Inc. All rights reserved. + * Use is subject to license terms. + */ + +#ifndef _NDPD_H +#define _NDPD_H + +#pragma ident "%Z%%M% %I% %E% SMI" + +#ifdef __cplusplus +extern "C" { +#endif + +#define NDPD_SNMP_SOCKET "/var/run/in.ndpd_mib" +#define NDPD_SNMP_INFO_REQ 1 +#define NDPD_SNMP_INFO_RESPONSE 2 +#define NDPD_PHYINT_INFO 3 +#define NDPD_PREFIX_INFO 4 +#define NDPD_ROUTER_INFO 5 + +#define NDPD_SNMP_INFO_VER 1 +#define NDPD_PHYINT_INFO_VER 1 +#define NDPD_PREFIX_INFO_VER 1 +#define NDPD_ROUTER_INFO_VER 1 + +/* + * Data structures used to handle configuration variables set in ndpd.conf. + * cf_notdefault is set for variables explicitly set in ndpd.conf. + */ +struct confvar { + uint_t cf_value; + boolean_t cf_notdefault; +}; + +extern struct confvar ifdefaults[]; + +/* + * Interfaces configuration variable indicies + */ +#define I_DupAddrDetectTransmits 0 /* From RFC 2462 */ +#define I_AdvSendAdvertisements 1 +#define I_MaxRtrAdvInterval 2 /* In seconds */ +#define I_MinRtrAdvInterval 3 /* In seconds */ +#define I_AdvManagedFlag 4 +#define I_AdvOtherConfigFlag 5 +#define I_AdvLinkMTU 6 +#define I_AdvReachableTime 7 /* In milliseconds */ +#define I_AdvRetransTimer 8 /* In milliseconds */ +#define I_AdvCurHopLimit 9 +#define I_AdvDefaultLifetime 10 /* In seconds */ +#define I_StatelessAddrConf 11 +#define I_TmpAddrsEnabled 12 /* From RFC 3041 */ +#define I_TmpValidLifetime 13 /* In seconds */ +#define I_TmpPreferredLifetime 14 /* In seconds */ +#define I_TmpRegenAdvance 15 /* In seconds */ +#define I_TmpMaxDesyncFactor 16 /* In seconds */ +#define I_StatefulAddrConf 17 +#define I_IFSIZE 18 /* # of variables */ + +typedef struct ndpd_info_s { + uint_t info_type; + uint_t info_version; + uint_t info_num_of_phyints; +} ndpd_info_t; + +typedef struct ndpd_prefix_info_s { + uint_t prefix_info_type; + uint_t prefix_info_version; + struct in6_addr prefix_prefix; /* Used to indentify prefix */ + uint_t prefix_len; /* Num bits valid */ + uint_t prefix_flags; /* IFF_ flags */ + uint_t prefix_phyint_index; + uint_t prefix_ValidLifetime; /* In ms w/ 2 hour rule */ + uint_t prefix_PreferredLifetime; /* In millseconds */ + uint_t prefix_OnLinkLifetime; /* ms valid w/o 2 hour rule */ + boolean_t prefix_OnLinkFlag; + boolean_t prefix_AutonomousFlag; +} ndpd_prefix_info_t; + +typedef struct ndpd_router_info_s { + uint_t router_info_type; + uint_t router_info_version; + struct in6_addr router_address; /* Used to identify router */ + uint_t router_lifetime; /* In milliseconds */ + uint_t router_phyint_index; +} ndpd_router_info_t; + + +typedef struct ndpd_phyint_info_s { + uint_t phyint_info_type; + uint_t phyint_info_version; + int phyint_index; + struct confvar phyint_config[I_IFSIZE]; +#define phyint_DupAddrDetectTransmits \ + phyint_config[I_DupAddrDetectTransmits].cf_value +#define phyint_AdvSendAdvertisements \ + phyint_config[I_AdvSendAdvertisements].cf_value +#define phyint_MaxRtrAdvInterval \ + phyint_config[I_MaxRtrAdvInterval].cf_value +#define phyint_MinRtrAdvInterval \ + phyint_config[I_MinRtrAdvInterval].cf_value +#define phyint_AdvManagedFlag phyint_config[I_AdvManagedFlag].cf_value +#define phyint_AdvOtherConfigFlag \ + phyint_config[I_AdvOtherConfigFlag].cf_value +#define phyint_AdvLinkMTU phyint_config[I_AdvLinkMTU].cf_value +#define phyint_AdvReachableTime phyint_config[I_AdvReachableTime].cf_value +#define phyint_AdvRetransTimer phyint_config[I_AdvRetransTimer].cf_value +#define phyint_AdvCurHopLimit phyint_config[I_AdvCurHopLimit].cf_value +#define phyint_AdvDefaultLifetime \ + phyint_config[I_AdvDefaultLifetime].cf_value +#define phyint_StatelessAddrConf \ + phyint_config[I_StatelessAddrConf].cf_value +#define phyint_TmpAddrsEnabled phyint_config[I_TmpAddrsEnabled].cf_value +#define phyint_TmpValidLifetime phyint_config[I_TmpValidLifetime].cf_value +#define phyint_TmpPreferredLifetime \ + phyint_config[I_TmpPreferredLifetime].cf_value +#define phyint_TmpRegenAdvance phyint_config[I_TmpRegenAdvance].cf_value +#define phyint_TmpMaxDesyncFactor \ + phyint_config[I_TmpMaxDesyncFactor].cf_value +#define phyint_StatefulAddrConf \ + phyint_config[I_StatefulAddrConf].cf_value + uint_t phyint_num_of_prefixes; + uint_t phyint_num_of_routers; +} ndpd_phyint_info_t; + +#ifdef __cplusplus +} +#endif + +#endif /* _NDPD_H */
--- a/usr/src/head/protocols/ndpd.h Wed Jan 24 15:11:28 2007 -0800 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,151 +0,0 @@ -/* - * CDDL HEADER START - * - * The contents of this file are subject to the terms of the - * Common Development and Distribution License (the "License"). - * You may not use this file except in compliance with the License. - * - * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE - * or http://www.opensolaris.org/os/licensing. - * See the License for the specific language governing permissions - * and limitations under the License. - * - * When distributing Covered Code, include this CDDL HEADER in each - * file and include the License file at usr/src/OPENSOLARIS.LICENSE. - * If applicable, add the following below this CDDL HEADER, with the - * fields enclosed by brackets "[]" replaced with your own identifying - * information: Portions Copyright [yyyy] [name of copyright owner] - * - * CDDL HEADER END - */ -/* - * Copyright 2007 Sun Microsystems, Inc. All rights reserved. - * Use is subject to license terms. - */ - -#ifndef _NDPD_H -#define _NDPD_H - -#pragma ident "%Z%%M% %I% %E% SMI" - -#ifdef __cplusplus -extern "C" { -#endif - -#define NDPD_SNMP_SOCKET "/var/run/in.ndpd_mib" -#define NDPD_SNMP_INFO_REQ 1 -#define NDPD_SNMP_INFO_RESPONSE 2 -#define NDPD_PHYINT_INFO 3 -#define NDPD_PREFIX_INFO 4 -#define NDPD_ROUTER_INFO 5 - -#define NDPD_SNMP_INFO_VER 1 -#define NDPD_PHYINT_INFO_VER 1 -#define NDPD_PREFIX_INFO_VER 1 -#define NDPD_ROUTER_INFO_VER 1 - -/* - * Data structures used to handle configuration variables set in ndpd.conf. - * cf_notdefault is set for variables explicitly set in ndpd.conf. - */ -struct confvar { - uint_t cf_value; - boolean_t cf_notdefault; -}; - -extern struct confvar ifdefaults[]; - -/* - * Interfaces configuration variable indicies - */ -#define I_DupAddrDetectTransmits 0 /* From RFC 2462 */ -#define I_AdvSendAdvertisements 1 -#define I_MaxRtrAdvInterval 2 /* In seconds */ -#define I_MinRtrAdvInterval 3 /* In seconds */ -#define I_AdvManagedFlag 4 -#define I_AdvOtherConfigFlag 5 -#define I_AdvLinkMTU 6 -#define I_AdvReachableTime 7 /* In milliseconds */ -#define I_AdvRetransTimer 8 /* In milliseconds */ -#define I_AdvCurHopLimit 9 -#define I_AdvDefaultLifetime 10 /* In seconds */ -#define I_StatelessAddrConf 11 -#define I_TmpAddrsEnabled 12 /* From RFC 3041 */ -#define I_TmpValidLifetime 13 /* In seconds */ -#define I_TmpPreferredLifetime 14 /* In seconds */ -#define I_TmpRegenAdvance 15 /* In seconds */ -#define I_TmpMaxDesyncFactor 16 /* In seconds */ -#define I_StatefulAddrConf 17 -#define I_IFSIZE 18 /* # of variables */ - -typedef struct ndpd_info_s { - uint_t info_type; - uint_t info_version; - uint_t info_num_of_phyints; -} ndpd_info_t; - -typedef struct ndpd_prefix_info_s { - uint_t prefix_info_type; - uint_t prefix_info_version; - struct in6_addr prefix_prefix; /* Used to indentify prefix */ - uint_t prefix_len; /* Num bits valid */ - uint_t prefix_flags; /* IFF_ flags */ - uint_t prefix_phyint_index; - uint_t prefix_ValidLifetime; /* In ms w/ 2 hour rule */ - uint_t prefix_PreferredLifetime; /* In millseconds */ - uint_t prefix_OnLinkLifetime; /* ms valid w/o 2 hour rule */ - boolean_t prefix_OnLinkFlag; - boolean_t prefix_AutonomousFlag; -} ndpd_prefix_info_t; - -typedef struct ndpd_router_info_s { - uint_t router_info_type; - uint_t router_info_version; - struct in6_addr router_address; /* Used to identify router */ - uint_t router_lifetime; /* In milliseconds */ - uint_t router_phyint_index; -} ndpd_router_info_t; - - -typedef struct ndpd_phyint_info_s { - uint_t phyint_info_type; - uint_t phyint_info_version; - int phyint_index; - struct confvar phyint_config[I_IFSIZE]; -#define phyint_DupAddrDetectTransmits \ - phyint_config[I_DupAddrDetectTransmits].cf_value -#define phyint_AdvSendAdvertisements \ - phyint_config[I_AdvSendAdvertisements].cf_value -#define phyint_MaxRtrAdvInterval \ - phyint_config[I_MaxRtrAdvInterval].cf_value -#define phyint_MinRtrAdvInterval \ - phyint_config[I_MinRtrAdvInterval].cf_value -#define phyint_AdvManagedFlag phyint_config[I_AdvManagedFlag].cf_value -#define phyint_AdvOtherConfigFlag \ - phyint_config[I_AdvOtherConfigFlag].cf_value -#define phyint_AdvLinkMTU phyint_config[I_AdvLinkMTU].cf_value -#define phyint_AdvReachableTime phyint_config[I_AdvReachableTime].cf_value -#define phyint_AdvRetransTimer phyint_config[I_AdvRetransTimer].cf_value -#define phyint_AdvCurHopLimit phyint_config[I_AdvCurHopLimit].cf_value -#define phyint_AdvDefaultLifetime \ - phyint_config[I_AdvDefaultLifetime].cf_value -#define phyint_StatelessAddrConf \ - phyint_config[I_StatelessAddrConf].cf_value -#define phyint_TmpAddrsEnabled phyint_config[I_TmpAddrsEnabled].cf_value -#define phyint_TmpValidLifetime phyint_config[I_TmpValidLifetime].cf_value -#define phyint_TmpPreferredLifetime \ - phyint_config[I_TmpPreferredLifetime].cf_value -#define phyint_TmpRegenAdvance phyint_config[I_TmpRegenAdvance].cf_value -#define phyint_TmpMaxDesyncFactor \ - phyint_config[I_TmpMaxDesyncFactor].cf_value -#define phyint_StatefulAddrConf \ - phyint_config[I_StatefulAddrConf].cf_value - uint_t phyint_num_of_prefixes; - uint_t phyint_num_of_routers; -} ndpd_phyint_info_t; - -#ifdef __cplusplus -} -#endif - -#endif /* _NDPD_H */
--- a/usr/src/pkgdefs/SUNWhea/prototype_com Wed Jan 24 15:11:28 2007 -0800 +++ b/usr/src/pkgdefs/SUNWhea/prototype_com Wed Jan 24 15:13:27 2007 -0800 @@ -239,6 +239,7 @@ f none usr/include/mtmalloc.h 644 root bin f none usr/include/nan.h 644 root bin f none usr/include/ndbm.h 644 root bin +f none usr/include/ndpd.h 644 root bin d none usr/include/net 755 root bin f none usr/include/net/af.h 644 root bin f none usr/include/net/if.h 644 root bin @@ -335,7 +336,6 @@ f none usr/include/project.h 644 root bin d none usr/include/protocols 755 root bin f none usr/include/protocols/dumprestore.h 644 root bin -f none usr/include/protocols/ndpd.h 644 root bin f none usr/include/protocols/routed.h 644 root bin f none usr/include/protocols/rwhod.h 644 root bin f none usr/include/protocols/timed.h 644 root bin
--- a/usr/src/tools/scripts/bfu.sh Wed Jan 24 15:11:28 2007 -0800 +++ b/usr/src/tools/scripts/bfu.sh Wed Jan 24 15:13:27 2007 -0800 @@ -4933,6 +4933,11 @@ fi # + # Remove old ndpd header (moved to /usr/include per 6509782) + # + rm -f $usr/include/protocols/ndpd.h + + # # Remove old FMA dictionary files # rm -f $usr/lib/fm/FMD.dict