staging: lustre: Fix unneeded byte-ordering cast

Fix sparse warning:

  CHECK   drivers/staging//lustre/lnet/lnet/acceptor.c
drivers/staging//lustre/lnet/lnet/acceptor.c:243:30: warning: cast to
restricted __le32

LNET_PROTO_TCP_MAGIC, as a define, is already CPU byte-ordered when
compared to 'magic', so no need for a cast.

Signed-off-by: Justin Skists <j.skists@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Justin Skists 2018-03-17 09:15:41 +00:00 committed by Greg Kroah-Hartman
parent ad7d95e979
commit 80782927e3

View File

@ -240,7 +240,7 @@ lnet_accept(struct socket *sock, __u32 magic)
return -EPROTO;
}
if (magic == le32_to_cpu(LNET_PROTO_TCP_MAGIC))
if (magic == LNET_PROTO_TCP_MAGIC)
str = "'old' socknal/tcpnal";
else
str = "unrecognised";