Commit
2bbf6158c769 ("net/rds: remove the RDS specific path record
caching") has changed the service level (SL) to TOS mapping to be
1:1. Nevertheless, it has assigned the SL to be a 8-bit value even though
IB specification section 7.7.3 mentioned that the SL is only a 4-bit
field. Thus, this patch assigns the SL correctly.
Orabug:
27607213
Signed-off-by: Wei Lin Guay <wei.lin.guay@oracle.com>
Reported-by: Håkon Bugge <haakon.bugge@oracle.com>
Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com>
Signed-off-by: Somasundaram Krishnasamy <somasundaram.krishnasamy@oracle.com>
(cherry picked from commit
8305552e624618c7196575d5a6ae64c0c024fc20
repo uek5)
Signed-off-by: Håkon Bugge <haakon.bugge@oracle.com>
Reviewed-by: Zhu Yanjun <yanjun.zhu@oracle.com>
Signed-off-by: Brian Maly <brian.maly@oracle.com>
* needs to update the sl manually. As for now, RDS is assuming
* that it is a 1:1 in tos to sl mapping.
*/
- cm_id->route.path_rec[0].sl = conn->c_tos;
+ cm_id->route.path_rec[0].sl = TOS_TO_SL(conn->c_tos);
cm_id->route.path_rec[0].qos_class = conn->c_tos;
ret = trans->cm_initiate_connect(cm_id, isv6);
} else {
#define RDS_RDMA_RESOLVE_TIMEOUT_MS 5000
+/* Per IB specification 7.7.3, service level is a 4-bit field. */
+#define TOS_TO_SL(tos) ((tos) & 0xF)
+
int rds_rdma_conn_connect(struct rds_connection *conn);
int rds_rdma_cm_event_handler(struct rdma_cm_id *cm_id,
struct rdma_cm_event *event);