Flesh out BUF_CMD_FLUSH support.
[dragonfly.git] / sbin / dhclient / includes / dhcpd.h.patch
1 $DragonFly: src/sbin/dhclient/includes/Attic/dhcpd.h.patch,v 1.1 2005/01/04 19:58:54 joerg Exp $
2 --- dhcpd.h.orig        2004-11-24 18:39:16.000000000 +0100
3 +++ dhcpd.h     2005-01-04 19:11:18.000000000 +0100
4 @@ -90,6 +90,9 @@
5          (((x) >> OPTION_HASH_EXP) & \
6           (OPTION_HASH_PTWO - 1))) % OPTION_HASH_SIZE;
7  
8 +#define NOLINK 0
9 +#define HAVELINK 1
10 +
11  enum dhcp_shutdown_state {
12         shutdown_listeners,
13         shutdown_omapi_connections,
14 @@ -255,7 +258,7 @@
15  } dhcp_control_object_t;
16  
17  /* Lease states: */
18 -typedef enum {
19 +typedef enum  {
20         FTS_FREE = 1,
21         FTS_ACTIVE = 2,
22         FTS_EXPIRED = 3,
23 @@ -263,7 +266,7 @@
24         FTS_ABANDONED = 5,
25         FTS_RESET = 6,
26         FTS_BACKUP = 7
27 -} binding_state_t;
28 +} __packed binding_state_t;
29  
30  /* FTS_LAST is the highest value that is valid for a lease binding state. */
31  #define FTS_LAST FTS_BACKUP
32 @@ -306,9 +309,9 @@
33  #      define EPHEMERAL_FLAGS          (MS_NULL_TERMINATION | \
34                                          UNICAST_BROADCAST_HACK)
35  
36 -       binding_state_t __attribute__ ((mode (__byte__))) binding_state;
37 -       binding_state_t __attribute__ ((mode (__byte__))) next_binding_state;
38 -       binding_state_t __attribute__ ((mode (__byte__))) desired_binding_state;
39 +       binding_state_t binding_state;
40 +       binding_state_t next_binding_state;
41 +       binding_state_t desired_binding_state;
42         
43         struct lease_state *state;
44  
45 @@ -774,6 +777,11 @@
46         unsigned remote_id_len;         /* Length of Remote ID. */
47  
48         char name [IFNAMSIZ];           /* Its name... */
49 +       int ieee80211;                  /* True if media is ieee802.11 */
50 +       int havemedia;                  /* True if we have a media table */
51 +       int linkstate;                  /* True if we have link */
52 +       int polling;                    /* True if polling is enabled */
53 +       int forcediscover;              /* True if a discover is needed */
54         int index;                      /* Its index. */
55         int rfdesc;                     /* Its read file descriptor. */
56         int wfdesc;                     /* Its write file descriptor, if
57 @@ -1836,6 +1844,9 @@
58  extern const char *path_dhclient_pid;
59  extern char *path_dhclient_script;
60  extern int interfaces_requested;
61 +#ifdef ENABLE_POLLING_MODE
62 +extern int polling_interval;
63 +#endif
64  
65  extern struct client_config top_level_config;
66  
67 @@ -1849,6 +1860,10 @@
68  void send_decline PROTO ((void *));
69  
70  void state_reboot PROTO ((void *));
71 +#ifdef ENABLE_POLLING_MODE
72 +void state_background PROTO ((void *));
73 +void state_polling PROTO ((void *));
74 +#endif
75  void state_init PROTO ((void *));
76  void state_selecting PROTO ((void *));
77  void state_requesting PROTO ((void *));
78 @@ -1856,6 +1871,11 @@
79  void state_stop PROTO ((void *));
80  void state_panic PROTO ((void *));
81  
82 +#if defined(DRAGONFLY_FUTURE)
83 +void set_ieee80211 PROTO ((struct interface_info *));
84 +#endif
85 +int interface_active PROTO ((struct interface_info *));
86 +
87  void bind_lease PROTO ((struct client_state *));
88  
89  void make_client_options PROTO ((struct client_state *,