Instead of the open coded version, makes sparse work. Signed-off-by: Jason Gunthorpe <jgunthorpe@xxxxxxxxxxxxxxxxxxxx> --- CMakeLists.txt | 4 ++-- providers/rxe/rxe.c | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7a05c3602bca2d..e5074f6e100637 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -392,8 +392,8 @@ endif() add_subdirectory(providers/hfi1verbs) # NO SPARSE add_subdirectory(providers/ipathverbs) # NO SPARSE -add_subdirectory(providers/rxe) # NO SPARSE -add_subdirectory(providers/rxe/man) # NO SPARSE +add_subdirectory(providers/rxe) +add_subdirectory(providers/rxe/man) # Binaries add_subdirectory(ibacm) # NO SPARSE diff --git a/providers/rxe/rxe.c b/providers/rxe/rxe.c index 438f7c30505dd1..775caf0e185148 100644 --- a/providers/rxe/rxe.c +++ b/providers/rxe/rxe.c @@ -753,8 +753,7 @@ static int rxe_post_recv(struct ibv_qp *ibqp, static inline int ipv6_addr_v4mapped(const struct in6_addr *a) { - return ((unsigned long)(a->s6_addr32[0] | a->s6_addr32[1]) | - (unsigned long)(a->s6_addr32[2] ^ htobe32(0x0000ffff))) == 0UL; + return IN6_IS_ADDR_V4MAPPED(a); } static inline int rdma_gid2ip(struct sockaddr *out, union ibv_gid *gid) -- 2.7.4 -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html