Skip to content

Commit 71df077

Browse files
yuwatakeszybz
authored andcommitted
network: sd-ipv4ll and sd-ipv4acd only support ethernet interfaces
The deny list in link_ipv4ll_enabled() are mostly non-ethernet type, whose link->iftype are not ARPHRD_ETHER, e.g. ARPHRD_NONE for bareudp, ARPHRD_WIREGURAD for wireguard, ARPHRD_GRE for gre, and so on. Only the exception is vrf, which is ARPHRD_ETHER, but seems not to support ARP.
1 parent 014e7df commit 71df077

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/network/networkd-link.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,12 @@ bool link_ipv4ll_enabled(Link *link) {
8787
if (ether_addr_is_null(&link->hw_addr.ether))
8888
return false;
8989

90-
if (STRPTR_IN_SET(link->kind,
91-
"vrf", "wireguard", "ipip", "gre", "ip6gre","ip6tnl", "sit", "vti",
92-
"vti6", "nlmon", "xfrm", "bareudp"))
90+
/* ARPHRD_INFINIBAND seems to potentially support IPv4LL.
91+
* But currently sd-ipv4ll and sd-ipv4acd only support ARPHRD_ETHER. */
92+
if (link->iftype != ARPHRD_ETHER)
93+
return false;
94+
95+
if (streq_ptr(link->kind, "vrf"))
9396
return false;
9497

9598
/* L3 or L3S mode do not support ARP. */

0 commit comments

Comments
 (0)