pci: cosmetic on pci_upadte_mappings()
Remove one indentation of pci_update_mappings. Just for cosmetics, no logic change. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
fb23162885
commit
a968857067
14
hw/pci.c
14
hw/pci.c
|
@ -637,7 +637,11 @@ static void pci_update_mappings(PCIDevice *d)
|
|||
cmd = pci_get_word(d->config + PCI_COMMAND);
|
||||
for(i = 0; i < PCI_NUM_REGIONS; i++) {
|
||||
r = &d->io_regions[i];
|
||||
if (r->size != 0) {
|
||||
|
||||
/* this region isn't registered */
|
||||
if (r->size == 0)
|
||||
continue;
|
||||
|
||||
if (r->type & PCI_BASE_ADDRESS_SPACE_IO) {
|
||||
if (cmd & PCI_COMMAND_IO) {
|
||||
new_addr = pci_get_long(d->config + pci_bar(d, i));
|
||||
|
@ -691,8 +695,12 @@ static void pci_update_mappings(PCIDevice *d)
|
|||
new_addr = PCI_BAR_UNMAPPED;
|
||||
}
|
||||
}
|
||||
|
||||
/* This bar isn't changed */
|
||||
if (new_addr == r->addr)
|
||||
continue;
|
||||
|
||||
/* now do the real mapping */
|
||||
if (new_addr != r->addr) {
|
||||
if (r->addr != PCI_BAR_UNMAPPED) {
|
||||
if (r->type & PCI_BASE_ADDRESS_SPACE_IO) {
|
||||
int class;
|
||||
|
@ -717,8 +725,6 @@ static void pci_update_mappings(PCIDevice *d)
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
uint32_t pci_default_read_config(PCIDevice *d,
|
||||
uint32_t address, int len)
|
||||
|
|
Loading…
Reference in New Issue