Lines Matching refs:uopt
469 static int udf_parse_options(char *options, struct udf_options *uopt, in udf_parse_options() argument
475 uopt->novrs = 0; in udf_parse_options()
476 uopt->session = 0xFFFFFFFF; in udf_parse_options()
477 uopt->lastblock = 0; in udf_parse_options()
478 uopt->anchor = 0; in udf_parse_options()
493 uopt->novrs = 1; in udf_parse_options()
501 uopt->blocksize = n; in udf_parse_options()
502 uopt->flags |= (1 << UDF_FLAG_BLOCKSIZE_SET); in udf_parse_options()
505 uopt->flags |= (1 << UDF_FLAG_UNHIDE); in udf_parse_options()
508 uopt->flags |= (1 << UDF_FLAG_UNDELETE); in udf_parse_options()
511 uopt->flags &= ~(1 << UDF_FLAG_USE_AD_IN_ICB); in udf_parse_options()
514 uopt->flags |= (1 << UDF_FLAG_USE_AD_IN_ICB); in udf_parse_options()
517 uopt->flags |= (1 << UDF_FLAG_USE_SHORT_AD); in udf_parse_options()
520 uopt->flags &= ~(1 << UDF_FLAG_USE_SHORT_AD); in udf_parse_options()
525 uopt->gid = make_kgid(current_user_ns(), option); in udf_parse_options()
526 if (!gid_valid(uopt->gid)) in udf_parse_options()
528 uopt->flags |= (1 << UDF_FLAG_GID_SET); in udf_parse_options()
533 uopt->uid = make_kuid(current_user_ns(), option); in udf_parse_options()
534 if (!uid_valid(uopt->uid)) in udf_parse_options()
536 uopt->flags |= (1 << UDF_FLAG_UID_SET); in udf_parse_options()
541 uopt->umask = option; in udf_parse_options()
544 uopt->flags &= ~(1 << UDF_FLAG_STRICT); in udf_parse_options()
549 uopt->session = option; in udf_parse_options()
551 uopt->flags |= (1 << UDF_FLAG_SESSION_SET); in udf_parse_options()
556 uopt->lastblock = option; in udf_parse_options()
558 uopt->flags |= (1 << UDF_FLAG_LASTBLOCK_SET); in udf_parse_options()
563 uopt->anchor = option; in udf_parse_options()
572 uopt->flags |= (1 << UDF_FLAG_UTF8); in udf_parse_options()
576 if (uopt->nls_map) in udf_parse_options()
577 unload_nls(uopt->nls_map); in udf_parse_options()
583 uopt->nls_map = load_nls(args[0].from); in udf_parse_options()
584 uopt->flags |= (1 << UDF_FLAG_NLS_MAP); in udf_parse_options()
588 uopt->flags |= (1 << UDF_FLAG_UID_FORGET); in udf_parse_options()
595 uopt->flags |= (1 << UDF_FLAG_GID_FORGET); in udf_parse_options()
600 uopt->fmode = option & 0777; in udf_parse_options()
605 uopt->dmode = option & 0777; in udf_parse_options()
617 struct udf_options uopt; in udf_remount_fs() local
626 uopt.flags = sbi->s_flags; in udf_remount_fs()
627 uopt.uid = sbi->s_uid; in udf_remount_fs()
628 uopt.gid = sbi->s_gid; in udf_remount_fs()
629 uopt.umask = sbi->s_umask; in udf_remount_fs()
630 uopt.fmode = sbi->s_fmode; in udf_remount_fs()
631 uopt.dmode = sbi->s_dmode; in udf_remount_fs()
632 uopt.nls_map = NULL; in udf_remount_fs()
634 if (!udf_parse_options(options, &uopt, true)) in udf_remount_fs()
638 sbi->s_flags = uopt.flags; in udf_remount_fs()
639 sbi->s_uid = uopt.uid; in udf_remount_fs()
640 sbi->s_gid = uopt.gid; in udf_remount_fs()
641 sbi->s_umask = uopt.umask; in udf_remount_fs()
642 sbi->s_fmode = uopt.fmode; in udf_remount_fs()
643 sbi->s_dmode = uopt.dmode; in udf_remount_fs()
1966 static int udf_load_vrs(struct super_block *sb, struct udf_options *uopt, in udf_load_vrs() argument
1973 if (!sb_set_blocksize(sb, uopt->blocksize)) { in udf_load_vrs()
1978 sbi->s_last_block = uopt->lastblock; in udf_load_vrs()
1979 if (!uopt->novrs) { in udf_load_vrs()
1998 sbi->s_anchor = uopt->anchor; in udf_load_vrs()
2123 struct udf_options uopt; in udf_fill_super() local
2128 uopt.flags = (1 << UDF_FLAG_USE_AD_IN_ICB) | (1 << UDF_FLAG_STRICT); in udf_fill_super()
2130 uopt.uid = make_kuid(current_user_ns(), overflowuid); in udf_fill_super()
2131 uopt.gid = make_kgid(current_user_ns(), overflowgid); in udf_fill_super()
2132 uopt.umask = 0; in udf_fill_super()
2133 uopt.fmode = UDF_INVALID_MODE; in udf_fill_super()
2134 uopt.dmode = UDF_INVALID_MODE; in udf_fill_super()
2135 uopt.nls_map = NULL; in udf_fill_super()
2145 if (!udf_parse_options((char *)options, &uopt, false)) in udf_fill_super()
2148 if (uopt.flags & (1 << UDF_FLAG_UTF8) && in udf_fill_super()
2149 uopt.flags & (1 << UDF_FLAG_NLS_MAP)) { in udf_fill_super()
2153 if ((uopt.flags & (1 << UDF_FLAG_NLS_MAP)) && !uopt.nls_map) { in udf_fill_super()
2154 uopt.nls_map = load_nls_default(); in udf_fill_super()
2155 if (!uopt.nls_map) in udf_fill_super()
2156 uopt.flags &= ~(1 << UDF_FLAG_NLS_MAP); in udf_fill_super()
2160 if (!(uopt.flags & (1 << UDF_FLAG_NLS_MAP))) in udf_fill_super()
2161 uopt.flags |= (1 << UDF_FLAG_UTF8); in udf_fill_super()
2166 sbi->s_flags = uopt.flags; in udf_fill_super()
2167 sbi->s_uid = uopt.uid; in udf_fill_super()
2168 sbi->s_gid = uopt.gid; in udf_fill_super()
2169 sbi->s_umask = uopt.umask; in udf_fill_super()
2170 sbi->s_fmode = uopt.fmode; in udf_fill_super()
2171 sbi->s_dmode = uopt.dmode; in udf_fill_super()
2172 sbi->s_nls_map = uopt.nls_map; in udf_fill_super()
2175 if (uopt.session == 0xFFFFFFFF) in udf_fill_super()
2178 sbi->s_session = uopt.session; in udf_fill_super()
2189 if (uopt.flags & (1 << UDF_FLAG_BLOCKSIZE_SET)) { in udf_fill_super()
2190 ret = udf_load_vrs(sb, &uopt, silent, &fileset); in udf_fill_super()
2192 uopt.blocksize = bdev_logical_block_size(sb->s_bdev); in udf_fill_super()
2193 while (uopt.blocksize <= 4096) { in udf_fill_super()
2194 ret = udf_load_vrs(sb, &uopt, silent, &fileset); in udf_fill_super()
2198 uopt.blocksize); in udf_fill_super()
2211 uopt.blocksize <<= 1; in udf_fill_super()
2317 if (uopt.nls_map) in udf_fill_super()
2318 unload_nls(uopt.nls_map); in udf_fill_super()