From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Myn4Y-0001uY-6E for qemu-devel@nongnu.org; Fri, 16 Oct 2009 09:42:22 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Myn4S-0001rq-1B for qemu-devel@nongnu.org; Fri, 16 Oct 2009 09:42:19 -0400 Received: from [199.232.76.173] (port=40526 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Myn4Q-0001rX-Uy for qemu-devel@nongnu.org; Fri, 16 Oct 2009 09:42:15 -0400 Received: from mx1.redhat.com ([209.132.183.28]:23478) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Myn4Q-0007o1-Fu for qemu-devel@nongnu.org; Fri, 16 Oct 2009 09:42:14 -0400 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n9GDgDd4021377 for ; Fri, 16 Oct 2009 09:42:13 -0400 From: Gerd Hoffmann Date: Fri, 16 Oct 2009 15:42:03 +0200 Message-Id: <1255700523-15270-11-git-send-email-kraxel@redhat.com> In-Reply-To: <1255700523-15270-1-git-send-email-kraxel@redhat.com> References: <1255700523-15270-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [RfC PATCH v3 10/10] ne2k_pci: load rom. List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gerd Hoffmann Signed-off-by: Gerd Hoffmann --- hw/ne2000.c | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/hw/ne2000.c b/hw/ne2000.c index f296b10..6cb5f58 100644 --- a/hw/ne2000.c +++ b/hw/ne2000.c @@ -25,6 +25,7 @@ #include "pci.h" #include "net.h" #include "ne2000.h" +#include "loader.h" /* debug NE2000 card */ //#define DEBUG_NE2000 @@ -767,6 +768,14 @@ static int pci_ne2000_init(PCIDevice *pci_dev) ne2000_cleanup, s); qemu_format_nic_info_str(s->vc, s->c.macaddr.a); + if (!pci_dev->qdev.hotplugged) { + static int loaded = 0; + if (!loaded) { + rom_add_option("pxe-ne2k_pci.bin"); + loaded = 1; + } + } + register_savevm("ne2000", -1, 3, pci_ne2000_save, pci_ne2000_load, d); return 0; } -- 1.6.2.5