History log of /freebsd-current/sys/net/ethernet.h
Revision Date Author Comments
# 3878bbf1 04-Nov-2023 Ronald Klop <ronald@FreeBSD.org>

Teach if_smsc to get MAC from bootargs.

Some Raspberry Pi pass smsc95xx.macaddr=XX:XX:XX:XX:XX:XX as bootargs.
Use this if no ethernet address is found in an EEPROM.
As last resort fall back to ether_gen_addr() instead of random MAC.

PR: 274092
Reported by: Patrick M. Hausen (via ML)
Reviewed by: imp, karels, zlei
Tested by: Patrick M. Hausen
Approved by: karels
MFC after: 1 month
Relnotes: yes
Differential Revision: https://reviews.freebsd.org/D42463


# 838c8c47 23-Aug-2023 Zhenlei Huang <zlei@FreeBSD.org>

net: Do not overwrite if_vlan's PCP

In commit c7cffd65c5d8 the function ether_8021q_frame() was slightly
refactored to use pointer of struct ether_8021q_tag as parameter qtag to
include the new option proto.

It is wrong to write to qtag->pcp as it will effectively change the memory
that qtag points to. Unfortunately the transmit routine of if_vlan parses
pointer of the member ifv_qtag of its softc which stores vlan interface's
PCP internally, when transmitting mbufs that contains PCP the vlan
interface's PCP will get overwritten.

Fix by operating on a local copy of qtag->pcp. Also mark 'struct ether_8021q_tag'
as const so that compilers can pick up such kind of bug.

PR: 273304
Reviewed by: kp
Fixes: c7cffd65c5d85 Add support for stacked VLANs (IEEE 802.1ad, AKA Q-in-Q)
MFC after: 3 days
Differential Revision: https://reviews.freebsd.org/D39505


# 95ee2897 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

sys: Remove $FreeBSD$: two-line .h pattern

Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/


# d862b165 10-Apr-2023 Mark Johnston <markj@FreeBSD.org>

bridge: Add support for emulated netmap mode

if_bridge receives packets via a special interface, if_bridge_input,
rather than by if_input. Thus, netmap's usual hooking of ifnet routines
does not work as expected. Instead, modify bridge_input() to pass
packets directly to netmap when it is enabled. This applies to both
locally delivered packets and forwarded packets.

When a netmap application transmits a packet by writing it to the host
TX ring, the mbuf chain is passed to if_input, which ordinarily points
to ether_input(). However, when transmitting via if_bridge,
bridge_input() needs to see the packet again in order to decide whether
to deliver or forward. Thus, introduce a new protocol flag,
M_BRIDGE_INJECT, which 1) causes the packet to be passed to
bridge_input() again after Ethernet processing, and 2) avoids passing
the packet back to netmap. The source MAC address of the packet is used
to determine the original "receiving" interface.

Reviewed by: vmaffione
MFC after: 2 months
Sponsored by: Zenarmor
Sponsored by: OPNsense
Sponsored by: Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D38066


# 950cc1f4 12-Jan-2023 Justin Hibbits <jhibbits@FreeBSD.org>

bpf: Add "_if" tap APIs

Summary:
Hide more netstack by making the BPF_TAP macros real functions in the
netstack. "struct ifnet" is used in the header instead of "if_t" to
keep header pollution down.

Sponsored by: Juniper Networks, Inc.
Differential Revision: https://reviews.freebsd.org/D38103


# cba46da5 02-Apr-2022 Gordon Bergling <gbe@FreeBSD.org>

net(3): Fix a typo in a source code comment

- s/verion/version/

MFC after: 3 days


# f4096a7c 15-Dec-2021 Kristof Provost <kp@FreeBSD.org>

net: make ethernet.h self-contained

Reviewed by: imp
Sponsored by: Rubicon Communications, LLC ("Netgate")
Differential Revision: https://reviews.freebsd.org/D33501


# 0ea8a7f3 29-Apr-2021 Jose Luis Duran <jlduran@gmail.com>

ifconfig: Minor documentation fix

Fix what appears to have been a small copy/paste typo in ifconfig(8)'s
documentation (man page and header file).

Not that it matters anymore.

Reference: Table I-2 in IEEE Std 802.1Q-2014.

PR: 255557
Submitted by: Jose Luis Duran <jlduran@gmail.com>
MFC after: 1 week


