Skip to content

Commit 7baaa49

Browse files
paravmellanoxjgunthorpe
authored andcommitted
RDMA/cma: Use correct size when writing netlink stats
The code was using the src size when formatting the dst. They are almost certainly the same value but it reads wrong. Fixes: ce117ff ("RDMA/cma: Export AF_IB statistics") Signed-off-by: Parav Pandit <[email protected]> Reviewed-by: Daniel Jurgens <[email protected]> Signed-off-by: Leon Romanovsky <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
1 parent 98aebc5 commit 7baaa49

File tree

1 file changed

+1
-1
lines changed
  • drivers/infiniband/core

1 file changed

+1
-1
lines changed

drivers/infiniband/core/cma.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4431,7 +4431,7 @@ static int cma_get_id_stats(struct sk_buff *skb, struct netlink_callback *cb)
44314431
RDMA_NL_RDMA_CM_ATTR_SRC_ADDR))
44324432
goto out;
44334433
if (ibnl_put_attr(skb, nlh,
4434-
rdma_addr_size(cma_src_addr(id_priv)),
4434+
rdma_addr_size(cma_dst_addr(id_priv)),
44354435
cma_dst_addr(id_priv),
44364436
RDMA_NL_RDMA_CM_ATTR_DST_ADDR))
44374437
goto out;

0 commit comments

Comments
 (0)