| /freebsd-14-stable/usr.sbin/autofs/ |
| HD | automount.c | 88 find_statfs(const struct statfs *mntbuf, int nitems, const char *mountpoint) in find_statfs() argument 93 if (strcmp(mntbuf[i].f_mntonname, mountpoint) == 0) in find_statfs() 94 return (mntbuf + i); in find_statfs() 145 const char *prefix, const struct statfs *mntbuf, int nitems) in mount_if_not_already() argument 157 sb = find_statfs(mntbuf, nitems, mountpoint); in mount_if_not_already() 186 struct statfs *mntbuf; in mount_unmount() local 190 nitems = getmntinfo(&mntbuf, MNT_WAIT); in mount_unmount() 197 if (strcmp(mntbuf[i].f_fstypename, "autofs") != 0) { in mount_unmount() 199 mntbuf[i].f_mntonname); in mount_unmount() 203 n = node_find(root, mntbuf[i].f_mntonname); in mount_unmount() [all …]
|
| HD | autounmountd.c | 103 struct statfs *mntbuf; in refresh_automounted() local 106 nitems = getmntinfo(&mntbuf, MNT_WAIT); in refresh_automounted() 116 if (strcmp(mntbuf[i].f_fstypename, "autofs") == 0) { in refresh_automounted() 118 mntbuf[i].f_mntonname); in refresh_automounted() 122 if ((mntbuf[i].f_flags & MNT_AUTOMOUNTED) == 0) { in refresh_automounted() 124 mntbuf[i].f_mntonname); in refresh_automounted() 128 af = automounted_find(mntbuf[i].f_fsid); in refresh_automounted() 131 "(FSID:%d:%d)", mntbuf[i].f_mntonname, in refresh_automounted() 132 mntbuf[i].f_fsid.val[0], mntbuf[i].f_fsid.val[1]); in refresh_automounted() 133 af = automounted_add(mntbuf[i].f_fsid, in refresh_automounted() [all …]
|
| /freebsd-14-stable/lib/libc/gen/ |
| HD | getmntinfo.c | 48 static struct statfs *mntbuf; in getmntinfo() local 55 if (bufsize > 0 && (mntsize = getfsstat(mntbuf, bufsize, mode)) < 0) in getmntinfo() 57 while (tries++ < MAX_TRIES && bufsize <= mntsize * sizeof(*mntbuf)) { in getmntinfo() 58 bufsize = (mntsize * SCALING_FACTOR) * sizeof(*mntbuf); in getmntinfo() 59 if ((mntbuf = reallocf(mntbuf, bufsize)) == NULL) in getmntinfo() 61 if ((mntsize = getfsstat(mntbuf, bufsize, mode)) < 0) in getmntinfo() 64 *mntbufp = mntbuf; in getmntinfo() 65 if (mntsize > (bufsize / sizeof(*mntbuf))) in getmntinfo() 66 return (bufsize / sizeof(*mntbuf)); in getmntinfo()
|
| HD | getmntinfo-compat11.c | 45 static struct freebsd11_statfs *mntbuf; in freebsd11_getmntinfo() local 53 (mntsize = freebsd11_getfsstat(mntbuf, bufsize, flags)) < 0) in freebsd11_getmntinfo() 56 if (mntbuf) in freebsd11_getmntinfo() 57 free(mntbuf); in freebsd11_getmntinfo() 59 if ((mntbuf = (struct freebsd11_statfs *)malloc(bufsize)) == 0) in freebsd11_getmntinfo() 61 if ((mntsize = freebsd11_getfsstat(mntbuf, bufsize, flags)) < 0) in freebsd11_getmntinfo() 64 *mntbufp = mntbuf; in freebsd11_getmntinfo()
|
| /freebsd-14-stable/contrib/netbsd-tests/fs/nfs/nfsservice/ |
| HD | getmntinfo.c | 62 static struct statvfs *mntbuf; local 72 (mntsize = getvfsstat(mntbuf, bufsize, flags)) == -1) 75 if (mntbuf) 76 free(mntbuf); 78 if ((mntbuf = malloc(bufsize)) == NULL) 80 if ((mntsize = getvfsstat(mntbuf, bufsize, flags)) == -1) 83 *mntbufp = mntbuf;
|
| /freebsd-14-stable/sbin/mount/ |
| HD | mount.c | 217 struct statfs *mntbuf; in main() local 305 if ((mntsize = getmntinfo(&mntbuf, in main() 326 ismounted(fs, mntbuf, mntsize)) in main() 329 mntbuf->f_flags); in main() 338 if (checkvfsname(mntbuf[i].f_fstypename, vfslist)) in main() 341 putfsent(&mntbuf[i]); in main() 348 if (checkvfsname(mntbuf[i].f_fstypename, in main() 352 (mntbuf[i].f_flags & MNT_IGNORE) != 0) in main() 355 prmount(&mntbuf[i]); in main() 369 if ((mntbuf = getmntpoint(*argv)) == NULL) in main() [all …]
|
| HD | getmntopts.c | 165 struct statfs *mntbuf, *statfsp; in getmntpoint() local 175 mntsize = getmntinfo(&mntbuf, MNT_NOWAIT); in getmntpoint() 177 statfsp = &mntbuf[i]; in getmntpoint()
|
| /freebsd-14-stable/sys/contrib/openzfs/lib/libspl/os/linux/ |
| HD | getmntany.c | 67 struct mntent mntbuf; in _sol_getmntent() local 70 ret = getmntent_r(fp, &mntbuf, buf, BUFSIZE); in _sol_getmntent() 73 mgetp->mnt_special = mntbuf.mnt_fsname; in _sol_getmntent() 74 mgetp->mnt_mountp = mntbuf.mnt_dir; in _sol_getmntent() 75 mgetp->mnt_fstype = mntbuf.mnt_type; in _sol_getmntent() 76 mgetp->mnt_mntopts = mntbuf.mnt_opts; in _sol_getmntent()
|
| /freebsd-14-stable/usr.sbin/snapinfo/ |
| HD | snapinfo.c | 58 struct statfs *mntbuf; in main() local 101 fscount = getmntinfo(&mntbuf, MNT_WAIT); in main() 103 if (!strncmp(mntbuf[n].f_fstypename, "ufs", 3)) { in main() 104 if (all || strcmp(path, mntbuf[n].f_mntonname) == 0) { in main() 105 find_snapshot(&mntbuf[n]); in main()
|
| /freebsd-14-stable/contrib/hyperv/tools/ |
| HD | hv_vss_daemon.c | 52 struct statfs *mntbuf, *statfsp; in check() local 56 mntsize = getmntinfo(&mntbuf, MNT_NOWAIT); in check() 63 statfsp = &mntbuf[i]; in check() 80 struct statfs *mntbuf, *statfsp; in freeze() local 91 mntsize = getmntinfo(&mntbuf, MNT_NOWAIT); in freeze() 98 statfsp = &mntbuf[i]; in freeze()
|
| /freebsd-14-stable/usr.sbin/rpc.umntall/ |
| HD | rpc.umntall.c | 225 struct statfs *mntbuf; in is_mounted() local 237 if ((mntbuf = malloc(bufsize)) == NULL) in is_mounted() 239 mntsize = getfsstat(mntbuf, (long)bufsize, MNT_NOWAIT); in is_mounted() 241 if (strcmp(mntbuf[i].f_mntfromname, name) == 0) { in is_mounted() 242 free(mntbuf); in is_mounted() 246 free(mntbuf); in is_mounted()
|
| /freebsd-14-stable/sbin/bectl/ |
| HD | bectl_jail.c | 211 struct statfs *mntbuf; in bectl_jail_cleanup() local 220 mntsize = getmntinfo(&mntbuf, MNT_NOWAIT); in bectl_jail_cleanup() 222 if (strncmp(mountpoint, mntbuf[i].f_mntonname, searchlen) == 0 && in bectl_jail_cleanup() 223 mntbuf[i].f_type != MNTTYPE_ZFS) { in bectl_jail_cleanup() 225 if (unmount(mntbuf[i].f_mntonname, 0) != 0) { in bectl_jail_cleanup() 227 mntbuf[i].f_mntonname); in bectl_jail_cleanup()
|
| /freebsd-14-stable/sbin/umount/ |
| HD | umount.c | 102 struct statfs *mntbuf, *sfs; in main() local 170 if ((mntsize = mntinfo(&mntbuf)) <= 0) in main() 177 sfs = &mntbuf[mntsize]; in main() 185 free(mntbuf); in main() 500 static struct statfs *mntbuf; in getmntentry() local 507 if ((mntsize = mntinfo(&mntbuf)) <= 0) in getmntentry() 524 sfs = &mntbuf[i]; in getmntentry() 621 mntinfo(struct statfs **mntbuf) in mntinfo() argument 634 *mntbuf = origbuf; in mntinfo()
|
| /freebsd-14-stable/tools/test/stress2/misc/ |
| HD | ufssuspend.sh | 42 struct statfs *mntbuf, *statfsp; 53 mntsize = getmntinfo(&mntbuf, MNT_NOWAIT); 60 statfsp = &mntbuf[i];
|
| /freebsd-14-stable/sbin/dump/ |
| HD | main.c | 645 struct statfs *mntbuf; in getmntpt() local 647 mntsize = getmntinfo(&mntbuf, MNT_NOWAIT); in getmntpt() 649 if (!strcmp(mntbuf[i].f_mntfromname, name)) { in getmntpt() 650 *mntflagsp = mntbuf[i].f_flags; in getmntpt() 651 return (mntbuf[i].f_mntonname); in getmntpt()
|
| /freebsd-14-stable/contrib/netbsd-tests/bin/df/ |
| HD | getmntinfo.c | 208 getmntinfo(struct statvfs **mntbuf, int flags) in getmntinfo() argument 216 *mntbuf = allstatvfs; in getmntinfo()
|
| /freebsd-14-stable/usr.bin/nfsstat/ |
| HD | nfsstat.c | 152 struct statfs *mntbuf; in main() local 170 mntlen = getmntinfo(&mntbuf, MNT_NOWAIT); in main() 172 if (strcmp(mntbuf->f_fstypename, "nfs") == 0) { in main() 174 mntbuf->f_mntonname; in main() 180 mntbuf->f_mntfromname, in main() 181 mntbuf->f_mntonname, buf); in main() 186 mntbuf++; in main()
|
| /freebsd-14-stable/lib/libugidfw/ |
| HD | ugidfw.c | 66 struct statfs *mntbuf; in bsde_rule_to_string() local 333 numfs = getmntinfo(&mntbuf, MNT_NOWAIT); in bsde_rule_to_string() 336 &mntbuf[i].f_fsid) == 0) in bsde_rule_to_string() 339 i == numfs ? "???" : mntbuf[i].f_mntonname); in bsde_rule_to_string()
|
| /freebsd-14-stable/contrib/llvm-project/compiler-rt/lib/sanitizer_common/ |
| HD | sanitizer_common_interceptors.inc | 4458 __sanitizer_mntent *mntbuf, char *buf, int buflen) { 4460 COMMON_INTERCEPTOR_ENTER(ctx, getmntent_r, fp, mntbuf, buf, buflen); 4461 __sanitizer_mntent *res = REAL(getmntent_r)(fp, mntbuf, buf, buflen);
|