Lines Matching refs:p

73 static int datablob_parse(char **datablob, struct trusted_key_payload *p)  in datablob_parse()  argument
95 p->key_len = keylen; in datablob_parse()
103 p->blob_len = strlen(c) / 2; in datablob_parse()
104 if (p->blob_len > MAX_BLOB_SIZE) in datablob_parse()
106 ret = hex2bin(p->blob, c, p->blob_len); in datablob_parse()
122 struct trusted_key_payload *p = NULL; in trusted_payload_alloc() local
125 ret = key_payload_reserve(key, sizeof(*p)); in trusted_payload_alloc()
128 p = kzalloc(sizeof(*p), GFP_KERNEL); in trusted_payload_alloc()
129 if (!p) in trusted_payload_alloc()
132 p->migratable = migratable; in trusted_payload_alloc()
134 return p; in trusted_payload_alloc()
217 struct trusted_key_payload *p; in trusted_rcu_free() local
219 p = container_of(rcu, struct trusted_key_payload, rcu); in trusted_rcu_free()
220 kfree_sensitive(p); in trusted_rcu_free()
228 struct trusted_key_payload *p; in trusted_update() local
236 p = key->payload.data[0]; in trusted_update()
237 if (!p->migratable) in trusted_update()
262 new_p->migratable = p->migratable; in trusted_update()
263 new_p->key_len = p->key_len; in trusted_update()
264 memcpy(new_p->key, p->key, p->key_len); in trusted_update()
265 dump_payload(p); in trusted_update()
276 call_rcu(&p->rcu, trusted_rcu_free); in trusted_update()
289 const struct trusted_key_payload *p; in trusted_read() local
293 p = dereference_key_locked(key); in trusted_read()
294 if (!p) in trusted_read()
297 if (buffer && buflen >= 2 * p->blob_len) { in trusted_read()
299 for (i = 0; i < p->blob_len; i++) in trusted_read()
300 bufp = hex_byte_pack(bufp, p->blob[i]); in trusted_read()
302 return 2 * p->blob_len; in trusted_read()