bnx2: Replace open-coded byte swapping with swab32s()
authorHeiner Kallweit <hkallweit1@gmail.com>
Sun, 22 Aug 2021 13:52:01 +0000 (15:52 +0200)
committerBjorn Helgaas <bhelgaas@google.com>
Tue, 24 Aug 2021 16:43:30 +0000 (11:43 -0500)
commit35e7f1be7972be8da9d0a37bd89bcc4b990c6e67
treeb89eca52b4757ed8be38b0fecbb457a0cec28df5
parent1a41fdb805705251fc61715167cadc0829de587a
bnx2: Replace open-coded byte swapping with swab32s()

Read NVRAM directly into buffer and use swab32s() to byte swap it in-place
instead of reading it into the end of the buffer and swapping it manually
while copying it.

[bhelgaas: commit log]
Link: https://lore.kernel.org/r/e4ac6229-1df5-8760-3a87-1ad0ace87137@gmail.com
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/net/ethernet/broadcom/bnx2.c