/freebsd-13-stable/sys/security/mac/ |
H A D | mac_posix_shm.c | 68 mac_posixshm_init(struct shmfd *shmfd) argument 72 shmfd->shm_label = mac_posixshm_label_alloc(); 74 shmfd->shm_label = NULL; 86 mac_posixshm_destroy(struct shmfd *shmfd) argument 89 if (shmfd->shm_label != NULL) { 90 mac_posixshm_label_free(shmfd->shm_label); 91 shmfd->shm_label = NULL; 96 mac_posixshm_create(struct ucred *cred, struct shmfd *shmf argument 121 mac_posixshm_check_mmap(struct ucred *cred, struct shmfd *shmfd, int prot, int flags) argument 138 mac_posixshm_check_open(struct ucred *cred, struct shmfd *shmfd, accmode_t accmode) argument 154 mac_posixshm_check_stat(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd) argument 171 mac_posixshm_check_truncate(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd) argument 188 mac_posixshm_check_unlink(struct ucred *cred, struct shmfd *shmfd) argument 203 mac_posixshm_check_setmode(struct ucred *cred, struct shmfd *shmfd, mode_t mode) argument 218 mac_posixshm_check_setowner(struct ucred *cred, struct shmfd *shmfd, uid_t uid, gid_t gid) argument 235 mac_posixshm_check_read(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd) argument 252 mac_posixshm_check_write(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd) argument [all...] |
H A D | mac_framework.h | 78 struct shmfd; 261 int mac_posixshm_check_mmap(struct ucred *cred, struct shmfd *shmfd, 263 int mac_posixshm_check_open(struct ucred *cred, struct shmfd *shmfd, 266 struct ucred *file_cred, struct shmfd *shmfd); 267 int mac_posixshm_check_setmode(struct ucred *cred, struct shmfd *shmfd, 269 int mac_posixshm_check_setowner(struct ucred *cred, struct shmfd *shmf [all...] |
H A D | mac_policy.h | 92 struct shmfd; 357 struct shmfd *shmfd, struct label *shmlabel, int prot, 360 struct shmfd *shmfd, struct label *shmlabel, 363 struct ucred *file_cred, struct shmfd *shmfd, 366 struct shmfd *shmfd, struct label *shmlabel, 369 struct shmfd *shmf [all...] |
/freebsd-13-stable/sys/kern/ |
H A D | uipc_shm.c | 110 struct shmfd *sm_shmfd; 114 static MALLOC_DEFINE(M_SHMFD, "shmfd", "shared memory file descriptor"); 125 static void shm_insert(char *path, Fnv32_t fnv, struct shmfd *shmfd); 126 static struct shmfd *shm_lookup(char *path, Fnv32_t fnv); 128 static int shm_dotruncate_cookie(struct shmfd *shmfd, off_t length, 130 static int shm_dotruncate_locked(struct shmfd *shmfd, off_t length, 338 shm_largepage(struct shmfd *shmf argument 346 struct shmfd *shmfd; local 388 struct shmfd *shmfd; local 411 struct shmfd *shmfd; local 468 struct shmfd *shmfd; local 486 struct shmfd *shmfd; local 540 struct shmfd *shmfd; local 582 struct shmfd *shmfd; local 630 shm_dotruncate_locked(struct shmfd *shmfd, off_t length, void *rl_cookie) argument 732 shm_dotruncate_largepage(struct shmfd *shmfd, off_t length, void *rl_cookie) argument 824 shm_dotruncate_cookie(struct shmfd *shmfd, off_t length, void *rl_cookie) argument 837 shm_dotruncate(struct shmfd *shmfd, off_t length) argument 856 struct shmfd *shmfd; local 889 shm_hold(struct shmfd *shmfd) argument 897 shm_drop(struct shmfd *shmfd) argument 916 shm_access(struct shmfd *shmfd, struct ucred *ucred, int flags) argument 987 shm_insert(char *path, Fnv32_t fnv, struct shmfd *shmfd) argument 1035 struct shmfd *shmfd; local 1416 shm_mmap_large(struct shmfd *shmfd, vm_map_t map, vm_offset_t *addr, vm_size_t size, vm_prot_t prot, vm_prot_t max_prot, int flags, vm_ooffset_t foff, struct thread *td) argument 1529 struct shmfd *shmfd; local 1621 struct shmfd *shmfd; local 1650 struct shmfd *shmfd; local 1683 struct shmfd *shmfd; local 1741 struct shmfd *shmfd; local 1779 shm_fill_kinfo_locked(struct shmfd *shmfd, struct kinfo_file *kif, bool list) argument 1824 struct shmfd *shmfd; local 1870 struct shmfd *shmfd; local 1881 struct shmfd *shmfd; local [all...] |
H A D | kern_sendfile.c | 565 struct vnode **vp_res, struct shmfd **shmfd_res, off_t *obj_size, 571 struct shmfd *shmfd; local 577 shmfd = *shmfd_res = NULL; 614 shmfd = fp->f_data; 615 obj = shmfd->shm_object; 617 *obj_size = shmfd->shm_size; 638 *shmfd_res = shmfd; 691 struct shmfd *shmfd; local [all...] |
H A D | kern_umtx.c | 3842 struct shmfd *ushm_obj;
|
/freebsd-13-stable/sys/sys/ |
H A D | mman.h | 268 struct shmfd { struct 306 int shm_access(struct shmfd *shmfd, struct ucred *ucred, int flags); 307 struct shmfd *shm_alloc(struct ucred *ucred, mode_t mode, bool largepage); 308 struct shmfd *shm_hold(struct shmfd *shmfd); 309 void shm_drop(struct shmfd *shmfd); 310 int shm_dotruncate(struct shmfd *shmf [all...] |
/freebsd-13-stable/tests/sys/vm/ |
H A D | mmap_test.c | 115 int devstatfd, pagesize, shmfd, zerofd; local 119 ATF_REQUIRE((shmfd = shm_open(SHM_ANON, O_RDWR, 0644)) >= 0); 120 ATF_REQUIRE(ftruncate(shmfd, pagesize) == 0); 126 checked_mmap(PROT_READ | PROT_WRITE, MAP_SHARED, shmfd, 0, 128 checked_mmap(PROT_READ | PROT_WRITE, MAP_PRIVATE, shmfd, 0, 140 checked_mmap(0xffff, MAP_SHARED, shmfd, EINVAL, 150 checked_mmap(PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_SHARED, shmfd, 154 checked_mmap(PROT_READ | PROT_WRITE, 0, shmfd, EINVAL, 179 close(shmfd);
|
/freebsd-13-stable/tools/tools/syscall_timing/ |
H A D | syscall_timing.c | 698 int shmfd; local 700 shmfd = shm_open(SHM_ANON, O_CREAT | O_RDWR, 0600); 701 if (shmfd < 0) 703 close(shmfd); 706 shmfd = shm_open(SHM_ANON, O_CREAT | O_RDWR, 0600); 707 if (shmfd < 0) 709 close(shmfd); 719 int fd, shmfd; local 721 shmfd = shm_open(SHM_ANON, O_CREAT | O_RDWR, 0600); 722 if (shmfd < 743 int shmfd; local [all...] |
/freebsd-13-stable/sys/security/mac_stub/ |
H A D | mac_stub.c | 738 stub_posixshm_check_mmap(struct ucred *cred, struct shmfd *shmfd, argument 746 stub_posixshm_check_open(struct ucred *cred, struct shmfd *shmfd, argument 755 struct shmfd *shm, struct label *shmlabel) 762 stub_posixshm_check_setmode(struct ucred *cred, struct shmfd *shmfd, argument 770 stub_posixshm_check_setowner(struct ucred *cred, struct shmfd *shmfd, argument 779 struct shmfd *shmf 778 stub_posixshm_check_stat(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmlabel) argument 786 stub_posixshm_check_truncate(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmlabel) argument 794 stub_posixshm_check_unlink(struct ucred *cred, struct shmfd *shmfd, struct label *shmlabel) argument 810 stub_posixshm_create(struct ucred *cred, struct shmfd *shmfd, struct label *shmlabel) argument [all...] |
/freebsd-13-stable/sys/security/mac_biba/ |
H A D | mac_biba.c | 1697 biba_posixshm_check_mmap(struct ucred *cred, struct shmfd *shmfd, argument 1721 biba_posixshm_check_open(struct ucred *cred, struct shmfd *shmfd, argument 1746 struct shmfd *vp, struct label *shmlabel) 1763 biba_posixshm_check_setmode(struct ucred *cred, struct shmfd *shmfd, argument 1781 biba_posixshm_check_setowner(struct ucred *cred, struct shmfd *shmfd, argument 1800 struct shmfd *shmf 1799 biba_posixshm_check_stat(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmlabel) argument 1817 biba_posixshm_check_truncate(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmlabel) argument 1835 biba_posixshm_check_unlink(struct ucred *cred, struct shmfd *shmfd, struct label *shmlabel) argument 1871 biba_posixshm_create(struct ucred *cred, struct shmfd *shmfd, struct label *shmlabel) argument [all...] |
/freebsd-13-stable/sys/security/mac_mls/ |
H A D | mac_mls.c | 1593 mls_posixshm_check_mmap(struct ucred *cred, struct shmfd *shmfd, argument 1617 mls_posixshm_check_open(struct ucred *cred, struct shmfd *shmfd, argument 1642 struct shmfd *shm, struct label *shmlabel) 1659 mls_posixshm_check_setmode(struct ucred *cred, struct shmfd *shmfd, argument 1677 mls_posixshm_check_setowner(struct ucred *cred, struct shmfd *shmfd, argument 1696 struct shmfd *shmf 1695 mls_posixshm_check_stat(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmlabel) argument 1713 mls_posixshm_check_truncate(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmlabel) argument 1731 mls_posixshm_check_unlink(struct ucred *cred, struct shmfd *shmfd, struct label *shmlabel) argument 1767 mls_posixshm_create(struct ucred *cred, struct shmfd *shmfd, struct label *shmlabel) argument [all...] |
/freebsd-13-stable/sys/security/mac_test/ |
H A D | mac_test.c | 1395 test_posixshm_check_mmap(struct ucred *cred, struct shmfd *shmfd, argument 1407 test_posixshm_check_open(struct ucred *cred, struct shmfd *shmfd, argument 1420 struct ucred *file_cred, struct shmfd *shm, struct label *shmlabel) 1434 test_posixshm_check_setmode(struct ucred *cred, struct shmfd *shmfd, argument 1446 test_posixshm_check_setowner(struct ucred *cred, struct shmfd *shmfd, argument 1459 struct ucred *file_cred, struct shmfd *shmf 1458 test_posixshm_check_stat(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmfdlabel) argument 1471 test_posixshm_check_truncate(struct ucred *active_cred, struct ucred *file_cred, struct shmfd *shmfd, struct label *shmfdlabel) argument 1484 test_posixshm_check_unlink(struct ucred *cred, struct shmfd *shmfd, struct label *shmfdlabel) argument 1511 test_posixshm_create(struct ucred *cred, struct shmfd *shmfd, struct label *shmfdlabel) argument [all...] |
/freebsd-13-stable/lib/libprocstat/ |
H A D | libprocstat.c | 1190 struct shmfd shmfd; local 1202 if (!kvm_read_all(kd, (unsigned long)shmfdp, &shmfd, 1203 sizeof(struct shmfd))) { 1204 warnx("can't read shmfd at %p", (void *)shmfdp); 1207 shm->mode = S_IFREG | shmfd.shm_mode; 1208 shm->size = shmfd.shm_size; 1209 if (fst->fs_path == NULL && shmfd.shm_path != NULL) { 1212 if (!kvm_read_all(kd, (unsigned long)shmfd.shm_path + i,
|