提交 c650ba73 编写于 作者: T Tina Ruchandani 提交者: Greg Kroah-Hartman

Staging: lustre: llite: Simplify error handling

This patch fixes the following checkpatch error:
ERROR: do not use assignment in if condition
2172: FILE: drivers/staging/lustre/lustre/llite/llite_lib.c:2172:
        if (!inode || !(sbi = ll_i2sbi(inode))) {
Signed-off-by: NTina Ruchandani <ruchandani.tina@gmail.com>
Suggested-by: NJosh Triplett <josh@joshtriplett.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 f526b20a
...@@ -2169,7 +2169,13 @@ int ll_obd_statfs(struct inode *inode, void *arg) ...@@ -2169,7 +2169,13 @@ int ll_obd_statfs(struct inode *inode, void *arg)
__u32 flags; __u32 flags;
int len = 0, rc; int len = 0, rc;
if (!inode || !(sbi = ll_i2sbi(inode))) { if (!inode) {
rc = -EINVAL;
goto out_statfs;
}
sbi = ll_i2sbi(inode);
if (!sbi) {
rc = -EINVAL; rc = -EINVAL;
goto out_statfs; goto out_statfs;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册