summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorPyun YongHyeon <yongari@FreeBSD.org>2008-04-15 00:46:15 +0000
committerPyun YongHyeon <yongari@FreeBSD.org>2008-04-15 00:46:15 +0000
commit339a44fb62595ffeb01a0a2d2f2ca87942038fb4 (patch)
treec4578b78a0a9b0df4e86b3261762ba71f1f15b93 /sys/dev
parent23080c0bd31b7b8b431ed18e2d10a3ad2af9490d (diff)
Notes
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/re/if_re.c18
1 files changed, 6 insertions, 12 deletions
diff --git a/sys/dev/re/if_re.c b/sys/dev/re/if_re.c
index d81e4d664437..2b0ef3a46503 100644
--- a/sys/dev/re/if_re.c
+++ b/sys/dev/re/if_re.c
@@ -1185,23 +1185,17 @@ re_attach(dev)
device_printf(dev, "Using %d MSI messages\n",
msic);
sc->rl_msi = 1;
+ /* Explicitly set MSI enable bit. */
+ CSR_WRITE_1(sc, RL_EECMD, RL_EE_MODE);
+ cfg = CSR_READ_1(sc, RL_CFG2);
+ cfg |= RL_CFG2_MSI;
+ CSR_WRITE_1(sc, RL_CFG2, cfg);
+ CSR_WRITE_1(sc, RL_EECMD, 0);
} else
pci_release_msi(dev);
}
}
- /* For MSI capable hardwares, explicitily set/clear MSI enable bit. */
- if (msic != 0) {
- CSR_WRITE_1(sc, RL_EECMD, RL_EE_MODE);
- cfg = CSR_READ_1(sc, RL_CFG2);
- if (sc->rl_msi != 0)
- cfg |= RL_CFG2_MSI;
- else
- cfg &= ~RL_CFG2_MSI;
- CSR_WRITE_1(sc, RL_CFG2, cfg);
- CSR_WRITE_1(sc, RL_EECMD, 0);
- }
-
/* Allocate interrupt */
if (sc->rl_msi == 0) {
rid = 0;