Home
last modified time | relevance | path

Searched refs:fp (Results 1 – 9 of 9) sorted by relevance

/security/selinux/ss/
Dpolicydb.c976 static int mls_read_range_helper(struct mls_range *r, void *fp) in mls_read_range_helper() argument
982 rc = next_entry(buf, fp, sizeof(u32)); in mls_read_range_helper()
993 rc = next_entry(buf, fp, sizeof(u32) * items); in mls_read_range_helper()
1005 rc = ebitmap_read(&r->level[0].cat, fp); in mls_read_range_helper()
1011 rc = ebitmap_read(&r->level[1].cat, fp); in mls_read_range_helper()
1037 void *fp) in context_read_and_validate() argument
1042 rc = next_entry(buf, fp, sizeof buf); in context_read_and_validate()
1051 rc = mls_read_range_helper(&c->range, fp); in context_read_and_validate()
1075 static int str_read(char **strp, gfp_t flags, void *fp, u32 len) in str_read() argument
1087 rc = next_entry(str, fp, len); in str_read()
[all …]
Dpolicydb.h326 extern int policydb_read(struct policydb *p, void *fp);
327 extern int policydb_write(struct policydb *p, void *fp);
359 void *fp; member
362 static inline int next_entry(void *buf, struct policy_file *fp, size_t bytes) in next_entry() argument
364 if (bytes > fp->len) in next_entry()
367 memcpy(buf, fp->data, bytes); in next_entry()
368 fp->data += bytes; in next_entry()
369 fp->len -= bytes; in next_entry()
373 static inline int put_entry(const void *buf, size_t bytes, int num, struct policy_file *fp) in put_entry() argument
377 if (len > fp->len) in put_entry()
[all …]
Dconditional.c208 int cond_read_bool(struct policydb *p, struct symtab *s, void *fp) in cond_read_bool() argument
220 rc = next_entry(buf, fp, sizeof(buf)); in cond_read_bool()
239 rc = next_entry(key, fp, len); in cond_read_bool()
324 static int cond_read_av_list(struct policydb *p, void *fp, in cond_read_av_list() argument
333 rc = next_entry(buf, fp, sizeof(u32)); in cond_read_av_list()
349 rc = avtab_read_item(&p->te_cond_avtab, fp, p, cond_insertf, in cond_read_av_list()
376 static int cond_read_node(struct policydb *p, struct cond_node *node, void *fp) in cond_read_node() argument
382 rc = next_entry(buf, fp, sizeof(u32) * 2); in cond_read_node()
399 rc = next_entry(buf, fp, sizeof(u32) * 2); in cond_read_node()
410 rc = cond_read_av_list(p, fp, &node->true_list, NULL); in cond_read_node()
[all …]
Davtab.c400 int avtab_read_item(struct avtab *a, void *fp, struct policydb *pol, in avtab_read_item() argument
419 rc = next_entry(buf32, fp, sizeof(u32)); in avtab_read_item()
430 rc = next_entry(buf32, fp, sizeof(u32)*items2); in avtab_read_item()
491 rc = next_entry(buf16, fp, sizeof(u16)*4); in avtab_read_item()
528 rc = next_entry(&xperms.specified, fp, sizeof(u8)); in avtab_read_item()
533 rc = next_entry(&xperms.driver, fp, sizeof(u8)); in avtab_read_item()
538 rc = next_entry(buf32, fp, sizeof(u32)*ARRAY_SIZE(xperms.perms.p)); in avtab_read_item()
547 rc = next_entry(buf32, fp, sizeof(u32)); in avtab_read_item()
568 int avtab_read(struct avtab *a, void *fp, struct policydb *pol) in avtab_read() argument
575 rc = next_entry(buf, fp, sizeof(u32)); in avtab_read()
[all …]
Davtab.h98 int avtab_read_item(struct avtab *a, void *fp, struct policydb *pol,
103 int avtab_read(struct avtab *a, void *fp, struct policydb *pol);
104 int avtab_write_item(struct policydb *p, const struct avtab_node *cur, void *fp);
105 int avtab_write(struct policydb *p, struct avtab *a, void *fp);
Debitmap.c365 int ebitmap_read(struct ebitmap *e, void *fp) in ebitmap_read() argument
377 rc = next_entry(buf, fp, sizeof buf); in ebitmap_read()
405 rc = next_entry(&ebitmap_start, fp, sizeof(u32)); in ebitmap_read()
447 rc = next_entry(&mapbits, fp, sizeof(u64)); in ebitmap_read()
471 int ebitmap_write(struct ebitmap *e, void *fp) in ebitmap_write() argument
494 rc = put_entry(buf, sizeof(u32), 3, fp); in ebitmap_write()
513 rc = put_entry(buf, sizeof(u32), 1, fp); in ebitmap_write()
518 rc = put_entry(buf64, sizeof(u64), 1, fp); in ebitmap_write()
534 rc = put_entry(buf, sizeof(u32), 1, fp); in ebitmap_write()
539 rc = put_entry(buf64, sizeof(u64), 1, fp); in ebitmap_write()
Dconditional.h72 int cond_read_bool(struct policydb *p, struct symtab *s, void *fp);
73 int cond_read_list(struct policydb *p, void *fp);
75 int cond_write_list(struct policydb *p, void *fp);
Debitmap.h132 int ebitmap_read(struct ebitmap *e, void *fp);
133 int ebitmap_write(struct ebitmap *e, void *fp);
Dservices.c2296 struct policy_file file = { data, len }, *fp = &file; in security_load_policy() local
2308 rc = policydb_read(&newpolicy->policydb, fp); in security_load_policy()
4003 struct policy_file fp; in __security_read_policy() local
4005 fp.data = data; in __security_read_policy()
4006 fp.len = *len; in __security_read_policy()
4008 rc = policydb_write(&policy->policydb, &fp); in __security_read_policy()
4012 *len = (unsigned long)fp.data - (unsigned long)data; in __security_read_policy()