# define ABS(x) ((x) >= 0 ? (x) : 0-(x))
# endif
+#if defined(USE_DLPI_PFMOD) || defined(USE_DLPI_RAW)
static int strioctl PROTO ((int fd, int cmd, int timeout, int len, char *dp));
+#endif
#define DLPI_MAXDLBUF 8192 /* Buffer size */
#define DLPI_MAXDLADDR 1024 /* Max address size */
static int dlpibindreq PROTO ((int fd, unsigned long sap, unsigned long max_conind,
unsigned long service_mode, unsigned long conn_mgmt,
unsigned long xidtest));
+#if defined(UNUSED_DLPI_INTERFACE)
+/* These functions are unused at present, but may be used at a later date.
+ * defined out to avoid compiler warnings about unused static functions.
+ */
static int dlpidetachreq PROTO ((int fd));
static int dlpiunbindreq PROTO ((int fd));
+#endif
static int dlpiokack PROTO ((int fd, char *bufp));
static int dlpiinfoack PROTO ((int fd, char *bufp));
static int dlpiphysaddrack PROTO ((int fd, char *bufp));
return sock;
}
+#if defined(USE_DLPI_PFMOD) || defined(USE_DLPI_RAW)
static int
strioctl (fd, cmd, timeout, len, dp)
int fd;
return sio.ic_len;
}
}
+#endif /* USE_DPI_PFMOD || USE_DLPI_RAW */
#ifdef USE_DLPI_SEND
void if_register_send (info)
struct sockaddr_in *to;
struct hardware *hto;
{
- unsigned hbufp = 0;
+#ifdef USE_DLPI_RAW
double hh [32];
+#endif
double ih [1536 / sizeof (double)];
unsigned char *dbuf = (unsigned char *)ih;
unsigned dbuflen;
unsigned char dbuf [1536];
unsigned char srcaddr [DLPI_MAXDLADDR];
unsigned long srcaddrlen;
- int flags = 0;
int length = 0;
int offset = 0;
- int rslt;
int bufix = 0;
int paylen;
static int dlpiunit (ifname)
char *ifname;
{
- int fd;
- char *cp, *dp, *ep;
+ char *cp;
int unit;
if (!ifname) {
return putmsg (fd, &ctl, (struct strbuf*)NULL, flags);
}
+#if defined(UNUSED_DLPI_INTERFACE)
/*
- * dlpiunbindreq - send a request to unbind.
+ * dlpiunbindreq - send a request to unbind. This function is not actually
+ * used by ISC DHCP, but is included for completeness in case it is
+ * ever required for new work.
*/
static int dlpiunbindreq (fd)
int fd;
/*
- * dlpidetachreq - send a request to detach.
+ * dlpidetachreq - send a request to detach. This function is not actually
+ * used by ISC DHCP, but is included for completeness in case it is
+ * ever required for new work.
*/
static int dlpidetachreq (fd)
int fd;
return putmsg (fd, &ctl, (struct strbuf*)NULL, flags);
}
+#endif /* UNUSED_DLPI_INTERFACE */
/*
#endif
#ifdef USE_DLPI_SEND
+int can_unicast_without_arp PROTO ((struct interface_info *));
+int can_receive_unicast_unconfigured PROTO ((struct interface_info *));
void if_reinitialize_send PROTO ((struct interface_info *));
void if_register_send PROTO ((struct interface_info *));
void if_deregister_send PROTO ((struct interface_info *));
struct packet *, struct dhcp_packet *, size_t,
struct in_addr,
struct sockaddr_in *, struct hardware *));
+int supports_multiple_interfaces (struct interface_info *);
+void maybe_setup_fallback PROTO ((void));
#endif
#ifdef USE_DLPI_RECEIVE
void if_reinitialize_receive PROTO ((struct interface_info *));