diff options
-rw-r--r-- | sys/dev/pcmcia/if_malo.c | 7 | ||||
-rw-r--r-- | sys/dev/pcmcia/if_malovar.h | 17 |
2 files changed, 6 insertions, 18 deletions
diff --git a/sys/dev/pcmcia/if_malo.c b/sys/dev/pcmcia/if_malo.c index 12557ca8570..927d611e05f 100644 --- a/sys/dev/pcmcia/if_malo.c +++ b/sys/dev/pcmcia/if_malo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_malo.c,v 1.10 2007/06/03 11:04:46 mglocker Exp $ */ +/* $OpenBSD: if_malo.c,v 1.11 2007/06/03 21:26:41 mglocker Exp $ */ /* * Copyright (c) 2007 Marcus Glocker <mglocker@openbsd.org> @@ -703,6 +703,9 @@ cmalo_rx(struct malo_softc *sc) /* access RX packet descriptor */ rxdesc = (struct malo_rx_desc *)sc->sc_data; + rxdesc->status = letoh16(rxdesc->status); + rxdesc->pkglen = letoh16(rxdesc->pkglen); + rxdesc->pkgoffset = letoh32(rxdesc->pkgoffset); DPRINTF(2, "RX status=%d, pkglen=%d, pkgoffset=%d\n", rxdesc->status, rxdesc->pkglen, rxdesc->pkgoffset); @@ -730,7 +733,7 @@ cmalo_rx(struct malo_softc *sc) return; } m->m_pkthdr.rcvif = ifp; - m->m_pkthdr.len = m->m_len = letoh16(rxdesc->pkglen); + m->m_pkthdr.len = m->m_len = rxdesc->pkglen; data = mtod(m, uint8_t *); bcopy(sc->sc_data + rxdesc->pkgoffset, data, m->m_pkthdr.len); diff --git a/sys/dev/pcmcia/if_malovar.h b/sys/dev/pcmcia/if_malovar.h index 79740109658..987600d8d99 100644 --- a/sys/dev/pcmcia/if_malovar.h +++ b/sys/dev/pcmcia/if_malovar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: if_malovar.h,v 1.6 2007/06/01 23:43:32 mglocker Exp $ */ +/* $OpenBSD: if_malovar.h,v 1.7 2007/06/03 21:26:41 mglocker Exp $ */ /* * Copyright (c) 2007 Marcus Glocker <mglocker@openbsd.org> @@ -66,16 +66,6 @@ struct malo_cmd_body_spec { uint32_t fw_capinfo; } __packed; -struct malo_cmd_body_status { - uint16_t fw_status; - uint16_t mac_status; - uint16_t rf_status; - uint16_t current_channel; - uint8_t ap_mac[ETHER_ADDR_LEN]; - uint16_t reserved; - uint32_t max_linkspeed; -} __packed; - struct malo_cmd_body_radio { uint16_t action; uint16_t control; @@ -104,11 +94,6 @@ struct malo_cmd_body_macctrl { uint16_t reserved; } __packed; -struct malo_cmd_body_macaddr { - uint16_t action; - uint8_t macaddr[ETHER_ADDR_LEN]; -} __packed; - /* RX descriptor */ #define MALO_RX_STATUS_OK 0x0001 struct malo_rx_desc { |