If MSI is not active make sure to disable MSI in EEPROM.

This commit is contained in:
Pyun YongHyeon 2008-07-02 06:45:59 +00:00
parent 81cf2eb6db
commit 4d2bf23925
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=180174

View file

@ -1195,6 +1195,17 @@ re_attach(dev)
}
}
if ((sc->rl_flags & RL_FLAG_MSI) == 0) {
CSR_WRITE_1(sc, RL_EECMD, RL_EE_MODE);
cfg = CSR_READ_1(sc, RL_CFG2);
if ((cfg & RL_CFG2_MSI) != 0) {
device_printf(dev, "turning off MSI enable bit.\n");
cfg &= ~RL_CFG2_MSI;
CSR_WRITE_1(sc, RL_CFG2, cfg);
}
CSR_WRITE_1(sc, RL_EECMD, RL_EEMODE_OFF);
}
/* Reset the adapter. */
RL_LOCK(sc);
re_reset(sc);