-----BEGIN PGP SIGNATURE-----

Version: GnuPG v1
 
 iQEcBAABAgAGBQJXurKIAAoJEO8Ells5jWIRUaAIAKy9h8aIpBV9JH7aeXmjbA8i
 WQGOOf1piiPjCayhfLOk0852MWYlGtTHRvJ4BkxK0ek+WeGnS7871QmfIE+VdZMt
 6fjYCzkQ2B5UQhqoahAbCNsCGrqxivHkLp9rl7nBm5gABowLGERfQzyVZ6fzwnqA
 EO05SSA09WfIi/F4JvklG3w+Iy8dprzq8UgzLaX2EoallYa3dkeJtB4yvF9Qikok
 Jz3uMTM2lOkWB6ccnDNGIYNJLsT3Q0mDnQ6y8mjv4zQambYPyd8W4iEOgtyk+sFJ
 +CYbZmpUsXAYgI0YNlukmfG/U3n2jCN043aTNmwfRzATi2qYXO95bohftjaFXck=
 =waIl
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/jasowang/tags/net-pull-request' into staging

# gpg: Signature made Mon 22 Aug 2016 09:06:32 BST
# gpg:                using RSA key 0xEF04965B398D6211
# gpg: Good signature from "Jason Wang (Jason Wang on RedHat) <jasowang@redhat.com>"
# gpg: WARNING: This key is not certified with sufficiently trusted signatures!
# gpg:          It is not certain that the signature belongs to the owner.
# Primary key fingerprint: 215D 46F4 8246 689E C77F  3562 EF04 965B 398D 6211

* remotes/jasowang/tags/net-pull-request:
  e1000e: remove internal interrupt flag
  slirp: fix segv when init failed

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
master
Peter Maydell 2016-08-22 10:02:28 +01:00
commit 62680fad7f
2 changed files with 4 additions and 8 deletions

View File

@ -69,7 +69,6 @@ typedef struct E1000EState {
uint16_t subsys_ven_used;
uint16_t subsys_used;
uint32_t intr_state;
bool disable_vnet;
E1000ECore core;
@ -89,8 +88,6 @@ typedef struct E1000EState {
#define E1000E_MSIX_TABLE (0x0000)
#define E1000E_MSIX_PBA (0x2000)
#define E1000E_USE_MSIX BIT(0)
static uint64_t
e1000e_mmio_read(void *opaque, hwaddr addr, unsigned size)
{
@ -302,8 +299,6 @@ e1000e_init_msix(E1000EState *s)
} else {
if (!e1000e_use_msix_vectors(s, E1000E_MSIX_VEC_NUM)) {
msix_uninit(d, &s->msix, &s->msix);
} else {
s->intr_state |= E1000E_USE_MSIX;
}
}
}
@ -311,7 +306,7 @@ e1000e_init_msix(E1000EState *s)
static void
e1000e_cleanup_msix(E1000EState *s)
{
if (s->intr_state & E1000E_USE_MSIX) {
if (msix_enabled(PCI_DEVICE(s))) {
e1000e_unuse_msix_vectors(s, E1000E_MSIX_VEC_NUM);
msix_uninit(PCI_DEVICE(s), &s->msix, &s->msix);
}
@ -601,7 +596,6 @@ static const VMStateDescription e1000e_vmstate = {
VMSTATE_MSIX(parent_obj, E1000EState),
VMSTATE_UINT32(ioaddr, E1000EState),
VMSTATE_UINT32(intr_state, E1000EState),
VMSTATE_UINT32(core.rxbuf_min_shift, E1000EState),
VMSTATE_UINT8(core.rx_desc_len, E1000EState),
VMSTATE_UINT32_ARRAY(core.rxbuf_sizes, E1000EState,

View File

@ -131,7 +131,9 @@ static void net_slirp_cleanup(NetClientState *nc)
SlirpState *s = DO_UPCAST(SlirpState, nc, nc);
slirp_cleanup(s->slirp);
qemu_remove_exit_notifier(&s->exit_notifier);
if (s->exit_notifier.notify) {
qemu_remove_exit_notifier(&s->exit_notifier);
}
slirp_smb_cleanup(s);
QTAILQ_REMOVE(&slirp_stacks, s, entry);
}