VirtualBox

Ignore:
Timestamp:
Mar 9, 2011 10:19:19 PM (14 years ago)
Author:
vboxsync
Message:

PCI: further interrupts work, tweaks

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VBoxShell/vboxshell.py

    r36107 r36246  
    30983098
    30993099def pciAddr(ctx,addr):
    3100     str = "%d:%d.%d" %(addr >> 8, (addr & 0xff) >> 3, addr & 7)
     3100    str = "%02x:%02x.%d" %(addr >> 8, (addr & 0xff) >> 3, addr & 7)
    31013101    return colPci(ctx, str)
    31023102
     
    31163116
    31173117def parsePci(str):
    3118     pcire = re.compile(r'(?P<b>\d+):(?P<d>\d+)\.(?P<f>\d)')
     3118    pcire = re.compile(r'(?P<b>[0-9a-fA-F]+):(?P<d>[0-9a-fA-F]+)\.(?P<f>\d)')
    31193119    m = pcire.search(str)
    31203120    if m is None:
    31213121        return -1
    31223122    dict = m.groupdict()
    3123     return ((int(dict['b'])) << 8) | ((int(dict['d'])) << 3) | int(dict['f'])
     3123    return ((int(dict['b'], 16)) << 8) | ((int(dict['d'], 16)) << 3) | int(dict['f'])
    31243124
    31253125def lspciCmd(ctx, args):
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette