Skip to content
  • Avi Kivity's avatar
    memory: fix rendering of a region obscured by another · d26a8cae
    Avi Kivity authored
    
    
    The memory core drops regions that are hidden by another region (for example,
    during BAR sizing), but it doesn't do so correctly if the lower address of the
    existing range is below the lower address of the new range.
    
    Example (qemu-system-mips -M malta -kernel vmlinux-2.6.32-5-4kc-malta
             -append "console=ttyS0"  -nographic -vga cirrus):
    
    Existing range: 10000000-107fffff
    New range:      100a0000-100bffff
    
    Correct behaviour: drop new range
    Incorrect behaviour: add new range
    
    Fix by taking this case into account (previously we only considered
    equal lower boundaries).
    
    Tested-by: default avatarAurelien Jarno <aurelien@aurel32.net>
    Signed-off-by: default avatarAvi Kivity <avi@redhat.com>
    Signed-off-by: default avatarAnthony Liguori <aliguori@us.ibm.com>
    d26a8cae