While the endiannes is being handled correctly as indicated by the commentThanks. I was worried about this macro magic o.w
above the offending line - sparse was unhappy with the missing annotation
as be64_to_cpu() expects a __be64 argument. To mitigate this annotation
all involved variables are changed to a consistent __le64 and the
conversion to uint64_t delayed to the call to rds_cong_map_updated().
Signed-off-by: Nicholas Mc Guire <hofrat@xxxxxxxxx>
---
Problem located by an experimental coccinelle script to locate
patters that make sparse unhappy (false positives):
net/rds/ib_recv.c:827:23: warning: cast to restricted __le64
V2: Edward Cree <ecree@xxxxxxxxxxxxxx> rejected the need for using __force
here - instead solve the sparse issue by updating all of the involved
variables - which results in an identical binary as well without using
the __force "solution" to the sparse warning. Thanks !
Patch was compile-tested with: x86_64_defconfig + INFINIBAND=m, RDS_RDMA=m
Patch was verified not to change the binary by diffing the
generated object code before and after applying the patch.