2 * Copyright 2009, Colin Günther, coling@gmx.de.
3 * All Rights Reserved. Distributed under the terms of the MIT License.
8 #include <sys/kernel.h>
11 #include <net/if_media.h>
13 #include <net80211/ieee80211_var.h>
15 #include <machine/bus.h>
17 #include <dev/mwl/if_mwlvar.h>
20 HAIKU_FBSD_WLAN_DRIVER_GLUE(marvell88w8363
, mwl
, pci
)
21 HAIKU_DRIVER_REQUIREMENTS(FBSD_TASKQUEUES
| FBSD_WLAN
);
22 HAIKU_FIRMWARE_VERSION(0);
24 NO_HAIKU_FBSD_MII_DRIVER();
25 NO_HAIKU_FIRMWARE_NAME_MAP();
29 HAIKU_CHECK_DISABLE_INTERRUPTS(device_t dev
)
31 struct mwl_softc
* sc
= (struct mwl_softc
*)device_get_softc(dev
);
32 struct mwl_hal
* mh
= sc
->sc_mh
;
36 // The hardware is not ready/present, don't touch anything.
37 // Note this can happen early on if the IRQ is shared.
41 mwl_hal_getisr(mh
, &intr_status
);
44 if (intr_status
== 0) {
45 // must be a shared irq
49 atomic_set((int32
*)&sc
->sc_intr_status
, intr_status
);
51 mwl_hal_intrset(mh
, 0);
52 // disable further intr's
58 HAIKU_REENABLE_INTERRUPTS(device_t dev
)
60 struct mwl_softc
* sc
= (struct mwl_softc
*)device_get_softc(dev
);
61 struct mwl_hal
* mh
= sc
->sc_mh
;
63 mwl_hal_intrset(mh
, sc
->sc_imask
);