diff --git a/arch/x86/soc/quark_x1000/soc.h b/arch/x86/soc/quark_x1000/soc.h index 0141c4222fa..39a417df743 100644 --- a/arch/x86/soc/quark_x1000/soc.h +++ b/arch/x86/soc/quark_x1000/soc.h @@ -107,10 +107,12 @@ extern "C" { static inline int pci_pin2irq(int bus, int dev, int pin) { - if (bus < 0 || bus > 1) + if (bus < 0 || bus > 1) { return -1; - if ((pin < PCI_INTA) || (pin > PCI_INTD)) + } + if ((pin < PCI_INTA) || (pin > PCI_INTD)) { return -1; + } return NUM_STD_IRQS + ((pin - 1 + bus) & 3); } diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index 5e06be6572d..6106b1e2eb7 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c @@ -398,8 +398,9 @@ int pci_bus_scan(struct pci_dev_info *dev_info) pci_ctrl_addr.field.bus = lookup.bus; pci_ctrl_addr.field.device = lookup.dev; - if (pci_dev_scan(pci_ctrl_addr, dev_info)) + if (pci_dev_scan(pci_ctrl_addr, dev_info)) { return 1; + } if (lookup.info.function != PCI_FUNCTION_ANY) { lookup.func = lookup.info.function;