WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-unstable] hvmloader: Scan for gpxe-capable NICs unt

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] hvmloader: Scan for gpxe-capable NICs until one is found.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 04 Jun 2009 10:25:26 -0700
Delivery-date: Thu, 04 Jun 2009 10:26:49 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1244041954 -3600
# Node ID 011948e1b5a7a01def6780093c46ebe99c4d25ba
# Parent  c4b048ce6a4b61111382ce37c6afaeed0234282e
hvmloader: Scan for gpxe-capable NICs until one is found.

Signed-off-by: Akio Takebe <takebe_akio@xxxxxxxxxxxxxx>
Signed-off-by: Keir Fraser <keir.fraser@xxxxxxxxxx>
---
 tools/firmware/hvmloader/hvmloader.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff -r c4b048ce6a4b -r 011948e1b5a7 tools/firmware/hvmloader/hvmloader.c
--- a/tools/firmware/hvmloader/hvmloader.c      Wed Jun 03 14:40:34 2009 +0100
+++ b/tools/firmware/hvmloader/hvmloader.c      Wed Jun 03 16:12:34 2009 +0100
@@ -451,8 +451,9 @@ static int scan_etherboot_nic(uint32_t c
 {
     uint8_t devfn;
     uint16_t class, vendor_id, device_id;
-
-    for ( devfn = 0; devfn < 128; devfn++ )
+    int rom_size = 0;
+
+    for ( devfn = 0; (devfn < 128) && !rom_size; devfn++ )
     {
         class     = pci_readw(devfn, PCI_CLASS_DEVICE);
         vendor_id = pci_readw(devfn, PCI_VENDOR_ID);
@@ -462,11 +463,11 @@ static int scan_etherboot_nic(uint32_t c
         if ( (vendor_id != 0xffff) &&
              (device_id != 0xffff) &&
              (class == 0x0200) )
-            return scan_option_rom(
+            rom_size = scan_option_rom(
                 devfn, vendor_id, device_id, etherboot, copy_rom_dest);
     }
 
-    return 0;
+    return rom_size;
 }
 
 /*

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] hvmloader: Scan for gpxe-capable NICs until one is found., Xen patchbot-unstable <=