Lines Matching refs:key
185 static int perm_destroy(void *key, void *datum, void *p) in perm_destroy() argument
187 kfree(key); in perm_destroy()
192 static int common_destroy(void *key, void *datum, void *p) in common_destroy() argument
196 kfree(key); in common_destroy()
219 static int cls_destroy(void *key, void *datum, void *p) in cls_destroy() argument
225 kfree(key); in cls_destroy()
261 static int role_destroy(void *key, void *datum, void *p) in role_destroy() argument
265 kfree(key); in role_destroy()
275 static int type_destroy(void *key, void *datum, void *p) in type_destroy() argument
277 kfree(key); in type_destroy()
282 static int user_destroy(void *key, void *datum, void *p) in user_destroy() argument
286 kfree(key); in user_destroy()
298 static int sens_destroy(void *key, void *datum, void *p) in sens_destroy() argument
302 kfree(key); in sens_destroy()
313 static int cat_destroy(void *key, void *datum, void *p) in cat_destroy() argument
315 kfree(key); in cat_destroy()
320 static int (*destroy_f[SYM_NUM]) (void *key, void *datum, void *datap) =
332 static int filenametr_destroy(void *key, void *datum, void *p) in filenametr_destroy() argument
334 struct filename_trans *ft = key; in filenametr_destroy()
337 kfree(key); in filenametr_destroy()
343 static int range_tr_destroy(void *key, void *datum, void *p) in range_tr_destroy() argument
347 kfree(key); in range_tr_destroy()
373 char *key = NULL; in roles_init() local
387 key = kstrdup(OBJECT_R, GFP_KERNEL); in roles_init()
388 if (!key) in roles_init()
391 rc = hashtab_insert(p->p_roles.table, key, role); in roles_init()
397 kfree(key); in roles_init()
441 const struct range_trans *key = k; in rangetr_hash() local
443 return (key->source_type + (key->target_type << 3) + in rangetr_hash()
444 (key->target_class << 5)) & (h->size - 1); in rangetr_hash()
530 static int common_index(void *key, void *datum, void *datap) in common_index() argument
540 p->sym_val_to_name[SYM_COMMONS][comdatum->value - 1] = key; in common_index()
545 static int class_index(void *key, void *datum, void *datap) in class_index() argument
555 p->sym_val_to_name[SYM_CLASSES][cladatum->value - 1] = key; in class_index()
560 static int role_index(void *key, void *datum, void *datap) in role_index() argument
572 p->sym_val_to_name[SYM_ROLES][role->value - 1] = key; in role_index()
577 static int type_index(void *key, void *datum, void *datap) in type_index() argument
590 p->sym_val_to_name[SYM_TYPES][typdatum->value - 1] = key; in type_index()
597 static int user_index(void *key, void *datum, void *datap) in user_index() argument
609 p->sym_val_to_name[SYM_USERS][usrdatum->value - 1] = key; in user_index()
614 static int sens_index(void *key, void *datum, void *datap) in sens_index() argument
627 p->sym_val_to_name[SYM_LEVELS][levdatum->level->sens - 1] = key; in sens_index()
633 static int cat_index(void *key, void *datum, void *datap) in cat_index() argument
645 p->sym_val_to_name[SYM_CATS][catdatum->value - 1] = key; in cat_index()
651 static int (*index_f[SYM_NUM]) (void *key, void *datum, void *datap) =
1089 char *key = NULL; in perm_read() local
1106 rc = str_read(&key, GFP_KERNEL, fp, len); in perm_read()
1110 rc = hashtab_insert(h, key, perdatum); in perm_read()
1116 perm_destroy(key, perdatum, NULL); in perm_read()
1122 char *key = NULL; in common_read() local
1145 rc = str_read(&key, GFP_KERNEL, fp, len); in common_read()
1155 rc = hashtab_insert(h, key, comdatum); in common_read()
1160 common_destroy(key, comdatum, NULL); in common_read()
1287 char *key = NULL; in class_read() local
1313 rc = str_read(&key, GFP_KERNEL, fp, len); in class_read()
1369 rc = hashtab_insert(h, key, cladatum); in class_read()
1375 cls_destroy(key, cladatum, NULL); in class_read()
1381 char *key = NULL; in role_read() local
1403 rc = str_read(&key, GFP_KERNEL, fp, len); in role_read()
1415 if (strcmp(key, OBJECT_R) == 0) { in role_read()
1426 rc = hashtab_insert(h, key, role); in role_read()
1431 role_destroy(key, role, NULL); in role_read()
1437 char *key = NULL; in type_read() local
1469 rc = str_read(&key, GFP_KERNEL, fp, len); in type_read()
1473 rc = hashtab_insert(h, key, typdatum); in type_read()
1478 type_destroy(key, typdatum, NULL); in type_read()
1511 char *key = NULL; in user_read() local
1533 rc = str_read(&key, GFP_KERNEL, fp, len); in user_read()
1550 rc = hashtab_insert(h, key, usrdatum); in user_read()
1555 user_destroy(key, usrdatum, NULL); in user_read()
1561 char *key = NULL; in sens_read() local
1578 rc = str_read(&key, GFP_ATOMIC, fp, len); in sens_read()
1591 rc = hashtab_insert(h, key, levdatum); in sens_read()
1596 sens_destroy(key, levdatum, NULL); in sens_read()
1602 char *key = NULL; in cat_read() local
1620 rc = str_read(&key, GFP_ATOMIC, fp, len); in cat_read()
1624 rc = hashtab_insert(h, key, catdatum); in cat_read()
1629 cat_destroy(key, catdatum, NULL); in cat_read()
1645 static int user_bounds_sanity_check(void *key, void *datum, void *datap) in user_bounds_sanity_check() argument
1659 (char *) key); in user_bounds_sanity_check()
1681 static int role_bounds_sanity_check(void *key, void *datum, void *datap) in role_bounds_sanity_check() argument
1695 (char *) key); in role_bounds_sanity_check()
1717 static int type_bounds_sanity_check(void *key, void *datum, void *datap) in type_bounds_sanity_check() argument
1728 (char *) key); in type_bounds_sanity_check()
1738 (char *) key, in type_bounds_sanity_check()
2606 char *key = vkey; in sens_write() local
2614 len = strlen(key); in sens_write()
2621 rc = put_entry(key, 1, len, fp); in sens_write()
2634 char *key = vkey; in cat_write() local
2642 len = strlen(key); in cat_write()
2650 rc = put_entry(key, 1, len, fp); in cat_write()
2747 char *key = vkey; in perm_write() local
2753 len = strlen(key); in perm_write()
2760 rc = put_entry(key, 1, len, fp); in perm_write()
2769 char *key = vkey; in common_write() local
2777 len = strlen(key); in common_write()
2786 rc = put_entry(key, 1, len, fp); in common_write()
2864 char *key = vkey; in class_write() local
2875 len = strlen(key); in class_write()
2898 rc = put_entry(key, 1, len, fp); in class_write()
2952 char *key = vkey; in role_write() local
2961 len = strlen(key); in role_write()
2974 rc = put_entry(key, 1, len, fp); in role_write()
2991 char *key = vkey; in type_write() local
3000 len = strlen(key); in type_write()
3023 rc = put_entry(key, 1, len, fp); in type_write()
3032 char *key = vkey; in user_write() local
3041 len = strlen(key); in user_write()
3052 rc = put_entry(key, 1, len, fp); in user_write()
3071 static int (*write_f[SYM_NUM]) (void *key, void *datum,
3266 static int hashtab_cnt(void *key, void *data, void *ptr) in hashtab_cnt() argument
3274 static int range_write_helper(void *key, void *data, void *ptr) in range_write_helper() argument
3277 struct range_trans *rt = key; in range_write_helper()
3330 static int filename_write_helper(void *key, void *data, void *ptr) in filename_write_helper() argument
3333 struct filename_trans *ft = key; in filename_write_helper()