]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
IB/ipath: validate path_mig_state properly
authorBryan O'Sullivan <bos@pathscale.com>
Fri, 25 Aug 2006 18:24:42 +0000 (11:24 -0700)
committerRoland Dreier <rolandd@cisco.com>
Fri, 22 Sep 2006 22:22:37 +0000 (15:22 -0700)
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/hw/ipath/ipath_qp.c

index 502d555fdf371da1f8607d0969846b42c864d5c5..77391886d2f8dd5de15733744fb8f1afd3fcc1db 100644 (file)
@@ -491,7 +491,8 @@ int ipath_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr,
                        goto inval;
 
        if (attr_mask & IB_QP_PATH_MIG_STATE)
-               if (attr->path_mig_state != IB_MIG_MIGRATED)
+               if (attr->path_mig_state != IB_MIG_MIGRATED &&
+                   attr->path_mig_state != IB_MIG_REARM)
                        goto inval;
 
        switch (new_state) {