Lines Matching +full:assigned +full:- +full:addresses
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
69 /* Reserved Ethernet Addresses per IEEE 802.1Q */
81 * is_link_local_ether_addr - Determine if given Ethernet address is link-local
82 * @addr: Pointer to a six-byte array containing the Ethernet address
104 * is_zero_ether_addr - Determine if give Ethernet address is all zeros.
105 * @addr: Pointer to a six-byte array containing the Ethernet address
123 * is_multicast_ether_addr - Determine if the Ethernet address is a multicast.
124 * @addr: Pointer to a six-byte array containing the Ethernet address
137 return 0x01 & (a >> ((sizeof(a) * 8) - 8)); in is_multicast_ether_addr()
157 * is_local_ether_addr - Determine if the Ethernet address is locally-assigned one (IEEE 802).
158 * @addr: Pointer to a six-byte array containing the Ethernet address
168 * is_broadcast_ether_addr - Determine if the Ethernet address is broadcast
169 * @addr: Pointer to a six-byte array containing the Ethernet address
183 * is_unicast_ether_addr - Determine if the Ethernet address is unicast
184 * @addr: Pointer to a six-byte array containing the Ethernet address
194 * is_valid_ether_addr - Determine if the given Ethernet address is valid
195 * @addr: Pointer to a six-byte array containing the Ethernet address
212 * eth_proto_is_802_3 - Determine if a given Ethertype/length is a protocol
230 * eth_random_addr - Generate software assigned random Ethernet address
231 * @addr: Pointer to a six-byte array containing the Ethernet address
234 * and has the local assigned bit set.
244 * eth_broadcast_addr - Assign broadcast address
245 * @addr: Pointer to a six-byte array containing the Ethernet address
255 * eth_zero_addr - Assign zero address
256 * @addr: Pointer to a six-byte array containing the Ethernet address
266 * eth_hw_addr_random - Generate software assigned random Ethernet and
280 dev->addr_assign_type = NET_ADDR_RANDOM; in eth_hw_addr_random()
284 * eth_hw_addr_crc - Calculate CRC from netdev_hw_addr
291 return ether_crc(ETH_ALEN, ha->addr); in eth_hw_addr_crc()
295 * ether_addr_copy - Copy an Ethernet address
296 * @dst: Pointer to a six-byte array Ethernet address destination
297 * @src: Pointer to a six-byte array Ethernet address source
317 * eth_hw_addr_set - Assign Ethernet address to a net_device
329 * eth_hw_addr_inherit - Copy dev_addr from another net_device
339 dst->addr_assign_type = src->addr_assign_type; in eth_hw_addr_inherit()
340 eth_hw_addr_set(dst, src->dev_addr); in eth_hw_addr_inherit()
344 * ether_addr_equal - Compare two Ethernet addresses
345 * @addr1: Pointer to a six-byte array containing the Ethernet address
346 * @addr2: Pointer other six-byte array containing the Ethernet address
348 * Compare two Ethernet addresses, returns true if equal
368 * ether_addr_equal_64bits - Compare two Ethernet addresses
372 * Compare two Ethernet addresses, returns true if equal, false otherwise.
397 * ether_addr_equal_unaligned - Compare two not u16 aligned Ethernet addresses
398 * @addr1: Pointer to a six-byte array containing the Ethernet address
399 * @addr2: Pointer other six-byte array containing the Ethernet address
401 * Compare two Ethernet addresses, returns true if equal
415 * ether_addr_equal_masked - Compare two Ethernet addresses with a mask
416 * @addr1: Pointer to a six-byte array containing the 1st Ethernet address
417 * @addr2: Pointer to a six-byte array containing the 2nd Ethernet address
418 * @mask: Pointer to a six-byte array containing the Ethernet address bitmask
420 * Compare two Ethernet addresses with a mask, returns true if for every bit
421 * set in the bitmask the equivalent bits in the ethernet addresses are equal.
458 * ether_addr_to_u64 - Convert an Ethernet address into a u64 value.
459 * @addr: Pointer to a six-byte array containing the Ethernet address
475 * u64_to_ether_addr - Convert a u64 to an Ethernet address.
477 * @addr: Pointer to a six-byte array to contain the Ethernet address
483 for (i = ETH_ALEN - 1; i >= 0; i--) { in u64_to_ether_addr()
490 * eth_addr_dec - Decrement the given MAC address
492 * @addr: Pointer to a six-byte array containing Ethernet address to decrement
498 u--; in eth_addr_dec()
503 * eth_addr_inc() - Increment the given MAC address.
504 * @addr: Pointer to a six-byte array containing Ethernet address to increment.
515 * eth_addr_add() - Add (or subtract) an offset to/from the given MAC address.
518 * @addr: Pointer to a six-byte array containing Ethernet address to increment.
529 * is_etherdev_addr - Tell if given Ethernet address belongs to the device.
531 * @addr: Pointer to a six-byte array containing the Ethernet address
533 * Compare passed address with all addresses of the device. Return true if the
534 * address if one of the device addresses.
547 res = ether_addr_equal_64bits(addr, ha->addr); in is_etherdev_addr()
557 * compare_ether_header - Compare two Ethernet headers
562 * This assumes that the network header (i.e., IP header) is 4-byte
594 * eth_hw_addr_gen - Generate and assign Ethernet address to a port
601 * addresses for all their ports. addr_assign_type is not changed.
615 * eth_skb_pkt_type - Assign packet type if destination address does not match
616 * @skb: Assigned a packet type if address does not match @dev address
627 if (unlikely(!ether_addr_equal_64bits(eth->h_dest, dev->dev_addr))) { in eth_skb_pkt_type()
628 if (unlikely(is_multicast_ether_addr_64bits(eth->h_dest))) { in eth_skb_pkt_type()
629 if (ether_addr_equal_64bits(eth->h_dest, dev->broadcast)) in eth_skb_pkt_type()
630 skb->pkt_type = PACKET_BROADCAST; in eth_skb_pkt_type()
632 skb->pkt_type = PACKET_MULTICAST; in eth_skb_pkt_type()
634 skb->pkt_type = PACKET_OTHERHOST; in eth_skb_pkt_type()
641 struct ethhdr *eth = (struct ethhdr *)skb->data; in eth_skb_pull_mac()
648 * eth_skb_pad - Pad buffer to minimum number of octets for Ethernet frame