From: Jacky Chou Date: Mon, 5 Feb 2024 08:02:28 +0000 (+0800) Subject: net: phy: ncsi: Correct the endian of the checksum X-Git-Url: http://git.dujemihanovic.xyz/img/%7B%7B%20%24image.RelPermalink%20%7D%7D?a=commitdiff_plain;h=60d77b6f91f08d3be3b03d188c30c9b47e800a62;p=u-boot.git net: phy: ncsi: Correct the endian of the checksum There is no need to perform the endian twice here. Signed-off-by: Jacky Chou Reviewed-by: Dan Carpenter --- diff --git a/drivers/net/phy/ncsi.c b/drivers/net/phy/ncsi.c index 9689385884..f9069c3a10 100644 --- a/drivers/net/phy/ncsi.c +++ b/drivers/net/phy/ncsi.c @@ -551,7 +551,7 @@ static int ncsi_send_command(unsigned int np, unsigned int nc, unsigned int cmd, checksum = ncsi_calculate_checksum((unsigned char *)hdr, sizeof(*hdr) + len); pchecksum = (__be32 *)((void *)(hdr + 1) + len); - put_unaligned_be32(htonl(checksum), pchecksum); + put_unaligned_be32(checksum, pchecksum); if (wait) { net_set_timeout_handler(1000UL, ncsi_timeout_handler);