]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
staging: lustre: lov: remove always false condition
authorSudip Mukherjee <sudipm.mukherjee@gmail.com>
Tue, 8 Sep 2015 16:23:02 +0000 (21:53 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 13 Sep 2015 01:24:51 +0000 (18:24 -0700)
The member qc_idx of struct if_quotactl is unsigned and hence it can
never be less than zero.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/lov/lov_obd.c

index 2a2fd8de055d091929575dace872f27acf334699..906503b0597984a3fa23b29c28f7d578538b295e 100644 (file)
@@ -1487,7 +1487,7 @@ static int lov_iocontrol(unsigned int cmd, struct obd_export *exp, int len,
                struct obd_quotactl *oqctl;
 
                if (qctl->qc_valid == QC_OSTIDX) {
-                       if (qctl->qc_idx < 0 || count <= qctl->qc_idx)
+                       if (count <= qctl->qc_idx)
                                return -EINVAL;
 
                        tgt = lov->lov_tgts[qctl->qc_idx];