Skip to content
  • Glauber Costa's avatar
    Make nic option rom loading less painful. · 406c8df3
    Glauber Costa authored
    
    
    The code how it is today, is totally painful to read and keep.
    To begin with, the code is duplicated with the option rom loading
    code that linux_boot and vga are already using.
    
    This patch introduces a "bootable" state in NICInfo structure,
    that we can use to keep track of whether or not a given nic should
    be bootable, avoiding the introduction of yet another global state.
    
    With that in hands, we move the code in vl.c to hw/pc.c, and use
    the already existing infra structure to load those option roms.
    
    Error checking code suggested by Mark McLoughlin
    
    Signed-off-by: default avatarGlauber Costa <glommer@redhat.com>
    Signed-off-by: default avatarAnthony Liguori <aliguori@us.ibm.com>
    406c8df3