diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2014-03-27 23:17:41 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2014-03-27 23:17:41 +0000 |
commit | 7e979b7bff70328a256f259ca666679892688785 (patch) | |
tree | 9cf6f5f4432f01816039670f38f42df150a7834b | |
parent | 353fc667b4845bf583639cdf43d0cec1616fa115 (diff) |
unbreak mfii after i changed the layout of some structures it borrows
from mpii.
disappointment from deraadt@
-rw-r--r-- | sys/dev/pci/mfii.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/sys/dev/pci/mfii.c b/sys/dev/pci/mfii.c index 3e48e874b5d..80b967d5d82 100644 --- a/sys/dev/pci/mfii.c +++ b/sys/dev/pci/mfii.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mfii.c,v 1.13 2013/08/30 08:51:56 haesbaert Exp $ */ +/* $OpenBSD: mfii.c,v 1.14 2014/03/27 23:17:40 dlg Exp $ */ /* * Copyright (c) 2012 David Gwynne <dlg@openbsd.org> @@ -998,14 +998,18 @@ mfii_initialise_firmware(struct mfii_softc *sc) htole16(sc->sc_reply_postq_depth); iiq->reply_free_queue_depth = htole16(0); - iiq->sense_buffer_address_high = - htole32(MFII_DMA_DVA(sc->sc_sense) >> 32); + htolem32(&iiq->sense_buffer_address_high, + MFII_DMA_DVA(sc->sc_sense) >> 32); - iiq->reply_descriptor_post_queue_address = - htole64(MFII_DMA_DVA(sc->sc_reply_postq)); + htolem32(&iiq->reply_descriptor_post_queue_address_lo, + MFII_DMA_DVA(sc->sc_reply_postq)); + htolem32(&iiq->reply_descriptor_post_queue_address_hi, + MFII_DMA_DVA(sc->sc_reply_postq) >> 32); - iiq->system_request_frame_base_address = - htole64(MFII_DMA_DVA(sc->sc_requests)); + htolem32(&iiq->system_request_frame_base_address_lo, + MFII_DMA_DVA(sc->sc_requests)); + htolem32(&iiq->system_request_frame_base_address_lo, + MFII_DMA_DVA(sc->sc_requests) >> 32); iiq->timestamp = htole64(time_uptime); |