Lines Matching defs:ea
117 struct ether_arp *ea;
122 if (mbuf_len(m) < sizeof (*ea) && mbuf_pullup(&m, sizeof (*ea)) != 0)
125 ea = mbuf_data(m);
128 if (ntohs(ea->arp_hrd) != ARPHRD_ETHER ||
129 ntohs(ea->arp_pro) != ETHERTYPE_IP ||
130 ea->arp_pln != sizeof (struct in_addr) ||
131 ea->arp_hln != ETHER_ADDR_LEN) {
137 if (bcmp(ea->arp_sha, etherbroadcastaddr, ETHER_ADDR_LEN) == 0) {
145 _ip_copy(&sender_ip.sin_addr, ea->arp_spa);
147 _ip_copy(&target_ip.sin_addr, ea->arp_tpa);
154 bcopy(ea->arp_sha, LLADDR(&sender_hw), ETHER_ADDR_LEN);
159 arp_ip_handle_input(ifp, ntohs(ea->arp_op), &sender_hw, &sender_ip,
407 struct ether_arp *ea;
425 mbuf_setlen(m, sizeof (*ea));
426 mbuf_pkthdr_setlen(m, sizeof (*ea));
432 mbuf_setdata(m, datap, sizeof (*ea));
433 ea = mbuf_data(m);
451 ea->arp_pro = htons(ETHERTYPE_IP);
452 ea->arp_hln = sizeof (ea->arp_sha);
453 ea->arp_pln = sizeof (ea->arp_spa);
454 ea->arp_hrd = htons(ARPHRD_ETHER);
455 ea->arp_op = htons(arpop);
459 bcopy(CONST_LLADDR(sender_hw), ea->arp_sha,
460 sizeof (ea->arp_sha));
462 ifnet_lladdr_copy_bytes(ifp, ea->arp_sha, ETHER_ADDR_LEN);
468 bcopy(&sender_ip->sin_addr, ea->arp_spa, sizeof (ea->arp_spa));
479 ifa->ifa_addr)->sin_addr, ea->arp_spa,
480 sizeof (ea->arp_spa));
496 bzero(ea->arp_tha, sizeof (ea->arp_tha));
500 bcopy(CONST_LLADDR(target_hw), ea->arp_tha,
501 sizeof (ea->arp_tha));
507 bcopy(&target_ip->sin_addr, ea->arp_tpa, sizeof (ea->arp_tpa));