Lines Matching +full:cfg +full:- +full:space
1 // SPDX-License-Identifier: GPL-2.0
15 #include <linux/pci-ecam.h>
29 struct pci_config_window *cfg;
31 err = of_address_to_resource(dev->of_node, 0, &cfgres);
37 bus = resource_list_first_type(&bridge->windows, IORESOURCE_BUS);
39 return ERR_PTR(-ENODEV);
41 cfg = pci_ecam_create(dev, &cfgres, bus->res, ops);
42 if (IS_ERR(cfg))
43 return cfg;
45 err = devm_add_action_or_reset(dev, gen_pci_unmap_cfg, cfg);
49 return cfg;
54 struct device *dev = &pdev->dev;
56 struct pci_config_window *cfg;
59 ops = of_device_get_match_data(&pdev->dev);
61 return -ENODEV;
65 return -ENOMEM;
71 /* Parse and map our Configuration Space windows */
72 cfg = gen_pci_init(dev, bridge, ops);
73 if (IS_ERR(cfg))
74 return PTR_ERR(cfg);
76 bridge->sysdata = cfg;
77 bridge->ops = (struct pci_ops *)&ops->pci_ops;
78 bridge->msi_domain = true;
89 pci_stop_root_bus(bridge->bus);
90 pci_remove_root_bus(bridge->bus);