Lines Matching refs:addr
15 const struct hw_addr_data *addr, in hw_addr_to_string_full() argument
19 assert(addr); in hw_addr_to_string_full()
21 assert(addr->length <= HW_ADDR_MAX_SIZE); in hw_addr_to_string_full()
23 for (size_t i = 0, j = 0; i < addr->length; i++) { in hw_addr_to_string_full()
24 buffer[j++] = hexchar(addr->bytes[i] >> 4); in hw_addr_to_string_full()
25 buffer[j++] = hexchar(addr->bytes[i] & 0x0f); in hw_addr_to_string_full()
30 buffer[addr->length == 0 || FLAGS_SET(flags, HW_ADDR_TO_STRING_NO_COLON) ? in hw_addr_to_string_full()
31 addr->length * 2 : in hw_addr_to_string_full()
32 addr->length * 3 - 1] = '\0'; in hw_addr_to_string_full()
60 char* ether_addr_to_string(const struct ether_addr *addr, char buffer[ETHER_ADDR_TO_STRING_MAX]) { in ether_addr_to_string() argument
61 assert(addr); in ether_addr_to_string()
69 addr->ether_addr_octet[0], in ether_addr_to_string()
70 addr->ether_addr_octet[1], in ether_addr_to_string()
71 addr->ether_addr_octet[2], in ether_addr_to_string()
72 addr->ether_addr_octet[3], in ether_addr_to_string()
73 addr->ether_addr_octet[4], in ether_addr_to_string()
74 addr->ether_addr_octet[5]); in ether_addr_to_string()
79 int ether_addr_to_string_alloc(const struct ether_addr *addr, char **ret) { in ether_addr_to_string_alloc() argument
82 assert(addr); in ether_addr_to_string_alloc()
89 ether_addr_to_string(addr, buf); in ether_addr_to_string_alloc()