Lines Matching refs:target
133 const char *target = NULL;
144 target = iPath;
151 (*target != '\0') && (*target != '/')) {
152 if (*mPath != *target) {
156 ++target;
159 ((*target == '\0') || (*target == '/'))) {
171 STATIC struct MountPoint *VfsMountPointInit(const char *source, const char *target,
180 /* find mp by target, to see if it was mounted */
181 mp = VfsMpFind(target, &pathInMp);
198 tsize = strlen(target) + 1;
218 if (strcpy_s((char *)mp + sizeof(struct MountPoint) + ssize, tsize, target) != EOK) {
229 STATIC int VfsRemount(const char *source, const char *target,
237 mp = VfsMpFind(target, NULL);
250 STATIC int VfsMountPathCheck(const char *target)
252 /* target must begin with '/', for example /system, /data, etc. */
253 if ((target == NULL) || (target[0] != '/')) {
258 if (strlen(target) >= PATH_MAX) {
266 int mount(const char *source, const char *target,
273 if (VfsMountPathCheck(target) != LOS_OK) {
280 ret = VfsRemount(source, target, fsType, mountflags, data);
285 mp = VfsMountPointInit(source, target, fsType, mountflags);
294 PRINT_ERR("mount failed, target %s.\n", target);
309 int umount(const char *target)
315 if (VfsMountPathCheck(target) != LOS_OK) {
319 mp = VfsMpFind(target, NULL);
344 PRINT_ERR("umount2 failed, target %s.\n", target);
364 int umount2(const char *target, int flag)
370 if (VfsMountPathCheck(target) != LOS_OK) {
374 mp = VfsMpFind(target, NULL);
401 PRINT_ERR("umount2 failed, target %s.\n", target);