]> Git Repo - qemu.git/commitdiff
pci: clean up pci_init_wmask()
authorIsaku Yamahata <[email protected]>
Fri, 30 Oct 2009 12:21:02 +0000 (21:21 +0900)
committerAnthony Liguori <[email protected]>
Mon, 9 Nov 2009 14:43:05 +0000 (08:43 -0600)
use pci_set_word() for pci command register.

Signed-off-by: Isaku Yamahata <[email protected]>
Signed-off-by: Anthony Liguori <[email protected]>
hw/pci.c

index 6abb0e2b3f5cbbdf446c4ccc7216a879b6f6db3b..84c761100731771887229062e7377741a5725c5f 100644 (file)
--- a/hw/pci.c
+++ b/hw/pci.c
@@ -352,8 +352,8 @@ static void pci_init_wmask(PCIDevice *dev)
     int i;
     dev->wmask[PCI_CACHE_LINE_SIZE] = 0xff;
     dev->wmask[PCI_INTERRUPT_LINE] = 0xff;
-    dev->wmask[PCI_COMMAND] = PCI_COMMAND_IO | PCI_COMMAND_MEMORY
-                              | PCI_COMMAND_MASTER;
+    pci_set_word(dev->wmask + PCI_COMMAND,
+                 PCI_COMMAND_IO | PCI_COMMAND_MEMORY | PCI_COMMAND_MASTER);
     for (i = PCI_CONFIG_HEADER_SIZE; i < PCI_CONFIG_SPACE_SIZE; ++i)
         dev->wmask[i] = 0xff;
 }
This page took 0.031684 seconds and 4 git commands to generate.