diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2019-07-11 02:23:41 +0900 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2019-07-11 22:22:29 +0900 |
commit | b956364db01264199ff910e994e651730341911e (patch) | |
tree | 17ea18a8a7a62ebab83ecf183738fdd859914801 /src/network/networkd-neighbor.h | |
parent | 49808e0e2d01fd77df2e748de19cb402eb176bb9 (diff) | |
download | systemd-b956364db01264199ff910e994e651730341911e.tar.gz systemd-b956364db01264199ff910e994e651730341911e.tar.bz2 systemd-b956364db01264199ff910e994e651730341911e.zip |
network: rename Neighbor.MACAddress= to Neighbor.LinkLayerAddress=
And make it support IPv4 address.
Closes #13015.
Diffstat (limited to 'src/network/networkd-neighbor.h')
-rw-r--r-- | src/network/networkd-neighbor.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/src/network/networkd-neighbor.h b/src/network/networkd-neighbor.h index f591f0b03f..59cd82ac11 100644 --- a/src/network/networkd-neighbor.h +++ b/src/network/networkd-neighbor.h @@ -15,6 +15,13 @@ typedef struct Neighbor Neighbor; #include "networkd-network.h" #include "networkd-util.h" +typedef enum { + NEIGHBOR_LLADDR_MAC, + NEIGHBOR_LLADDR_IP, + _NEIGHBOR_LLADDR_MAX, + _NEIGHBOR_LLADDR_INVALID = -1, +} NeighborLLAddressType; + struct Neighbor { Network *network; Link *link; @@ -22,8 +29,11 @@ struct Neighbor { int family; union in_addr_union in_addr; - bool mac_configured; - struct ether_addr mac; + union { + struct ether_addr mac; + union in_addr_union ip; + } lladdr; + NeighborLLAddressType lladdr_type; LIST_FIELDS(Neighbor, neighbors); }; @@ -36,3 +46,4 @@ int neighbor_configure(Neighbor *neighbor, Link *link, link_netlink_message_hand CONFIG_PARSER_PROTOTYPE(config_parse_neighbor_address); CONFIG_PARSER_PROTOTYPE(config_parse_neighbor_hwaddr); +CONFIG_PARSER_PROTOTYPE(config_parse_neighbor_lladdr); |