# 38c09513 21-Feb-2021 Kristof Provost <kp@FreeBSD.org>

bridge: Remove members when assigned to a new vnet

When the bridge is moved to a different vnet we must remove all of its
member interfaces (and span interfaces), because we don't know if those
will be moved along with it. We don't want to hold references to
interfaces not in our vnet.

Reviewed by: donner@
MFC after: 1 week
Sponsored by: Orange Business Services
Differential Revision: https://reviews.freebsd.org/D28859


# ced0f524 30-Oct-2020 Mitchell Horne <mhorne@FreeBSD.org>

net: add ETHER_IS_IPV6_MULTICAST

This can be used to detect if an ethernet address is specifically an
IPv6 multicast address, defined in accordance to RFC 2464.

ETHER_IS_MULTICAST is still preferred in the general case.

Reviewed by: ae
Sponsored by: NetApp, Inc.
Sponsored by: Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D26611


# c7cffd65 21-Oct-2020 Alexander V. Chernikov <melifaro@FreeBSD.org>

Add support for stacked VLANs (IEEE 802.1ad, AKA Q-in-Q).

802.1ad interfaces are created with ifconfig using the "vlanproto" parameter.
Eg., the following creates a 802.1Q VLAN (id #42) over a 802.1ad S-VLAN
(id #5) over a physical Ethernet interface (em0).

ifconfig vlan5 create vlandev em0 vlan 5 vlanproto 802.1ad up
ifconfig vlan42 create vlandev vlan5 vlan 42 inet 10.5.42.1/24

VLAN_MTU, VLAN_HWCSUM and VLAN_TSO capabilities should be properly
supported. VLAN_HWTAGGING is only partially supported, as there is
currently no IFCAP_VLAN_* denoting the possibility to set the VLAN
EtherType to anything else than 0x8100 (802.1ad uses 0x88A8).

Submitted by: Olivier Piras
Sponsored by: RG Nets
Differential Revision: https://reviews.freebsd.org/D26436


# a1b769b3 07-Feb-2020 Pedro F. Giffuni <pfg@FreeBSD.org>

typo: stray spaces.

No functional change


# abfc5e85 05-Feb-2020 Pedro F. Giffuni <pfg@FreeBSD.org>

ethernet: Add a couple more Ethertypes.

Powerlink and Sercos III are used in automation. Both have been standardized
and In the case of Ethernet Powerlink there is a BSD-licensed stack.


# 2a1481fb 02-Feb-2020 Pedro F. Giffuni <pfg@FreeBSD.org>

typo: Registration.

Pointed by: Dikshie Fauzie


# ad2b6d4e 02-Feb-2020 Pedro F. Giffuni <pfg@FreeBSD.org>

ethernet: Minor cleanup.
Consistently use uppercase for ethertype hex numbers.


# b33c1977 02-Feb-2020 Pedro F. Giffuni <pfg@FreeBSD.org>

style(9): Fix spaces after #define.

No functional change.


# 682397c2 02-Feb-2020 Pedro F. Giffuni <pfg@FreeBSD.org>

ethernet: add some more Ethertypes.

Sort ETHERTYPE_FCOE, from r357414.


# badbcf06 02-Feb-2020 Pedro F. Giffuni <pfg@FreeBSD.org>

ethernet: add some more Ethertypes.

Add some types based on other BSDs and also add EtherCat and PROFINET, which
are IEC standards.

There is a public list (CSV format) at:
https://standards.ieee.org/products-services/regauth/

MFC after: 2 weeks


# 74954211 04-Nov-2019 Eric Joyner <erj@FreeBSD.org>

net: add ETHER_IS_ZERO macro similar to ETHER_IS_BROADCAST

Some places in network code may need to verify that an ethernet address
is not the 'zero' address. Provide a standard macro ETHER_IS_ZERO for
this purpose, similar to the ETHER_IS_BROADCAST macro already available.

This patch also removes previous ETHER_IS_ZERO definitions in several
USB ethernet drivers, in favor of this centrally-located macro.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>

Submitted by: Jacob Keller <jacob.e.keller@intel.com>
Reviewed by: erj@
Sponsored by: Intel Corporation
Differential Revision: https://reviews.freebsd.org/D21240


# 579b70db 16-Oct-2019 Philip Paeps <philip@FreeBSD.org>

ether: add older ethertype definitions for QinQ

Older network equipment used the ethertypes 0x9100, 0x9200, and 0x9300 for
outer VLANs, before standardisation introduced 0x88a8.

Submitted by: Lutz Donnerhacke <lutz_donnerhacke.de>
Differential Revision: https://reviews.freebsd.org/D21846


# e2e050c8 19-May-2019 Conrad Meyer <cem@FreeBSD.org>

Extract eventfilter declarations to sys/_eventfilter.h

This allows replacing "sys/eventfilter.h" includes with "sys/_eventfilter.h"
in other header files (e.g., sys/{bus,conf,cpu}.h) and reduces header
pollution substantially.

EVENTHANDLER_DECLARE and EVENTHANDLER_LIST_DECLAREs were moved out of .c
files into appropriate headers (e.g., sys/proc.h, powernv/opal.h).

As a side effect of reduced header pollution, many .c files and headers no
longer contain needed definitions. The remainder of the patch addresses
adding appropriate includes to fix those files.

LOCK_DEBUG and LOCK_FILE_LINE_ARG are moved to sys/_lock.h, as required by
sys/mutex.h since r326106 (but silently protected by header pollution prior
to this change).

No functional change (intended). Of course, any out of tree modules that
relied on header pollution for sys/eventhandler.h, sys/lock.h, or
sys/mutex.h inclusion need to be fixed. __FreeBSD_version has been bumped.


# 3c3aa8c1 17-Apr-2019 Kyle Evans <kevans@FreeBSD.org>

net: adjust randomized address bits

Give devices that need a MAC a 16-bit allocation out of the FreeBSD
Foundation OUI range. Change the name ether_fakeaddr to ether_gen_addr now
that we're dealing real MAC addresses with a real OUI rather than random
locally-administered addresses.

Reviewed by: bz, rgrimes
Differential Revision: https://reviews.freebsd.org/D19587


# 6b7e0c1c 14-Mar-2019 Kyle Evans <kevans@FreeBSD.org>

ether: centralize fake hwaddr generation

We currently have two places with identical fake hwaddr generation --
if_vxlan and if_bridge. Lift it into if_ethersubr for reuse in other
interfaces that may also need a fake addr.

Reviewed by: bryanv, kp, philip
Differential Revision: https://reviews.freebsd.org/D19573


# f1379734 27-Mar-2018 Konstantin Belousov <kib@FreeBSD.org>

Allow to specify PCP on packets not belonging to any VLAN.

According to 802.1Q-2014, VLAN tagged packets with VLAN id 0 should be
considered as untagged, and only PCP and DEI values from the VLAN tag
are meaningful. See for instance
https://www.cisco.com/c/en/us/td/docs/switches/connectedgrid/cg-switch-sw-master/software/configuration/guide/vlan0/b_vlan_0.html.

Make it possible to specify PCP value for outgoing packets on an
ethernet interface. When PCP is supplied, the tag is appended, VLAN
id set to 0, and PCP is filled by the supplied value. The code to do
VLAN tag encapsulation is refactored from the if_vlan.c and moved into
if_ethersubr.c.

Drivers might have issues with filtering VID 0 packets on
receive. This bug should be fixed for each driver.

Reviewed by: ae (previous version), hselasky, melifaro
Sponsored by: Mellanox Technologies
MFC after: 2 weeks
Differential revision: https://reviews.freebsd.org/D14702


# 6d5948bb 05-Mar-2018 Andrey V. Elsukov <ae@FreeBSD.org>

Define ethernet type 0x88A8 as ETHERTYPE_QINQ.

Reviewed by: kp
Obtained from: OpenBSD
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D14593


# 8819ad85 23-Jul-2017 Sepherosa Ziehau <sephe@FreeBSD.org>

ethernet: Add ethernet interface attached event and devctl notification.

ifnet_arrival_event may not be adequate under certain situation; e.g.
when the LLADDR is needed. So the ethernet ifattach event is announced
after all necessary bits are setup.

MFC after: 3 days
Sponsored by: Microsoft
Differential Revision: https://reviews.freebsd.org/D11617


# ae0669e3 18-May-2017 Sepherosa Ziehau <sephe@FreeBSD.org>

net/vlan: Revert 305177

Miss read the parentheses.

Reported by: oleg@
Reviewed by: hps@
MFC after: 3 days
Sponsored by: Microsoft


# f320cbed 01-Sep-2016 Sepherosa Ziehau <sephe@FreeBSD.org>

net/vlan: Shift for pri is 13 (pri mask 0xe000) not 1.

Reviewed by: araujo, hps
MFC after: 1 week
Sponsored by: Microsoft
Differential Revision: https://reviews.freebsd.org/D7710


# eb81dc79 06-Aug-2016 Adrian Chadd <adrian@FreeBSD.org>

Extract out the various local definitions of ETHER_IS_BROADCAST() and
turn them into a shared definition.

Set M_MCAST/M_BCAST appropriately upon packet reception in net80211, just
before they are delivered up to the ethernet stack.

Submitted by: rstone


# cd4a821c 28-Mar-2016 George V. Neville-Neil <gnn@FreeBSD.org>

Add ethertype reserved for network testing

MFC after: 2 weeks


# 00f22c06 11-Nov-2014 Gleb Smirnoff <glebius@FreeBSD.org>

Move struct ether_vlan_header to ethernet.h, out of if_vlan_var.h,
since this structure is protocol definition, not part of implementation.


# 033074c4 09-Nov-2014 Alexander V. Chernikov <melifaro@FreeBSD.org>

Replace 'struct route *' if_output() argument with 'struct nhop_info *'.
Leave 'struct route' as is for legacy routing api users.
Remove most of rtalloc_ign*-derived functions.


# 47e8d432 25-Apr-2013 Gleb Smirnoff <glebius@FreeBSD.org>

Add const qualifier to the dst parameter of the ifnet if_output method.


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# 279aa3d4 16-Apr-2009 Kip Macy <kmacy@FreeBSD.org>

Change if_output to take a struct route as its fourth argument in order
to allow passing a cached struct llentry * down to L2

Reviewed by: rwatson


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# d54d93ac 27-Aug-2008 Ed Maste <emaste@FreeBSD.org>

Move CTASSERT of ether header sizes out of the header file and into
if_ethersubr.c. CTASSERT is implemented using a dummy typedef, which if
used in a header file may conflict with another CTASSERT in a source file
using that header.

I'll make a note of this in CTASSERT's man page.

Approved by: imp


# 99cba684 15-May-2008 Sean Farley <scf@FreeBSD.org>

Spelling and capitalization fixes.

MFC after: 3 days


# a0cf8186 18-Oct-2007 Andrew Thompson <thompsa@FreeBSD.org>

Use a uint16_t type for the vlan tag rather an int.


# 60e87ca8 18-Oct-2007 Andrew Thompson <thompsa@FreeBSD.org>

The bridging output function puts the mbuf directly on the interfaces send
queue so the output network card must support the same tagging mechanism as
how the frame was input (prepended Ethernet header tag or stripped HW mflag).

Now the vlan Ethernet header is _always_ stripped in ether_input and the mbuf
flagged, only only network cards with VLAN_HWTAGGING enabled would properly
re-tag any outgoing vlan frames.

If the outgoing interface does not support hardware tagging then readd the vlan
header to the front of the frame. Move the common vlan encapsulation in to
ether_vlanencap().

Reported by: Erik Osterholm, Jon Otterholm
MFC after: 1 week


# 995c7fd1 28-May-2007 Yaroslav Tykhiy <ytykhiy@gmail.com>

Sync ether_ioctl() with ioctl(2) and ifnet.if_ioctl
as to the type of the command argument: int -> u_long.
These types have different widths in the 64-bit world.

Add a note to UPDATING because the change breaks KBI
on 64-bit platforms.

Discussed on: -net, -current
Reviewed by: bms, ru


# 78cfb6a0 13-May-2007 Robert Watson <rwatson@FreeBSD.org>

Add prototypes for ether_aton_r() and ether_ntoa_r() missed in previous
commit.


# a949987d 06-Mar-2007 Bruce M Simpson <bms@FreeBSD.org>

Add Ethertype for 802.3ad LACP.


# 8d8d78c2 01-Jan-2007 Christian S.J. Peron <csjp@FreeBSD.org>

style(9) nit. Prefer struct[space]name[space]{ to make grep searches more
in line with that we find in the rest of the tree.


# a20538a0 01-Dec-2006 Warner Losh <imp@FreeBSD.org>

Use CTASSERT to make sure:
sizeof ether_header is 2 * ETHER_ADDR_LEN + 2 (14) bytes long
sizeof ether_addr is ETHER_ADDR_LEN bytes long

On arm, this shows that struct ether_addr needs to be __packed.

The first condition muts be true for the bridging code to not dump core.
The second one appears to be implicitly relied upon by wi (but many
of the rids it sends down likely need __packed too to be safe) and
maybe others. It appears to not hurt anything.


# fa5c72f5 18-Nov-2006 Christian S.J. Peron <csjp@FreeBSD.org>

Fix typo in comment

Pointed out by: ru


# 52f1277e 18-Nov-2006 Christian S.J. Peron <csjp@FreeBSD.org>

Currently, drivers that support hardware offload of VLAN tag
processing are forced to toggle this functionality when the card
is put in and out of promiscuous mode. The main reason for this
is because the hardware strips the VLAN tag, making it impossible
for the tag information to show up in network diagnostic tools like
tcpdump(1).

This change introduces ether_vlan_mtap(), which is called if the
mbuf has M_VLANTAG set. VLAN information is extracted from the
mbuf and inserted into a stack allocated ether vlan header which
is then inserted through the bpf machinery via bpf_mtap2(). The
original mbuf's data pointer and lengths are temporarily adjusted
to eliminate the original Ethernet header for the duration of the
tap operation. This should have no long term effects on the mbuf.

Also, define a new macro, ETHER_BPF_MTAP which should be used
by drivers which support hardware offload of VLAN tag processing.

The fixes for the relevant drivers will follow shortly.

Discussed with: rwatson, andre, jhb (and others)
Much feedback from: sam, ru
MFC after: 1 month [1]

[1] The version that is eventually MFCed will be somewhat
different then this, as there has been significant work
done to the VLAN code in HEAD.


# fdc63545 18-Nov-2006 Sam Leffler <sam@FreeBSD.org>

mark struct ether_header packed so gcc honors alignment
constratins on arm; this fixes bridging when packets are
rx'd so ip headers are 32-bit aligned

Reviewed by: imp (and discussed elsewhere)
MFC after: 2 weeks


# 0cc8f89a 05-Oct-2004 Sam Leffler <sam@FreeBSD.org>

add ETHERTYPE_PAE for EAPOL/802.1x


# 16b4a343 02-Jun-2004 Christian Weisgerber <naddy@FreeBSD.org>

Add helper functions to calculate the standard ethernet CRC in
little/big endian fashion, so that network drivers can just reference
the standard implementation and don't have to bring their own.

As discussed on arch@.

Obtained from: NetBSD


# eef6f897 14-Nov-2002 Sam Leffler <sam@FreeBSD.org>

general cleanups mostly aimed at improving portability of drivers

o ETHER_* (ETHER_ALIGN, ETHER_MAX_FRAME, ETHER_CRC_LEN, etc.)
o M_HASFCS for drivers to indicate packets include FCS
o remove global declarations for ng_ether* and vlan_* since these
represent a private contract between the if_ethersubr.c code and
certain parts of the system that should not normally be abused
o add ether_* declarations that were elsewhere
o remove ETHER_BPF_* since they are no longer used with the parameter
no longer passed to ether_ifattach and ether_ifdetach

Reviewed by: many
Approved by: re


# d04c7d51 06-Sep-2002 Maxim Sobolev <sobomax@FreeBSD.org>

Add more ethernet types and move AppleTalk types into proper location.

Obtained from: NetBSD (syssrc/sys/net/ethertypes.h, rev.1.13)


# 7d3e4c6e 03-Apr-2002 Luigi Rizzo <luigi@FreeBSD.org>

Fix a couple of incorrect m_free() vs. m_freem() usages and related issues.

Reviewed-by: brooks


# 929ddbbb 19-Mar-2002 Alfred Perlstein <alfred@FreeBSD.org>

Remove __P.


# 437e48e9 03-Dec-2001 Brooks Davis <brooks@FreeBSD.org>

Don't pass an interface pointer to VLAN_INPUT{,_TAG}. Get it from the
mbuf instead.

Suggested by: fenner


# 9d4fe4b2 05-Sep-2001 Brooks Davis <brooks@FreeBSD.org>

Make vlan(4) loadable, unloadable, and clonable. As a side effect,
interfaces must now always enable VLAN support.

Reviewed by: jlemon
MFC after: 3 weeks


# 6e641683 18-Jul-2000 Archie Cobbs <archie@FreeBSD.org>

Const'ify parameters to ethers(3) routines as appropriate.


# 21b8ebd9 13-Jul-2000 Archie Cobbs <archie@FreeBSD.org>

Make all Ethernet drivers attach using ether_ifattach() and detach using
ether_ifdetach().

The former consolidates the operations of if_attach(), ng_ether_attach(),
and bpfattach(). The latter consolidates the corresponding detach operations.

Reviewed by: julian, freebsd-net


# 44ce4b7d 29-Jun-2000 Archie Cobbs <archie@FreeBSD.org>

Provide forward declarations for struct ifnet and struct mbuf
to avoid compiler warnings.


# e1e1452d 26-Jun-2000 Archie Cobbs <archie@FreeBSD.org>

Make the ng_ether(4) node type dynamically loadable like the rest.
This means 'options NETGRAPH' is no longer necessary in order to get
netgraph-enabled Ethernet interfaces. This supports loading/unloading
the ng_ether.ko and attaching/detaching the Ethernet interface in any
order.

Add two new hooks 'upper' and 'lower' to allow access to the protocol
demux engine and the raw device, respectively. This enables bridging
to be defined as a netgraph node, if so desired.

Reviewed by: freebsd-net@freebsd.org


# 664a31e4 28-Dec-1999 Peter Wemm <peter@FreeBSD.org>

Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL"
is an application space macro and the applications are supposed to be free
to use it as they please (but cannot). This is consistant with the other
BSD's who made this change quite some time ago. More commits to come.


# 76429de4 05-Nov-1999 Yoshinobu Inoue <shin@FreeBSD.org>

KAME related header files additions and merges.
(only those which don't affect c source files so much)

Reviewed by: cvs-committers
Obtained from: KAME project


# c3aac50f 27-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


# 2cc2df49 17-Mar-1998 Garrett Wollman <wollman@FreeBSD.org>

Add preliminary support for IEEE 802.1Q VLAN tagging. It doesn't actually
work reliably yet (I've had panics), but it does seem to occasionally
be able to transmit and receive syntactically-correct packets.
Also fixes one of if_ethersubr.c's legion style bugs, and removes
the hostcache code from standard kernels---the code that depends on it
is not going to happen any time soon, I'm afraid.


# 6875d254 22-Feb-1997 Peter Wemm <peter@FreeBSD.org>

Back out part 1 of the MCFH that changed $Id$ to $FreeBSD$. We are not
ready for it yet.


# 1130b656 14-Jan-1997 Jordan K. Hubbard <jkh@FreeBSD.org>

Make the long-awaited change from $Id$ to $FreeBSD$

This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.


# 9cb3aff2 03-Jan-1997 Garrett Wollman <wollman@FreeBSD.org>

Move the ethertypes from <netinet/if_ether.h> to <net/ethernet.h>.
Many programs need the numbers but don't need the internals of ARP.

More commits to follow...


# 32341648 19-Dec-1996 Bruce Evans <bde@FreeBSD.org>

More cleanups to satisfy the following rules:
- C++ should be supported for application functions (use __BEGIN_DECLS,
etc.).
- prototypes should be sorted.
- comments on #endif's should spell identifiers the same as the code.
- comments on #endif's should have the same sense as the code (use `!'
to match ifndef, etc.).


# 992af1d0 19-Dec-1996 Garrett Wollman <wollman@FreeBSD.org>

Clean up Bill's additions.


# 18fe1007 18-Dec-1996 Bill Paul <wpaul@FreeBSD.org>

Add prototypes for ethers.3 functions as per wollman:

> wollman 96/12/10 09:19:15
>
> Modified: lib/libc/net ether_addr.c ethers.3
> Log:
> Get struct ether_addr directly from <net/ethernet.h> rather than pulling
> in lots of unrelated junk from <net/if.h> and <net/if_ether.h>. These
> functions still aren't prototyped anywhere (but should be in
> <net/ethernet.h>---got that, Bill?).

(Note that this file has no copyright header; one should probably
be added.)


# 26a8b0bf 06-Aug-1996 Poul-Henning Kamp <phk@FreeBSD.org>

Megacommit to straigthen out ETHER_ mess.

I'm pretty convinced after looking at this that the majority of our
drivers are confused about the in/exclusion of ETHER_CRC_LEN :-(


# e4b54c02 05-Aug-1996 Poul-Henning Kamp <phk@FreeBSD.org>

This file is the (intended) definitive source of the ETHER_ macros.