ipmi: fix runtime on powerpc64le

Summary:
OPAL runs in big-endian mode, so we need to byteswap msg_len on little-endian.

MFC after:	1 week

Test Plan: ipmitool lan print

Reviewers: #powerpc

Subscribers: imp

Differential Revision: https://reviews.freebsd.org/D49530
This commit is contained in:
Piotr Kubaj 2025-03-27 12:55:48 +01:00
parent 6d6c97fb72
commit 2e16618fe7

View file

@ -93,6 +93,7 @@ opal_ipmi_recv(struct opal_ipmi_softc *sc, uint64_t *msg_len, int timo)
opal_call(OPAL_POLL_EVENTS, NULL);
err = opal_call(OPAL_IPMI_RECV, sc->sc_interface,
vtophys(sc->sc_msg), vtophys(msg_len));
*msg_len = be64toh(*msg_len);
if (err != OPAL_EMPTY)
break;