Lines Matching refs:perm

255 	if (acl->perm & (1 << r->param.path.operation)) {  in tomoyo_check_path_acl()
277 return (acl->perm & (1 << r->param.path_number.operation)) && in tomoyo_check_path_number_acl()
297 return (acl->perm & (1 << r->param.path2.operation)) && in tomoyo_check_path2_acl()
316 return (acl->perm & (1 << r->param.mkdev.operation)) && in tomoyo_check_mkdev_acl()
357 ->perm; in tomoyo_merge_path_acl()
358 u16 perm = *a_perm; in tomoyo_merge_path_acl() local
359 const u16 b_perm = container_of(b, struct tomoyo_path_acl, head)->perm; in tomoyo_merge_path_acl()
361 perm &= ~b_perm; in tomoyo_merge_path_acl()
363 perm |= b_perm; in tomoyo_merge_path_acl()
364 *a_perm = perm; in tomoyo_merge_path_acl()
365 return !perm; in tomoyo_merge_path_acl()
378 static int tomoyo_update_path_acl(const u16 perm, in tomoyo_update_path_acl() argument
383 .perm = perm in tomoyo_update_path_acl()
429 head)->perm; in tomoyo_merge_mkdev_acl()
430 u8 perm = *a_perm; in tomoyo_merge_mkdev_acl() local
432 ->perm; in tomoyo_merge_mkdev_acl()
434 perm &= ~b_perm; in tomoyo_merge_mkdev_acl()
436 perm |= b_perm; in tomoyo_merge_mkdev_acl()
437 *a_perm = perm; in tomoyo_merge_mkdev_acl()
438 return !perm; in tomoyo_merge_mkdev_acl()
451 static int tomoyo_update_mkdev_acl(const u8 perm, in tomoyo_update_mkdev_acl() argument
456 .perm = perm in tomoyo_update_mkdev_acl()
506 ->perm; in tomoyo_merge_path2_acl()
507 u8 perm = *a_perm; in tomoyo_merge_path2_acl() local
508 const u8 b_perm = container_of(b, struct tomoyo_path2_acl, head)->perm; in tomoyo_merge_path2_acl()
510 perm &= ~b_perm; in tomoyo_merge_path2_acl()
512 perm |= b_perm; in tomoyo_merge_path2_acl()
513 *a_perm = perm; in tomoyo_merge_path2_acl()
514 return !perm; in tomoyo_merge_path2_acl()
527 static int tomoyo_update_path2_acl(const u8 perm, in tomoyo_update_path2_acl() argument
532 .perm = perm in tomoyo_update_path2_acl()
641 head)->perm; in tomoyo_merge_path_number_acl()
642 u8 perm = *a_perm; in tomoyo_merge_path_number_acl() local
644 ->perm; in tomoyo_merge_path_number_acl()
646 perm &= ~b_perm; in tomoyo_merge_path_number_acl()
648 perm |= b_perm; in tomoyo_merge_path_number_acl()
649 *a_perm = perm; in tomoyo_merge_path_number_acl()
650 return !perm; in tomoyo_merge_path_number_acl()
661 static int tomoyo_update_path_number_acl(const u8 perm, in tomoyo_update_path_number_acl() argument
666 .perm = perm in tomoyo_update_path_number_acl()
994 u16 perm = 0; in tomoyo_write_file() local
999 perm |= 1 << type; in tomoyo_write_file()
1000 if (perm) in tomoyo_write_file()
1001 return tomoyo_update_path_acl(perm, param); in tomoyo_write_file()
1005 perm |= 1 << type; in tomoyo_write_file()
1006 if (perm) in tomoyo_write_file()
1007 return tomoyo_update_path2_acl(perm, param); in tomoyo_write_file()
1011 perm |= 1 << type; in tomoyo_write_file()
1012 if (perm) in tomoyo_write_file()
1013 return tomoyo_update_path_number_acl(perm, param); in tomoyo_write_file()
1017 perm |= 1 << type; in tomoyo_write_file()
1018 if (perm) in tomoyo_write_file()
1019 return tomoyo_update_mkdev_acl(perm, param); in tomoyo_write_file()