diff options
Diffstat (limited to 'sys/dev/mly/mly.c')
-rw-r--r-- | sys/dev/mly/mly.c | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/sys/dev/mly/mly.c b/sys/dev/mly/mly.c index a5c568b10433..a58b21b8f08e 100644 --- a/sys/dev/mly/mly.c +++ b/sys/dev/mly/mly.c @@ -333,7 +333,6 @@ static int mly_pci_attach(struct mly_softc *sc) { int i, error; - u_int32_t command; debug_called(1); @@ -342,21 +341,8 @@ mly_pci_attach(struct mly_softc *sc) /* * Verify that the adapter is correctly set up in PCI space. - * - * XXX we shouldn't do this; the PCI code should. */ - command = pci_read_config(sc->mly_dev, PCIR_COMMAND, 2); - command |= PCIM_CMD_BUSMASTEREN; - pci_write_config(sc->mly_dev, PCIR_COMMAND, command, 2); - command = pci_read_config(sc->mly_dev, PCIR_COMMAND, 2); - if (!(command & PCIM_CMD_BUSMASTEREN)) { - mly_printf(sc, "can't enable busmaster feature\n"); - goto fail; - } - if ((command & PCIM_CMD_MEMEN) == 0) { - mly_printf(sc, "memory window not available\n"); - goto fail; - } + pci_enable_busmaster(sc->mly_dev); /* * Allocate the PCI register window. |