Skip to content
Snippets Groups Projects
Commit b1927cf1 authored by Jan Kiszka's avatar Jan Kiszka Committed by Stefan Hajnoczi
Browse files

e1000: Preserve link state across device reset


A device reset does not affect the link state, only set_link does.

Signed-off-by: default avatarJan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: default avatarStefan Hajnoczi <stefanha@linux.vnet.ibm.com>
parent c455d17c
No related branches found
No related tags found
No related merge requests found
......@@ -1133,6 +1133,11 @@ static void e1000_reset(void *opaque)
memmove(d->mac_reg, mac_reg_init, sizeof mac_reg_init);
d->rxbuf_min_shift = 1;
memset(&d->tx, 0, sizeof d->tx);
if (d->nic->nc.link_down) {
d->mac_reg[STATUS] &= ~E1000_STATUS_LU;
d->phy_reg[PHY_STATUS] &= ~MII_SR_LINK_STATUS;
}
}
static NetClientInfo net_e1000_info = {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment