Deleted Added
full compact
if_ether.c (109409) if_ether.c (109623)
1/*
2 * Copyright (c) 1982, 1986, 1988, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)if_ether.c 8.1 (Berkeley) 6/10/93
1/*
2 * Copyright (c) 1982, 1986, 1988, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)if_ether.c 8.1 (Berkeley) 6/10/93
34 * $FreeBSD: head/sys/netinet/if_ether.c 109409 2003-01-17 07:59:35Z hsu $
34 * $FreeBSD: head/sys/netinet/if_ether.c 109623 2003-01-21 08:56:16Z alfred $
35 */
36
37/*
38 * Ethernet address resolution protocol.
39 * TODO:
40 * add "inuse/lock" bit (or ref. count) along with valid bit
41 */
42

--- 269 unchanged lines hidden (view full) ---

312 register struct ether_header *eh;
313 register struct arc_header *arh;
314 register struct arphdr *ah;
315 struct sockaddr sa;
316 static u_char llcx[] = { 0x82, 0x40, LLC_SNAP_LSAP, LLC_SNAP_LSAP,
317 LLC_UI, 0x00, 0x00, 0x00, 0x08, 0x06 };
318 u_short ar_hrd;
319
35 */
36
37/*
38 * Ethernet address resolution protocol.
39 * TODO:
40 * add "inuse/lock" bit (or ref. count) along with valid bit
41 */
42

--- 269 unchanged lines hidden (view full) ---

312 register struct ether_header *eh;
313 register struct arc_header *arh;
314 register struct arphdr *ah;
315 struct sockaddr sa;
316 static u_char llcx[] = { 0x82, 0x40, LLC_SNAP_LSAP, LLC_SNAP_LSAP,
317 LLC_UI, 0x00, 0x00, 0x00, 0x08, 0x06 };
318 u_short ar_hrd;
319
320 if ((m = m_gethdr(M_DONTWAIT, MT_DATA)) == NULL)
320 if ((m = m_gethdr(M_NOWAIT, MT_DATA)) == NULL)
321 return;
322 m->m_pkthdr.rcvif = (struct ifnet *)0;
323#ifdef MAC
324 mac_create_mbuf_linklayer(ifp, m);
325#endif
326 switch (ifp->if_type) {
327 case IFT_ARCNET:
328 ar_hrd = htons(ARPHRD_ARCNET);

--- 644 unchanged lines hidden ---
321 return;
322 m->m_pkthdr.rcvif = (struct ifnet *)0;
323#ifdef MAC
324 mac_create_mbuf_linklayer(ifp, m);
325#endif
326 switch (ifp->if_type) {
327 case IFT_ARCNET:
328 ar_hrd = htons(ARPHRD_ARCNET);

--- 644 unchanged lines hidden ---