Commit 19c55148 authored by Sebastien Buisson's avatar Sebastien Buisson Committed by Greg Kroah-Hartman

staging: lustre: fix 'no effect' errors

Fix 'no effect' issues found by Coverity version 6.5.1:

Unsigned compared against 0 (NO_EFFECT)
This greater-than-or-equal-to-zero comparison of an unsigned value
is always true.

Remove useless cast.
Signed-off-by: default avatarSebastien Buisson <sbuisson@ddn.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3907
Reviewed-on: http://review.whamcloud.com/7166Reviewed-by: default avatarOleg Drokin <oleg.drokin@intel.com>
Signed-off-by: default avatarJames Simmons <jsimmons@infradead.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e1798006
......@@ -424,8 +424,7 @@ int ll_getxattr_common(struct inode *inode, const char *name,
if (rce && rce->rce_ops == RMT_LSETFACL) {
ext_acl_xattr_header *acl;
acl = lustre_posix_acl_xattr_2ext(
(posix_acl_xattr_header *)buffer, rc);
acl = lustre_posix_acl_xattr_2ext(buffer, rc);
if (IS_ERR(acl)) {
rc = PTR_ERR(acl);
goto out;
......
......@@ -926,7 +926,7 @@ static int lmv_iocontrol(unsigned int cmd, struct obd_export *exp,
struct obd_quotactl *oqctl;
if (qctl->qc_valid == QC_MDTIDX) {
if (qctl->qc_idx < 0 || count <= qctl->qc_idx)
if (count <= qctl->qc_idx)
return -EINVAL;
tgt = lmv->tgts[qctl->qc_idx];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment