Lines Matching defs:path
78 * Copy parameter control struct, including a possible path allocated
108 * Check sanity of parameter control fields and if a path is present
123 err = invalid_str(param->path, param->size - AUTOFS_DEV_IOCTL_SIZE);
126 "path string terminator missing for cmd(0x%08x)\n",
131 err = check_name(param->path);
133 pr_warn("invalid path supplied for cmd(0x%08x)\n",
184 struct path *res,
185 int test(const struct path *path, void *data),
188 struct path path;
191 err = kern_path(pathname, LOOKUP_MOUNTPOINT, &path);
195 while (path.dentry == path.mnt->mnt_root) {
196 if (path.dentry->d_sb->s_magic == AUTOFS_SUPER_MAGIC) {
197 if (test(&path, data)) {
198 path_get(&path);
199 *res = path;
204 if (!follow_up(&path))
207 path_put(&path);
211 static int test_by_dev(const struct path *path, void *p)
213 return path->dentry->d_sb->s_dev == *(dev_t *)p;
216 static int test_by_type(const struct path *path, void *p)
218 struct autofs_info *ino = autofs_dentry_ino(path->dentry);
225 * to the given path and device number (aka. new_encode_dev(sb->s_dev)).
234 struct path path;
236 err = find_autofs_mount(name, &path, test_by_dev, &devid);
240 filp = dentry_open(&path, O_RDONLY, current_cred());
241 path_put(&path);
262 const char *path;
266 /* param->path has been checked in validate_dev_ioctl() */
273 path = param->path;
277 fd = autofs_dev_ioctl_open_mountpoint(path, devid);
425 struct path path;
429 /* param->path has been checked in validate_dev_ioctl() */
435 err = find_autofs_mount(param->path, &path, test_by_dev, &devid);
439 ino = autofs_dentry_ino(path.dentry);
442 autofs_expire_wait(&path, 0);
450 path_put(&path);
484 * Check if the given path is a mountpoint.
488 * the path is considered a mountpoint if it is itself a
491 * path is a mount point and the super magic of the covering
495 * lookup the path and check if it is the root of a mount.
498 * located path is the root of a mount we return 1 along with
508 struct path path;
514 /* param->path has been checked in validate_dev_ioctl() */
516 name = param->path;
525 &path);
527 err = find_autofs_mount(name, &path,
531 devid = new_encode_dev(path.dentry->d_sb->s_dev);
533 if (path.mnt->mnt_root == path.dentry) {
535 magic = path.dentry->d_sb->s_magic;
540 err = find_autofs_mount(name, &path, test_by_dev, &dev);
546 err = path_has_submounts(&path);
548 if (follow_down_one(&path))
549 magic = path.dentry->d_sb->s_magic;
554 path_put(&path);