Deleted Added
full compact
30c30
< * $FreeBSD: head/sys/dev/hme/if_hme_pci.c 93043 2002-03-23 19:37:11Z tmm $
---
> * $FreeBSD: head/sys/dev/hme/if_hme_pci.c 108976 2003-01-09 00:45:10Z tmm $
79a80,82
> static int hme_pci_detach(device_t);
> static int hme_pci_suspend(device_t);
> static int hme_pci_resume(device_t);
84a88,92
> DEVMETHOD(device_detach, hme_pci_detach),
> DEVMETHOD(device_suspend, hme_pci_suspend),
> DEVMETHOD(device_resume, hme_pci_resume),
> /* Can just use the suspend method here. */
> DEVMETHOD(device_shutdown, hme_pci_suspend),
184a193
> hme_detach(sc);
194a204,237
>
> static int
> hme_pci_detach(device_t dev)
> {
> struct hme_pci_softc *hsc = device_get_softc(dev);
> struct hme_softc *sc = &hsc->hsc_hme;
>
> hme_detach(sc);
>
> bus_teardown_intr(dev, hsc->hsc_ires, hsc->hsc_ih);
> bus_release_resource(dev, SYS_RES_IRQ, hsc->hsc_irid, hsc->hsc_ires);
> bus_release_resource(dev, SYS_RES_MEMORY, hsc->hsc_srid, hsc->hsc_sres);
> return (0);
> }
>
> static int
> hme_pci_suspend(device_t dev)
> {
> struct hme_pci_softc *hsc = device_get_softc(dev);
> struct hme_softc *sc = &hsc->hsc_hme;
>
> hme_suspend(sc);
> return (0);
> }
>
> static int
> hme_pci_resume(device_t dev)
> {
> struct hme_pci_softc *hsc = device_get_softc(dev);
> struct hme_softc *sc = &hsc->hsc_hme;
>
> hme_resume(sc);
> return (0);
> }