bootp
bootp(sock);
void bootp(int);
bootp(netdev_sock);
bootp(sock);
void bootp(int);
bootp(netdev_sock);
bootp(netdev_sock);
bootp(sock);
int bootp(int sock);
bootp(sock);
bootp(sock);
bootp(netdev_sock);
bootp(netdev_sock);
bootp(sock);
bootp(netdev_sock);
bootp(netdev_sock); /* send DHCP request */
bootp(netdev_sock);
bootp(netdev_sock);
bootp(netdev_sock);
bootp(0);
struct bootp *bp;
struct bootp wbootp;
struct bootp rbootp;
struct bootp *bp;
struct bootp *bp;
if (n == -1 || (size_t)n < sizeof(struct bootp) - BOOTP_VENDSIZE)
bp = (struct bootp *)pkt;
extern void bootp(int);
bootp(sock);
#define BOOTP_SIZE_MAX (sizeof(struct bootp)+312-64)
#define BOOTP_SIZE_MAX (sizeof(struct bootp)+256-64)
#define BOOTP_SIZE_MIN (sizeof(struct bootp))
static void bootp_extract (struct bootp *, int, struct nfs_diskless *, int *);
struct bootp *replybuf;
struct bootp *bootp;
bootp = mtod(m, struct bootp*);
bootp->bp_secs = htons(waited);
struct bootp *bootp;
if (m->m_len < offsetof(struct bootp, bp_sname)) {
m = *mp = m_pullup(m, offsetof(struct bootp, bp_sname));
bootp = mtod(m, struct bootp*);
if (bootp->bp_op != BOOTREPLY) {
DPRINTF(("bootpcheck: op %d is not reply\n", bootp->bp_op));
if (bootp->bp_hlen != bpc->halen) {
DPRINTF(("bootpcheck: hlen %d != %d\n", bootp->bp_hlen,
if (memcmp(bootp->bp_chaddr, bpc->haddr, bpc->halen)) {
bootp->bp_chaddr),
if (bootp->bp_xid != bpc->xid) {
DPRINTF(("bootpcheck: xid %d != %d\n", bootp->bp_xid,
bootp = bpc->replybuf;
if (bootp->bp_yiaddr.s_addr == INADDR_ANY ||
bootp->bp_yiaddr.s_addr == INADDR_BROADCAST) {
inet_ntoa(bootp->bp_yiaddr));
if (memcmp(bootp->bp_vend, vm_rfc1048, 4)) {
p = &bootp->bp_vend[4];
limit = ((u_char*)bootp) + bpc->replylen;
printf(" (bad reply from %s)\n", inet_ntoa(bootp->bp_siaddr));
struct bootp *bootp; /* request */
bootp = mtod(m, struct bootp*);
memset((void *)bootp, 0, BOOTP_SIZE_MAX);
bootp->bp_op = BOOTREQUEST;
bootp->bp_htype = hafmt;
bootp->bp_hlen = halen; /* Hardware address length */
bootp->bp_xid = ++xid;
memcpy(bootp->bp_chaddr, haddr, halen);
strncpy(bootp->bp_file, NFS_BOOT_BOOTP_REQFILE, sizeof(bootp->bp_file));
memcpy(bootp->bp_vend, vm_rfc1048, 4);
bootp->bp_vend[index++] = TAG_DHCP_MSGTYPE;
bootp->bp_vend[index++] = 1;
bootp->bp_vend[index++] = DHCPDISCOVER;
bootp_addvend(&bootp->bp_vend[index]);
bootp->bp_vend[index++] = DHCPREQUEST;
bootp->bp_vend[index++] = TAG_REQ_ADDR;
bootp->bp_vend[index++] = 4;
memcpy(&bootp->bp_vend[index], &bpc.replybuf->bp_yiaddr, 4);
bootp->bp_vend[index++] = TAG_SERVERID;
bootp->bp_vend[index++] = 4;
memcpy(&bootp->bp_vend[index], &bpc.dhcp_serverip.s_addr, 4);
bootp->bp_vend[index++] = TAG_LEASETIME;
bootp->bp_vend[index++] = 4;
memcpy(&bootp->bp_vend[index], &leasetime, 4);
bootp_addvend(&bootp->bp_vend[index]);
bootp_extract(struct bootp *bootp, int replylen,
rootserver = bootp->bp_siaddr;
p = &bootp->bp_vend[4];
limit = ((u_char*)bootp) + replylen;
nd->nd_myip = bootp->bp_yiaddr;
if (!overloaded && bootp->bp_sname[0] != 0 &&
!memcmp(&rootserver, &bootp->bp_siaddr,
strncpy(ndm->ndm_host, bootp->bp_sname,
strncpy(nd->nd_bootfile, bootp->bp_file, BOOTFILELEN);
bootp(net_socket);
struct bootp *bp = (struct bootp *) pktbuf;
PRIVATE void dovend_cmu(struct bootp *, struct host *);
PRIVATE void dovend_rfc1048(struct bootp *, struct host *, int32);
dovend_cmu(struct bootp *bp, struct host *hp)
dovend_rfc1048(struct bootp *bp, struct host *hp, int32 bootsize)
struct bootp *bp;
assert(sizeof(struct bootp) == BP_MINPKTSZ);
bp = (struct bootp *) pktbuf;
if (n < (int)sizeof(struct bootp)) {
struct bootp *bp = (struct bootp *) pktbuf;
struct bootp *bp;
assert(sizeof(struct bootp) == BP_MINPKTSZ);
bp = (struct bootp *) pktbuf;
if (n < (int)sizeof(struct bootp)) {
struct bootp *bp = (struct bootp *) pktbuf;
struct bootp *bp = (struct bootp *) pktbuf;
struct bootp *bp;
assert(sizeof(struct bootp) == BP_MINPKTSZ);
bp = (struct bootp *) sndbuf;
if (n < (int)sizeof(struct bootp)) {
bootp_print((struct bootp *)rcvbuf, n, sin_from.sin_port, 0);
bootp_print((struct bootp *)sndbuf, snaplen, sin_from.sin_port, 0);
extern void bootp_print(struct bootp *, int, u_short, u_short);
bootp_print(struct bootp *bp, int length, u_short sport, u_short dport)
if (length != sizeof(struct bootp))