coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
mainboard.c
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 
3 #include <device/pci_def.h>
4 #include <device/pci_ids.h>
5 #include <device/pci_ops.h>
6 #include <device/device.h>
7 #include <baseboard/variants.h>
8 
10 {
11  struct device *dev;
12 
13  if (CONFIG(PCI_ALLOW_BUS_MASTER_ANY_DEVICE)) {
14  /* Set Master Enable for on-board PCI device if allowed. */
15  dev = dev_find_device(PCI_VID_SIEMENS, 0x403e, 0);
16  if (dev) {
18  }
19  }
20 }
struct device * dev_find_device(u16 vendor, u16 device, struct device *from)
Find a device of a given vendor and type.
Definition: device_util.c:42
@ CONFIG
Definition: dsi_common.h:201
static __always_inline void pci_or_config16(const struct device *dev, u16 reg, u16 ormask)
Definition: pci_ops.h:180
#define PCI_COMMAND_MASTER
Definition: pci_def.h:13
#define PCI_COMMAND
Definition: pci_def.h:10
#define PCI_VID_SIEMENS
Definition: pci_ids.h:1491
void __weak variant_mainboard_final(void)
Definition: mainboard.c:245
Definition: device.h:107