Tom Rini | 83d290c | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0+ |
Simon Glass | a219dae | 2015-03-05 12:25:31 -0700 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (c) 2015 Google, Inc |
Simon Glass | a219dae | 2015-03-05 12:25:31 -0700 | [diff] [blame] | 4 | */ |
| 5 | |
| 6 | #include <common.h> |
| 7 | #include <dm.h> |
| 8 | #include <pci.h> |
Simon Glass | 945cae7 | 2015-07-03 18:28:25 -0600 | [diff] [blame] | 9 | #include <asm/pci.h> |
Simon Glass | a219dae | 2015-03-05 12:25:31 -0700 | [diff] [blame] | 10 | |
Simon Glass | 945cae7 | 2015-07-03 18:28:25 -0600 | [diff] [blame] | 11 | static const struct dm_pci_ops pci_x86_ops = { |
| 12 | .read_config = pci_x86_read_config, |
| 13 | .write_config = pci_x86_write_config, |
Simon Glass | a219dae | 2015-03-05 12:25:31 -0700 | [diff] [blame] | 14 | }; |
| 15 | |
Simon Glass | 945cae7 | 2015-07-03 18:28:25 -0600 | [diff] [blame] | 16 | static const struct udevice_id pci_x86_ids[] = { |
| 17 | { .compatible = "pci-x86" }, |
Simon Glass | a219dae | 2015-03-05 12:25:31 -0700 | [diff] [blame] | 18 | { } |
| 19 | }; |
| 20 | |
| 21 | U_BOOT_DRIVER(pci_x86) = { |
| 22 | .name = "pci_x86", |
| 23 | .id = UCLASS_PCI, |
Simon Glass | 945cae7 | 2015-07-03 18:28:25 -0600 | [diff] [blame] | 24 | .of_match = pci_x86_ids, |
| 25 | .ops = &pci_x86_ops, |
Simon Glass | a219dae | 2015-03-05 12:25:31 -0700 | [diff] [blame] | 26 | }; |