Lines Matching full:cached
1476 static int compare(const struct CACHED_SECURID *cached, in compare() argument
1484 csize = (cached->variable ? in compare()
1486 + (((struct POSIX_SECURITY*)cached->variable)->acccnt in compare()
1487 + ((struct POSIX_SECURITY*)cached->variable)->defcnt) in compare()
1496 return ((cached->uid != item->uid) in compare()
1497 || (cached->gid != item->gid) in compare()
1498 || (cached->dmode != item->dmode) in compare()
1502 && memcmp(&((struct POSIX_SECURITY*)cached->variable)->acl, in compare()
1505 return ((cached->uid != item->uid) in compare()
1506 || (cached->gid != item->gid) in compare()
1507 || (cached->dmode != item->dmode)); in compare()
1511 static int leg_compare(const struct CACHED_PERMISSIONS_LEGACY *cached, in leg_compare() argument
1514 return (cached->mft_no != item->mft_no); in leg_compare()
1714 * give direct access to the cached pxdesc in enter_cache()
1727 * Fetch owner, group and permission of a file, if cached
2072 const struct CACHED_PERMISSIONS *cached; in ntfs_get_perm() local
2086 cached = fetch_cache(scx,ni); in ntfs_get_perm()
2087 if (cached) { in ntfs_get_perm()
2088 uid = cached->uid; in ntfs_get_perm()
2089 gid = cached->gid; in ntfs_get_perm()
2090 perm = access_check_posix(scx,cached->pxdesc,request,uid,gid); in ntfs_get_perm()
2174 const struct CACHED_PERMISSIONS *cached; in ntfs_get_posix_acl() local
2188 cached = fetch_cache(scx,ni); in ntfs_get_posix_acl()
2189 if (cached) in ntfs_get_posix_acl()
2190 pxdesc = cached->pxdesc; in ntfs_get_posix_acl()
2282 if (!cached) in ntfs_get_posix_acl()
2305 const struct CACHED_PERMISSIONS *cached; in ntfs_get_perm() local
2318 cached = fetch_cache(scx,ni); in ntfs_get_perm()
2319 if (cached) { in ntfs_get_perm()
2320 perm = cached->mode; in ntfs_get_perm()
2321 uid = cached->uid; in ntfs_get_perm()
2322 gid = cached->gid; in ntfs_get_perm()
2445 const struct CACHED_PERMISSIONS *cached; in ntfs_get_owner_mode() local
2456 cached = fetch_cache(scx,ni); in ntfs_get_owner_mode()
2457 if (cached) { in ntfs_get_owner_mode()
2460 && cached->pxdesc) in ntfs_get_owner_mode()
2461 perm = ntfs_basic_perms(scx,cached->pxdesc); in ntfs_get_owner_mode()
2464 perm = cached->mode; in ntfs_get_owner_mode()
2465 stbuf->st_uid = cached->uid; in ntfs_get_owner_mode()
2466 stbuf->st_gid = cached->gid; in ntfs_get_owner_mode()
2557 const struct CACHED_PERMISSIONS *cached; in inherit_posix() local
2569 cached = fetch_cache(scx,dir_ni); in inherit_posix()
2570 if (cached) { in inherit_posix()
2571 uid = cached->uid; in inherit_posix()
2572 gid = cached->gid; in inherit_posix()
2573 pxdesc = cached->pxdesc; in inherit_posix()
2652 const struct CACHED_SECURID *cached; in ntfs_alloc_securid() local
2679 cached = (const struct CACHED_SECURID*)ntfs_fetch_cache( in ntfs_alloc_securid()
2683 if (cached) in ntfs_alloc_securid()
2684 securid = cached->securid; in ntfs_alloc_securid()
2688 if (!cached && (scx->vol->major_ver >= 3)) { in ntfs_alloc_securid()
2796 const struct CACHED_SECURID *cached; in ntfs_alloc_securid() local
2818 cached = (const struct CACHED_SECURID*)ntfs_fetch_cache( in ntfs_alloc_securid()
2822 if (cached) in ntfs_alloc_securid()
2823 securid = cached->securid; in ntfs_alloc_securid()
2827 if (!cached && (scx->vol->major_ver >= 3)) { in ntfs_alloc_securid()
2879 const struct CACHED_SECURID *cached; in ntfs_set_owner_mode() local
2909 cached = (const struct CACHED_SECURID*)ntfs_fetch_cache( in ntfs_set_owner_mode()
2913 if (cached) { in ntfs_set_owner_mode()
2914 ni->security_id = cached->securid; in ntfs_set_owner_mode()
2925 } else cached = (struct CACHED_SECURID*)NULL; in ntfs_set_owner_mode()
2927 if (!cached) { in ntfs_set_owner_mode()
3009 const struct CACHED_PERMISSIONS *cached; in ntfs_allowed_as_owner() local
3028 cached = fetch_cache(scx, ni); in ntfs_allowed_as_owner()
3029 if (cached) { in ntfs_allowed_as_owner()
3030 uid = cached->uid; in ntfs_allowed_as_owner()
3079 const struct CACHED_PERMISSIONS *cached; in ntfs_set_posix_acl() local
3106 cached = fetch_cache(scx, ni); in ntfs_set_posix_acl()
3107 if (cached) { in ntfs_set_posix_acl()
3108 uid = cached->uid; in ntfs_set_posix_acl()
3109 gid = cached->gid; in ntfs_set_posix_acl()
3110 oldpxdesc = cached->pxdesc; in ntfs_set_posix_acl()
3255 const struct CACHED_PERMISSIONS *cached; in ntfs_set_mode() local
3272 cached = fetch_cache(scx, ni); in ntfs_set_mode()
3273 if (cached) { in ntfs_set_mode()
3274 uid = cached->uid; in ntfs_set_mode()
3275 gid = cached->gid; in ntfs_set_mode()
3277 oldpxdesc = cached->pxdesc; in ntfs_set_mode()
3632 const struct CACHED_PERMISSIONS *cached; in ntfs_set_owner() local
3650 cached = fetch_cache(scx,ni); in ntfs_set_owner()
3651 if (cached) { in ntfs_set_owner()
3652 fileuid = cached->uid; in ntfs_set_owner()
3653 filegid = cached->gid; in ntfs_set_owner()
3654 mode = cached->mode; in ntfs_set_owner()
3656 pxdesc = cached->pxdesc; in ntfs_set_owner()
3755 const struct CACHED_PERMISSIONS *cached; in ntfs_set_ownmod() local
3773 cached = fetch_cache(scx,ni); in ntfs_set_ownmod()
3774 if (cached) { in ntfs_set_ownmod()
3775 fileuid = cached->uid; in ntfs_set_ownmod()
3776 filegid = cached->gid; in ntfs_set_ownmod()
3778 oldpxdesc = cached->pxdesc; in ntfs_set_ownmod()
4032 struct CACHED_PERMISSIONS *cached; in ntfs_inherited_id() local
4037 cached = (struct CACHED_PERMISSIONS*)NULL; in ntfs_inherited_id()
4044 cached = fetch_cache(scx, dir_ni); in ntfs_inherited_id()
4045 if (cached in ntfs_inherited_id()
4046 && (cached->uid == scx->uid) && (cached->gid == scx->gid)) in ntfs_inherited_id()
4047 securid = (fordir ? cached->inh_dirid in ntfs_inherited_id()
4048 : cached->inh_fileid); in ntfs_inherited_id()
4051 * Not cached or not available in cache, compute it all in ntfs_inherited_id()
4065 cached = fetch_cache(scx, dir_ni); in ntfs_inherited_id()
4066 if (cached in ntfs_inherited_id()
4067 && (cached->uid == scx->uid) in ntfs_inherited_id()
4068 && (cached->gid == scx->gid)) { in ntfs_inherited_id()
4070 cached->inh_dirid = securid; in ntfs_inherited_id()
4072 cached->inh_fileid = securid; in ntfs_inherited_id()