IB/ucm: Get rid of duplicate P_Key parameter
authorSean Hefty <sean.hefty@intel.com>
Sun, 18 Jun 2006 03:37:39 +0000 (20:37 -0700)
committerRoland Dreier <rolandd@cisco.com>
Sun, 18 Jun 2006 03:37:39 +0000 (20:37 -0700)
The P_Key is provided into a SIDR REQ in two places, once as a
parameter, and again in the path record.  Remove the P_Key as a
parameter and always use the one given in the path record.

This change has no practical effect on ABI functionality.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
drivers/infiniband/core/cm.c
drivers/infiniband/core/ucm.c
include/rdma/ib_cm.h
include/rdma/ib_user_cm.h

index 1c7463b7c5fd57c783580c6edfbc76f2af50d1d0..629ed26a01769a46ea3febc93321442629342ea2 100644 (file)
@@ -2615,7 +2615,7 @@ static void cm_format_sidr_req(struct cm_sidr_req_msg *sidr_req_msg,
        cm_format_mad_hdr(&sidr_req_msg->hdr, CM_SIDR_REQ_ATTR_ID,
                          cm_form_tid(cm_id_priv, CM_MSG_SEQUENCE_SIDR));
        sidr_req_msg->request_id = cm_id_priv->id.local_id;
-       sidr_req_msg->pkey = cpu_to_be16(param->pkey);
+       sidr_req_msg->pkey = cpu_to_be16(param->path->pkey);
        sidr_req_msg->service_id = param->service_id;
 
        if (param->private_data && param->private_data_len)
index 67caf36504ee0c8b7a82455d5b0e9acb081f8d18..c1c6fda9452cc44f6b44400e00eaa7f5e42ea43a 100644 (file)
@@ -1044,7 +1044,6 @@ static ssize_t ib_ucm_send_sidr_req(struct ib_ucm_file *file,
        param.service_id       = cmd.sid;
        param.timeout_ms       = cmd.timeout;
        param.max_cm_retries   = cmd.max_cm_retries;
-       param.pkey             = cmd.pkey;
 
        ctx = ib_ucm_ctx_get(file, cmd.id);
        if (!IS_ERR(ctx)) {
index 8f394f035684a417ba7febe6cd502727934d1633..c9b4738be9d68021067b8911c68713362d2d0c9d 100644 (file)
@@ -546,7 +546,6 @@ struct ib_cm_sidr_req_param {
        const void              *private_data;
        u8                      private_data_len;
        u8                      max_cm_retries;
-       u16                     pkey;
 };
 
 /**
@@ -570,7 +569,7 @@ struct ib_cm_sidr_rep_param {
 };
 
 /**
- * ib_send_cm_sidr_rep - Sends a service ID resolution request to the
+ * ib_send_cm_sidr_rep - Sends a service ID resolution reply to the
  *   remote node.
  * @cm_id: Communication identifier associated with the received service ID
  *   resolution request.
index a9e1b22d245c38052587d29a863f4f74a2c62167..066c20b7cdfbf08019a3f23c7b17e93e4371e49b 100644 (file)
@@ -200,7 +200,7 @@ struct ib_ucm_sidr_req {
        __be64 sid;
        __u64 data;
        __u64 path;
-       __u16 pkey;
+       __u16 reserved_pkey;
        __u8  len;
        __u8  max_cm_retries;
        __u8  reserved[4];