Lines Matching refs:p
10 ceph_decode_entity_addr_versioned(void **p, void *end, in ceph_decode_entity_addr_versioned() argument
18 ret = ceph_start_decoding(p, end, 1, "entity_addr_t", &struct_v, in ceph_decode_entity_addr_versioned()
24 struct_end = *p + struct_len; in ceph_decode_entity_addr_versioned()
26 ceph_decode_copy_safe(p, end, &addr->type, sizeof(addr->type), bad); in ceph_decode_entity_addr_versioned()
28 ceph_decode_copy_safe(p, end, &addr->nonce, sizeof(addr->nonce), bad); in ceph_decode_entity_addr_versioned()
30 ceph_decode_32_safe(p, end, addr_len, bad); in ceph_decode_entity_addr_versioned()
36 ceph_decode_copy_safe(p, end, &addr->in_addr, addr_len, bad); in ceph_decode_entity_addr_versioned()
43 *p = struct_end; in ceph_decode_entity_addr_versioned()
50 ceph_decode_entity_addr_legacy(void **p, void *end, in ceph_decode_entity_addr_legacy() argument
56 ceph_decode_skip_n(p, end, 3, bad); in ceph_decode_entity_addr_legacy()
63 ceph_decode_copy_safe(p, end, &addr->nonce, sizeof(addr->nonce), bad); in ceph_decode_entity_addr_legacy()
65 ceph_decode_copy_safe(p, end, &addr->in_addr, in ceph_decode_entity_addr_legacy()
75 ceph_decode_entity_addr(void **p, void *end, struct ceph_entity_addr *addr) in ceph_decode_entity_addr() argument
79 ceph_decode_8_safe(p, end, marker, bad); in ceph_decode_entity_addr()
81 return ceph_decode_entity_addr_versioned(p, end, addr); in ceph_decode_entity_addr()
83 return ceph_decode_entity_addr_legacy(p, end, addr); in ceph_decode_entity_addr()
95 int ceph_decode_entity_addrvec(void **p, void *end, bool msgr2, in ceph_decode_entity_addrvec() argument
107 ceph_decode_8_safe(p, end, marker, e_inval); in ceph_decode_entity_addrvec()
113 ceph_decode_32_safe(p, end, addr_cnt, e_inval); in ceph_decode_entity_addrvec()
118 ret = ceph_decode_entity_addr(p, end, &tmp_addr); in ceph_decode_entity_addrvec()
178 void ceph_encode_entity_addr(void **p, const struct ceph_entity_addr *addr) in ceph_encode_entity_addr() argument
183 ceph_encode_8(p, 1); /* marker */ in ceph_encode_entity_addr()
184 ceph_start_encoding(p, 1, 1, sizeof(addr->type) + in ceph_encode_entity_addr()
187 ceph_encode_copy(p, &addr->type, sizeof(addr->type)); in ceph_encode_entity_addr()
188 ceph_encode_copy(p, &addr->nonce, sizeof(addr->nonce)); in ceph_encode_entity_addr()
190 ceph_encode_32(p, addr_len); in ceph_encode_entity_addr()
191 ceph_encode_16(p, family); in ceph_encode_entity_addr()
192 ceph_encode_copy(p, addr->in_addr.__data, addr_len - sizeof(family)); in ceph_encode_entity_addr()