Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=92761cdaf215599a1bd81d383facb32adabfa620
Commit:     92761cdaf215599a1bd81d383facb32adabfa620
Parent:     5d88278e3bdb6f2e4ed43306659e930ecd715f0c
Author:     Joachim Fenkes <[EMAIL PROTECTED]>
AuthorDate: Wed May 9 13:48:01 2007 +0200
Committer:  Roland Dreier <[EMAIL PROTECTED]>
CommitDate: Mon May 14 13:38:57 2007 -0700

    IB/ehca: Correctly set GRH mask bit in ehca_modify_qp()
    
    The driver needs to always supply the "GRH present" flag to the
    hypervisor, whether it's true or false. Not supplying it (i.e. not
    setting the corresponding mask bit) amounts to a "perhaps", which we
    don't want.
    
    Signed-off-by: Joachim Fenkes <[EMAIL PROTECTED]>
    Signed-off-by: Roland Dreier <[EMAIL PROTECTED]>
---
 drivers/infiniband/hw/ehca/ehca_qp.c |   12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)

diff --git a/drivers/infiniband/hw/ehca/ehca_qp.c 
b/drivers/infiniband/hw/ehca/ehca_qp.c
index df0516f..e21d796 100644
--- a/drivers/infiniband/hw/ehca/ehca_qp.c
+++ b/drivers/infiniband/hw/ehca/ehca_qp.c
@@ -968,17 +968,21 @@ static int internal_modify_qp(struct ib_qp *ibqp,
                        ((ehca_mult - 1) / ah_mult) : 0;
                else
                        mqpcb->max_static_rate = 0;
-
                update_mask |= EHCA_BMASK_SET(MQPCB_MASK_MAX_STATIC_RATE, 1);
 
                /*
+                * Always supply the GRH flag, even if it's zero, to give the
+                * hypervisor a clear "yes" or "no" instead of a "perhaps"
+                */
+               update_mask |= EHCA_BMASK_SET(MQPCB_MASK_SEND_GRH_FLAG, 1);
+
+               /*
                 * only if GRH is TRUE we might consider SOURCE_GID_IDX
                 * and DEST_GID otherwise phype will return H_ATTR_PARM!!!
                 */
                if (attr->ah_attr.ah_flags == IB_AH_GRH) {
-                       mqpcb->send_grh_flag = 1 << 31;
-                       update_mask |=
-                               EHCA_BMASK_SET(MQPCB_MASK_SEND_GRH_FLAG, 1);
+                       mqpcb->send_grh_flag = 1;
+
                        mqpcb->source_gid_idx = attr->ah_attr.grh.sgid_index;
                        update_mask |=
                                EHCA_BMASK_SET(MQPCB_MASK_SOURCE_GID_IDX, 1);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to