]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/rxe: Restore setting tot_len in the IPv4 header
authorBob Pearson <rpearsonhpe@gmail.com>
Thu, 29 Jul 2021 22:00:39 +0000 (17:00 -0500)
committerJason Gunthorpe <jgg@nvidia.com>
Mon, 2 Aug 2021 15:45:22 +0000 (12:45 -0300)
commit7368aeddd362359b39eacb2b9c9e58ee35601ac7
tree46d6b9f2a1231159413aa5f982250aff1efc16e7
parenta5d7743cf6b1f81e46955afd4d506cb3b7c39ea9
RDMA/rxe: Restore setting tot_len in the IPv4 header

An earlier patch removed setting of tot_len in IPv4 headers because it was
also set in ip_local_out. However, this change resulted in an incorrect
ICRC being computed because the tot_len field is not masked out. This
patch restores that line. This fixes the bug reported by Zhu Yanjun.  This
bug affects anyone using rxe which is currently broken.

Fixes: 84db2036a88e ("RDMA/rxe: Fix redundant call to ip_send_check")
Link: https://lore.kernel.org/r/20210729220039.18549-3-rpearsonhpe@gmail.com
Reported-by: Zhu Yanjun <zyjzyj2000@gmail.com>
Signed-off-by: Bob Pearson <rpearsonhpe@gmail.com>
Reviewed-and-tested-by: Zhu Yanjun <zyjzyj2000@gmail.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/sw/rxe/rxe_net.c