On Wed, Jun 22, 2011 at 10:02:42AM +0000, Thomas Gerlach wrote: > as for the "pulling toghether", i would suggest something like this (draft, > patches against latest -current files, _without_ stefan's recent patches):
> +#if 1 > #ifndef SMALL_KERNEL > #endif > +#endif Huh? > @@ -367,6 +365,22 @@ > { > u_int32_t command; > struct xl_pci_softc *psc = (struct xl_pci_softc*)ppsc; > + struct xl_softc *sc = &psc->psc_softc; > + > + XL_SEL_WIN(7); > + > + /* Clear any pending PME events. */ > + CSR_READ_2(sc, XL_W7_BM_PME); > + > + /* If WOL flag is not set make sure PME is disabled, and > + * return without doing anything. */ > + if ((sc->xl_flags & XL_FLAG_WOL) == 0) { > + CSR_WRITE_2(sc, XL_W7_BM_PME, 0); > + return; > + } > + > + CSR_WRITE_2(sc, XL_W7_BM_PME, XL_BM_PME_MAGIC); > + CSR_WRITE_2(sc, XL_COMMAND, XL_CMD_RX_ENABLE); I see what you mean now but I don't know if putting these register writes into the PCI glue code is appropriate.