Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
77cb271e
K
Kernel
项目概览
openeuler
/
Kernel
大约 1 年 前同步成功
通知
5
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
77cb271e
编写于
12月 21, 2019
作者:
A
Al Viro
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
gfs2: switch to use of errorfc() et.al.
Signed-off-by:
N
Al Viro
<
viro@zeniv.linux.org.uk
>
上级
2e28c49e
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
15 addition
and
15 deletion
+15
-15
fs/gfs2/ops_fstype.c
fs/gfs2/ops_fstype.c
+15
-15
未找到文件。
fs/gfs2/ops_fstype.c
浏览文件 @
77cb271e
...
...
@@ -1359,7 +1359,7 @@ static int gfs2_parse_param(struct fs_context *fc, struct fs_parameter *param)
break
;
case
Opt_debug
:
if
(
result
.
boolean
&&
args
->
ar_errors
==
GFS2_ERRORS_PANIC
)
return
invalf
(
fc
,
"gfs2:
-o debug and -o errors=panic are mutually exclusive"
);
return
invalf
c
(
fc
,
"
-o debug and -o errors=panic are mutually exclusive"
);
args
->
ar_debug
=
result
.
boolean
;
break
;
case
Opt_upgrade
:
...
...
@@ -1389,27 +1389,27 @@ static int gfs2_parse_param(struct fs_context *fc, struct fs_parameter *param)
break
;
case
Opt_commit
:
if
(
result
.
int_32
<=
0
)
return
invalf
(
fc
,
"gfs2:
commit mount option requires a positive numeric argument"
);
return
invalf
c
(
fc
,
"
commit mount option requires a positive numeric argument"
);
args
->
ar_commit
=
result
.
int_32
;
break
;
case
Opt_statfs_quantum
:
if
(
result
.
int_32
<
0
)
return
invalf
(
fc
,
"gfs2:
statfs_quantum mount option requires a non-negative numeric argument"
);
return
invalf
c
(
fc
,
"
statfs_quantum mount option requires a non-negative numeric argument"
);
args
->
ar_statfs_quantum
=
result
.
int_32
;
break
;
case
Opt_quota_quantum
:
if
(
result
.
int_32
<=
0
)
return
invalf
(
fc
,
"gfs2:
quota_quantum mount option requires a positive numeric argument"
);
return
invalf
c
(
fc
,
"
quota_quantum mount option requires a positive numeric argument"
);
args
->
ar_quota_quantum
=
result
.
int_32
;
break
;
case
Opt_statfs_percent
:
if
(
result
.
int_32
<
0
||
result
.
int_32
>
100
)
return
invalf
(
fc
,
"gfs2:
statfs_percent mount option requires a numeric argument between 0 and 100"
);
return
invalf
c
(
fc
,
"
statfs_percent mount option requires a numeric argument between 0 and 100"
);
args
->
ar_statfs_percent
=
result
.
int_32
;
break
;
case
Opt_errors
:
if
(
args
->
ar_debug
&&
result
.
uint_32
==
GFS2_ERRORS_PANIC
)
return
invalf
(
fc
,
"gfs2:
-o debug and -o errors=panic are mutually exclusive"
);
return
invalf
c
(
fc
,
"
-o debug and -o errors=panic are mutually exclusive"
);
args
->
ar_errors
=
result
.
uint_32
;
break
;
case
Opt_barrier
:
...
...
@@ -1422,7 +1422,7 @@ static int gfs2_parse_param(struct fs_context *fc, struct fs_parameter *param)
args
->
ar_loccookie
=
result
.
boolean
;
break
;
default:
return
invalf
(
fc
,
"gfs2:
invalid mount option: %s"
,
param
->
key
);
return
invalf
c
(
fc
,
"
invalid mount option: %s"
,
param
->
key
);
}
return
0
;
}
...
...
@@ -1448,27 +1448,27 @@ static int gfs2_reconfigure(struct fs_context *fc)
spin_unlock
(
&
gt
->
gt_spin
);
if
(
strcmp
(
newargs
->
ar_lockproto
,
oldargs
->
ar_lockproto
))
{
errorf
(
fc
,
"gfs2:
reconfiguration of locking protocol not allowed"
);
errorf
c
(
fc
,
"
reconfiguration of locking protocol not allowed"
);
return
-
EINVAL
;
}
if
(
strcmp
(
newargs
->
ar_locktable
,
oldargs
->
ar_locktable
))
{
errorf
(
fc
,
"gfs2:
reconfiguration of lock table not allowed"
);
errorf
c
(
fc
,
"
reconfiguration of lock table not allowed"
);
return
-
EINVAL
;
}
if
(
strcmp
(
newargs
->
ar_hostdata
,
oldargs
->
ar_hostdata
))
{
errorf
(
fc
,
"gfs2:
reconfiguration of host data not allowed"
);
errorf
c
(
fc
,
"
reconfiguration of host data not allowed"
);
return
-
EINVAL
;
}
if
(
newargs
->
ar_spectator
!=
oldargs
->
ar_spectator
)
{
errorf
(
fc
,
"gfs2:
reconfiguration of spectator mode not allowed"
);
errorf
c
(
fc
,
"
reconfiguration of spectator mode not allowed"
);
return
-
EINVAL
;
}
if
(
newargs
->
ar_localflocks
!=
oldargs
->
ar_localflocks
)
{
errorf
(
fc
,
"gfs2:
reconfiguration of localflocks not allowed"
);
errorf
c
(
fc
,
"
reconfiguration of localflocks not allowed"
);
return
-
EINVAL
;
}
if
(
newargs
->
ar_meta
!=
oldargs
->
ar_meta
)
{
errorf
(
fc
,
"gfs2:
switching between gfs2 and gfs2meta not allowed"
);
errorf
c
(
fc
,
"
switching between gfs2 and gfs2meta not allowed"
);
return
-
EINVAL
;
}
if
(
oldargs
->
ar_spectator
)
...
...
@@ -1478,11 +1478,11 @@ static int gfs2_reconfigure(struct fs_context *fc)
if
(
fc
->
sb_flags
&
SB_RDONLY
)
{
error
=
gfs2_make_fs_ro
(
sdp
);
if
(
error
)
errorf
(
fc
,
"gfs2:
unable to remount read-only"
);
errorf
c
(
fc
,
"
unable to remount read-only"
);
}
else
{
error
=
gfs2_make_fs_rw
(
sdp
);
if
(
error
)
errorf
(
fc
,
"gfs2:
unable to remount read-write"
);
errorf
c
(
fc
,
"
unable to remount read-write"
);
}
}
sdp
->
sd_args
=
*
newargs
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录