Lines Matching +full:ecam +full:- +full:based
1 // SPDX-License-Identifier: GPL-2.0-only
3 * Low-Level PCI Support for PC
5 * (c) 1999--2000 Martin Mares <mj@ucw.cz>
10 #include <linux/pci-acpi.h>
35 int pcibios_last_bus = -1;
44 return raw_pci_ops->read(domain, bus, devfn, reg, len, val); in raw_pci_read()
46 return raw_pci_ext_ops->read(domain, bus, devfn, reg, len, val); in raw_pci_read()
47 return -EINVAL; in raw_pci_read()
54 return raw_pci_ops->write(domain, bus, devfn, reg, len, val); in raw_pci_write()
56 return raw_pci_ext_ops->write(domain, bus, devfn, reg, len, val); in raw_pci_write()
57 return -EINVAL; in raw_pci_write()
62 return raw_pci_read(pci_domain_nr(bus), bus->number, in pci_read()
68 return raw_pci_write(pci_domain_nr(bus), bus->number, in pci_write()
78 * This interrupt-safe spinlock protects all accesses to PCI configuration
79 * space, except for the mmconfig (ECAM) based operations.
86 printk(KERN_INFO "PCI: %s detected, can skip ISA alignment\n", d->ident); in can_skip_ioresource_align()
129 struct resource *rom_r = &dev->resource[PCI_ROM_RESOURCE]; in pcibios_fixup_device_resources()
140 bar_r = &dev->resource[bar]; in pcibios_fixup_device_resources()
141 if (bar_r->start == 0 && bar_r->end != 0) { in pcibios_fixup_device_resources()
142 bar_r->flags = 0; in pcibios_fixup_device_resources()
143 bar_r->end = 0; in pcibios_fixup_device_resources()
149 if (rom_r->parent) in pcibios_fixup_device_resources()
151 if (rom_r->start) { in pcibios_fixup_device_resources()
155 rom_r->start = rom_r->end = rom_r->flags = 0; in pcibios_fixup_device_resources()
169 list_for_each_entry(dev, &b->devices, bus_list) in pcibios_fixup_bus()
192 printk(KERN_INFO "PCI: %s detected, enabling pci=bfsort.\n", d->ident); in set_bf_sort()
202 if (dm->type != 0xB1) in read_dmi_type_b1()
222 " (pci=assign-busses)\n", d->ident); in assign_all_busses()
230 d->ident); in set_scan_all()
238 * Laptops which need pci=assign-busses to see Cardbus cards
469 sd->node = x86_pci_root_bus_node(busnum); in pcibios_scan_root()
491 if (c->x86_clflush_size > 0) { in pcibios_set_cache_line_size()
492 pci_dfl_cache_line_size = c->x86_clflush_size >> 2; in pcibios_set_cache_line_size()
589 } else if (!strcmp(str, "assign-busses")) { in pcibios_setup()
621 if (noioapicreroute != -1) in pcibios_setup()
625 if (noioapicreroute != -1) in pcibios_setup()
639 if (is_vmd(pdev->bus)) in set_dev_domain_options()
640 pdev->hotplug_user_indicators = 1; in set_dev_domain_options()
654 return -ENOMEM; in pcibios_device_add()
656 if (data->type == SETUP_PCI) { in pcibios_device_add()
659 if ((pci_domain_nr(dev->bus) == rom->segment) && in pcibios_device_add()
660 (dev->bus->number == rom->bus) && in pcibios_device_add()
661 (PCI_SLOT(dev->devfn) == rom->device) && in pcibios_device_add()
662 (PCI_FUNC(dev->devfn) == rom->function) && in pcibios_device_add()
663 (dev->vendor == rom->vendor) && in pcibios_device_add()
664 (dev->device == rom->devid)) { in pcibios_device_add()
665 dev->rom = pa_data + in pcibios_device_add()
667 dev->romlen = rom->pcilen; in pcibios_device_add()
670 pa_data = data->next; in pcibios_device_add()
684 msidom = dev_get_msi_domain(&dev->bus->dev); in pcibios_device_add()
687 dev_set_msi_domain(&dev->dev, msidom); in pcibios_device_add()
712 if (atomic_dec_return(&dev->enable_cnt) >= 0) in pcibios_release_device()
729 if (is_vmd(dev->bus)) in pci_real_dma_dev()
730 return to_pci_sysdata(dev->bus)->vmd_dev; in pci_real_dma_dev()