]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[pci] Enable memory cycles in adjust_pci_device()
authorMichael Brown <mcb30@etherboot.org>
Fri, 12 Dec 2008 19:15:00 +0000 (19:15 +0000)
committerMichael Brown <mcb30@etherboot.org>
Fri, 12 Dec 2008 19:15:00 +0000 (19:15 +0000)
adjust_pci_device() has historically enabled bus-mastering and I/O
cycles, but has never previously needed to enable memory cycles.  Some
EFI systems seem not to enable memory cycles by default, so add that
to the list of PCI command register bits that we force on.

src/drivers/bus/pci.c

index 54d1136fac7617a4be25688d299e7523e6784553..2dc9d43a844d0418e466672ee617e3f801b9e49a 100644 (file)
@@ -148,7 +148,8 @@ void adjust_pci_device ( struct pci_device *pci ) {
        unsigned char pci_latency;
 
        pci_read_config_word ( pci, PCI_COMMAND, &pci_command );
-       new_command = pci_command | PCI_COMMAND_MASTER | PCI_COMMAND_IO;
+       new_command = ( pci_command | PCI_COMMAND_MASTER |
+                       PCI_COMMAND_MEM | PCI_COMMAND_IO );
        if ( pci_command != new_command ) {
                DBG ( "PCI BIOS has not enabled device %02x:%02x.%x! "
                      "Updating PCI command %04x->%04x\n", pci->bus,