int wdc_obio_detach(struct device *self, int flags) { struct wdc_obio_softc *sc = (struct wdc_obio_softc *)self; struct channel_softc *chp = &sc->wdc_channel; int error; if ((error = wdcdetach(chp, flags)) != 0) return (error); free(chp->ch_queue, M_DEVBUF); if (sc->sc_use_dma) { unmapiodev((void *)sc->sc_dmareg, sc->sc_dmasize); dbdma_free(sc->sc_dbdma); } mac_intr_disestablish(NULL, sc->sc_ih); bus_space_unmap(chp->cmd_iot, chp->cmd_ioh, sc->sc_cmdsize); bus_dmamap_destroy(sc->sc_dmat, sc->sc_dmamap); return (0); }
void pciide_machdep_compat_intr_disestablish(pci_chipset_tag_t pc, void *cookie) { mac_intr_disestablish(NULL, cookie); }