Sophie

Sophie

distrib > Scientific%20Linux > 5x > x86_64 > by-pkgid > 340e01248478ba8b78a6d4d1809b1eff > files > 328

kvm-83-270.el5_11.src.rpm

From 36c286457785e9068fa5bd118c9b4466e48abe1f Mon Sep 17 00:00:00 2001
From: Amit Shah <amit.shah@redhat.com>
Date: Wed, 13 May 2009 15:07:39 +0530
Subject: [PATCH 04/16] e1000: Do not reinit pci config space to 0

pci_register_device already mallocs the pci config space buffer filled
with zeroes.

Doing this again breaks some default config space writes like
setting the subsystem vendor id and subsystem device id.

Upstream commit ID 4a794a626d6442d66ba32dc4931ea0f336dd87fc

Bugzilla: 501729
Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-ID: <20090513093739.GA15304@amit-x200.pnq.redhat.com>
RH-Upstream-status: applied(kvm/master)
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Acked-by: Juan Quintela <quintela@redhat.com>
Acked-by: Dor Laor <dlaor@redhat.com>
Acked-by: john cooper <john.cooper@redhat.com>
Acked-by: Glauber Costa <glommer@redhat.com>
Acked-by: Eduardo Habkost <ehabkost@redhat.com>
---
 qemu/hw/e1000.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/qemu/hw/e1000.c b/qemu/hw/e1000.c
index f6f0135..97eb383 100644
--- a/qemu/hw/e1000.c
+++ b/qemu/hw/e1000.c
@@ -1061,7 +1061,6 @@ pci_e1000_init(PCIBus *bus, NICInfo *nd, int devfn)
 	return NULL;
 
     pci_conf = d->dev.config;
-    memset(pci_conf, 0, 256);
 
     *(uint16_t *)(pci_conf+0x00) = cpu_to_le16(0x8086);
     *(uint16_t *)(pci_conf+0x02) = cpu_to_le16(E1000_DEVID);
-- 
1.6.3.rc4.29.g8146