2 * Copyright (c) 2002-2005 Apple Computer, Inc. All rights reserved.
4 * @APPLE_LICENSE_HEADER_START@
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. Please obtain a copy of the License at
10 * http://www.opensource.apple.com/apsl/ and read it before using this
13 * The Original Code and all software distributed under the License are
14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
18 * Please see the License for the specific language governing rights and
19 * limitations under the License.
21 * @APPLE_LICENSE_HEADER_END@
23 Change History (most recent first):
25 $Log: mDNSVxWorks.h,v $
26 Revision 1.4 2005/05/30 07:36:38 bradley
27 New implementation of the mDNS platform plugin for VxWorks 5.5 or later with IPv6 support.
31 #ifndef __MDNS_VXWORKS_H__
32 #define __MDNS_VXWORKS_H__
39 #include "CommonServices.h"
40 #include "DebugServices.h"
46 // Forward Declarations
48 typedef struct NetworkInterfaceInfoVxWorks NetworkInterfaceInfoVxWorks
;
50 //---------------------------------------------------------------------------------------------------------------------------
53 @abstract Data for IPv4 and IPv6 sockets.
56 typedef struct SocketSet SocketSet
;
59 NetworkInterfaceInfoVxWorks
* info
;
64 //---------------------------------------------------------------------------------------------------------------------------
65 /*! @struct NetworkInterfaceInfoVxWorks
67 @abstract Interface info for VxWorks.
70 struct NetworkInterfaceInfoVxWorks
72 NetworkInterfaceInfo ifinfo
; // MUST be the first element in this structure.
73 NetworkInterfaceInfoVxWorks
* next
;
74 mDNSu32 exists
; // 1 = currently exists in getifaddrs list; 0 = doesn't.
75 // 2 = exists, but McastTxRx state changed.
76 mDNSs32 lastSeen
; // If exists == 0, last time this interface appeared in getifaddrs list.
77 mDNSu32 scopeID
; // Interface index / IPv6 scope ID.
78 int family
; // Socket address family of the primary socket.
83 //---------------------------------------------------------------------------------------------------------------------------
84 /*! @struct mDNS_PlatformSupport_struct
86 @abstract Data for mDNS platform plugin.
89 struct mDNS_PlatformSupport_struct
91 NetworkInterfaceInfoVxWorks
* interfaceList
;
93 domainlabel userNiceLabel
;
94 domainlabel userHostLabel
;
105 //---------------------------------------------------------------------------------------------------------------------------
106 /*! @function mDNSReconfigure
108 @abstract Tell mDNS that the configuration has changed. Call when IP address changes, link goes up after being down, etc.
112 VxWorks does not provide a generic mechanism for getting notified when network interfaces change so this routines
113 provides a way for BSP-specific code to signal mDNS that something has changed and it should re-build its interfaces.
116 void mDNSReconfigure( void );
118 //---------------------------------------------------------------------------------------------------------------------------
119 /*! @function mDNSDeferIPv4
121 @abstract Tells mDNS whether to defer advertising of IPv4 interfaces.
125 To workaround problems with clients getting a link-local IPv4 address before a DHCP address is acquired, this allows
126 external code to defer advertising of IPv4 addresses until a DHCP lease has been acquired (or it times out).
129 void mDNSDeferIPv4( mDNSBool inDefer
);
135 #endif // __MDNS_VXWORKS_H__