From nobody Sat Apr 27 14:46:09 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4VRXTZ2nWvz5JGB2; Sat, 27 Apr 2024 14:46:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VRXTZ0Zjlz41hL; Sat, 27 Apr 2024 14:46:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1714229170; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BqZLzV8KhdT0sdizWPXKUac9w8HXIv2AHf3WaHvO5vc=; b=N7Bi0S6qfrBbclE6v0nTEzLJqVn1wUg1c+xV9H3NSSah2JJWEOb1gNpFmNkplz68Q8ylg4 Ovx/ao4drvHSqbK3f8g5bKhZwneU0hknRa1IYNSg2jyvrSR54xPSkQ912aS9geMea/oUyQ XPmOgPJABK117ag5Z8t3ZEMS3+9rBosFPScInLSFsdE6QqJhbPQ/uxSyySLtCux8Wnskzi kVeQxKOnUKNDSbonFhgm0hAc++sR5oFX1igiYQnveogl079MlJ2BsBa/kwjQaMOOj4BVU/ RyM3IYo5YPG1MOMeMJr5SBrZTWUzO6uFnNvPsAHN3sU2EMl8l5FhGJWcl7BWcA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1714229170; a=rsa-sha256; cv=none; b=MjcBiz/b7AFPQpRHn99R2YbviFhx1NFnHTtNCPqb+f1g7CVnDH9us4t71Mxfc73JKGAzIM bLqBEsbS5XRBk3CljRnCIdBh5kFiCjtbmqXWyx3SgFcd1DJwCjBaCGvUglXZcJUHGOQnR3 rNbGtq41YVLGqQ5UXHP1BwOpb7nm2nXjwqALtHE5R4ENZkbgYZxeIzQ/6AE3QRndub9Vx1 ZXXEKb24D5jmxj6w93llH0gw42wmlev40vEv9ISU9xi37fIjlgS0rYYhn/Nj2dYk+NIfcA bCvLKDNVWKk1iufm59FD6+Q7QanWQraYJgINhWmOkqeRcJQRXVktbFivqVOidA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1714229170; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=BqZLzV8KhdT0sdizWPXKUac9w8HXIv2AHf3WaHvO5vc=; b=X9ZTAD8ba9wWG+9N8Fx59BBc3492Gf3r4io1Fv/z95g3uhcuMHLmepOs6cTO0ne5uFmeDV HIBSJGq1QJU+HsMC2+DQsfgD+W77/nKeRKWTPisuw0eOzFeacbVasXExKXArF2qSr843YT 66x6JEgMNR/MXkQDfziTYYobLPz7rLtQo/l06JLWKBWQnreclq7AxuLVNVl2vz3KNoKru9 LArYuN4pPp1vuo4hj+ndRyL4Vq6s+t2FdYXlrfNcCJ9QVwQA4sPX6no227PCH1sGNls8P0 g2ATqEokYUj5Ze27UyIiLRO6qoMdPrY4ovt4TwS+XRUKFP6NMLd9Yr3ENdZXiA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4VRXTZ08K4zWF1; Sat, 27 Apr 2024 14:46:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 43REk9KH015229; Sat, 27 Apr 2024 14:46:09 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 43REk9dZ015226; Sat, 27 Apr 2024 14:46:09 GMT (envelope-from git) Date: Sat, 27 Apr 2024 14:46:09 GMT Message-Id: <202404271446.43REk9dZ015226@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ed Maste Subject: git: d776dd5fbd48 - stable/14 - Support ARP for 802 networks List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: emaste X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: d776dd5fbd484acdf00f6df55583e9aa53226859 Auto-Submitted: auto-generated The branch stable/14 has been updated by emaste: URL: https://cgit.FreeBSD.org/src/commit/?id=d776dd5fbd484acdf00f6df55583e9aa53226859 commit d776dd5fbd484acdf00f6df55583e9aa53226859 Author: Denny Page AuthorDate: 2024-04-13 17:16:08 +0000 Commit: Ed Maste CommitDate: 2024-04-27 14:45:22 +0000 Support ARP for 802 networks This is used by 802.3 Ethernet. (Also be used by 802.4 Token Bus and 802.5 Token Ring, but we don't support those.) This was accidentally removed along with FDDI support in commit 0437c8e3b198, presumably because comments implied it was used only by FDDI or Token Ring. Fixes: 0437c8e3b198 ("Remove support for FDDI networks.") Reviewed-by: emaste Signed-off-by: Denny Page Pull-request: https://github.com/freebsd/freebsd-src/pull/1166 (cherry picked from commit fcdf9a19893b9b5beb7a21407de507f0ae4c500b) --- sys/net/if_arp.h | 2 +- sys/netinet/if_ether.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/net/if_arp.h b/sys/net/if_arp.h index 0319807dbfd2..f201fd67cab4 100644 --- a/sys/net/if_arp.h +++ b/sys/net/if_arp.h @@ -47,7 +47,7 @@ struct arphdr { u_short ar_hrd; /* format of hardware address */ #define ARPHRD_ETHER 1 /* ethernet hardware format */ -#define ARPHRD_IEEE802 6 /* token-ring hardware format */ +#define ARPHRD_IEEE802 6 /* 802.2 networks (ethernet/tb/tr) */ #define ARPHRD_FRELAY 15 /* frame relay hardware format */ #define ARPHRD_IEEE1394 24 /* firewire hardware format */ #define ARPHRD_INFINIBAND 32 /* infiniband hardware format */ diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c index df564b210f9b..a14671528f18 100644 --- a/sys/netinet/if_ether.c +++ b/sys/netinet/if_ether.c @@ -684,6 +684,10 @@ arpintr(struct mbuf *m) hlen = ETHER_ADDR_LEN; /* RFC 826 */ layer = "ethernet"; break; + case ARPHRD_IEEE802: + hlen = ETHER_ADDR_LEN; + layer = "ieee802"; + break; case ARPHRD_INFINIBAND: hlen = 20; /* RFC 4391, INFINIBAND_ALEN */ layer = "infiniband";