VirtualBox

Changeset 67679 in vbox for trunk/src/VBox/Devices/PC/BIOS


Ignore:
Timestamp:
Jun 29, 2017 8:28:50 AM (8 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
116498
Message:

BIOS: Explicitly enable bus mastering for AHCI.

Location:
trunk/src/VBox/Devices/PC/BIOS
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/PC/BIOS/ahci.c

    r63562 r67679  
    10021002                        uint16_t    u16AhciIoBase = (u32Bar & 0xfff0) + u16Off;
    10031003
     1004                        /* Enable PCI memory, I/O, bus mastering access in command register. */
     1005                        pci_write_config_word(u8Bus, u8DevFn, 4, 0x7);
     1006
    10041007                        DBG_AHCI("I/O base: 0x%x\n", u16AhciIoBase);
    10051008                        rc = ahci_hba_init(u16AhciIoBase);
  • trunk/src/VBox/Devices/PC/BIOS/pciutil.c

    r62509 r67679  
    152152}
    153153
     154void pci_write_config_word(uint8_t bus, uint8_t dev_fn, uint8_t reg, uint16_t val)
     155{
     156    pci_write_cfgw((PCIBIOS_ID << 8) | PCIBIOS_WRITE_CONFIG_WORD, (bus << 8) | dev_fn, reg, val);
     157}
     158
    154159#if 0 /* Disabled to save space because they are not needed. Might become useful in the future. */
    155160/**
     
    174179}
    175180
    176 void pci_write_config_word(uint8_t bus, uint8_t dev_fn, uint8_t reg, uint16_t val)
    177 {
    178     pci_write_cfgw((PCIBIOS_ID << 8) | PCIBIOS_WRITE_CONFIG_WORD, (bus << 8) | dev_fn, reg, val);
    179 }
    180 
    181181void pci_write_config_dword(uint8_t bus, uint8_t dev_fn, uint8_t reg, uint32_t val)
    182182{
Note: See TracChangeset for help on using the changeset viewer.

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