diff options
author | Laurent Vivier <lvivier@redhat.com> | 2024-01-24 11:40:06 +0100 |
---|---|---|
committer | Jason Wang <jasowang@redhat.com> | 2024-03-12 19:28:32 +0800 |
commit | 4cadf10234989861398e19f3bb441d3861f3bb7c (patch) | |
tree | b38022da1710655fbe971ed9197cc8d49b6e2cf7 /hw/net/e1000e_core.h | |
parent | 65c2ab808571dcd9322020690a63df63281a67f0 (diff) |
e1000e: fix link state on resume
On resume e1000e_vm_state_change() always calls e1000e_autoneg_resume()
that sets link_down to false, and thus activates the link even
if we have disabled it.
The problem can be reproduced starting qemu in paused state (-S) and
then set the link to down. When we resume the machine the link appears
to be up.
Reproducer:
# qemu-system-x86_64 ... -device e1000e,netdev=netdev0,id=net0 -S
{"execute": "qmp_capabilities" }
{"execute": "set_link", "arguments": {"name": "net0", "up": false}}
{"execute": "cont" }
To fix the problem, merge the content of e1000e_vm_state_change()
into e1000e_core_post_load() as e1000 does.
Buglink: https://issues.redhat.com/browse/RHEL-21867
Fixes: 6f3fbe4ed06a ("net: Introduce e1000e device emulation")
Suggested-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Signed-off-by: Laurent Vivier <lvivier@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Diffstat (limited to 'hw/net/e1000e_core.h')
-rw-r--r-- | hw/net/e1000e_core.h | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/hw/net/e1000e_core.h b/hw/net/e1000e_core.h index 66b025cc43..01510ca78b 100644 --- a/hw/net/e1000e_core.h +++ b/hw/net/e1000e_core.h @@ -98,8 +98,6 @@ struct E1000Core { E1000IntrDelayTimer eitr[E1000E_MSIX_VEC_NUM]; - VMChangeStateEntry *vmstate; - uint32_t itr_guest_value; uint32_t eitr_guest_value[E1000E_MSIX_VEC_NUM]; |