Map type of service, TOS, to IB or VLAN service level 1:1 in ibcore.
MFC after: 1 week Sponsored by: Mellanox Technologies
This commit is contained in:
parent
5b94bd8a69
commit
6d36a2c769
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=330495
@ -2422,8 +2422,17 @@ static int cma_resolve_iw_route(struct rdma_id_private *id_priv, int timeout_ms)
|
||||
|
||||
static int iboe_tos_to_sl(struct net_device *ndev, int tos)
|
||||
{
|
||||
/* TODO: Implement this function */
|
||||
return 0;
|
||||
/* get service level, SL, from type of service, TOS */
|
||||
int sl = tos;
|
||||
|
||||
/* range check input argument and map 1:1 */
|
||||
if (sl > 255)
|
||||
sl = 255;
|
||||
else if (sl < 0)
|
||||
sl = 0;
|
||||
|
||||
/* final mappings are done by the vendor specific drivers */
|
||||
return sl;
|
||||
}
|
||||
|
||||
static enum ib_gid_type cma_route_gid_type(enum rdma_network_type network_type,
|
||||
|
Loading…
Reference in New Issue
Block a user