blob: 4fe60dd91a511fba263a6d12cbe63d7b87c74467 [file] [log] [blame]
Duncan Laurie0f5a17e2020-10-27 10:26:18 -07001/* SPDX-License-Identifier: GPL-2.0-only */
2
3#include <device/device.h>
4#include <device/pci.h>
5#include <device/pci_ids.h>
6#include <intelblocks/acpi.h>
7#include <soc/pci_devs.h>
8
9static const char *usb4_xhci_acpi_name(const struct device *dev)
10{
11 if (dev->path.type != DEVICE_PATH_PCI)
12 return NULL;
13
14 return "TXHC";
15}
16
17static struct device_operations usb4_xhci_ops = {
18 .read_resources = pci_dev_read_resources,
19 .set_resources = pci_dev_set_resources,
20 .enable_resources = pci_dev_enable_resources,
21 .ops_pci = &pci_dev_ops_pci,
22 .scan_bus = scan_static_bus,
23#if CONFIG(HAVE_ACPI_TABLES)
24 .acpi_name = usb4_xhci_acpi_name,
25#endif
26};
27
28static const unsigned short pci_device_ids[] = {
29 PCI_DEVICE_ID_INTEL_TGP_TCSS_XHCI,
30 0
31};
32
33static const struct pci_driver usb4_xhci __pci_driver = {
34 .ops = &usb4_xhci_ops,
35 .vendor = PCI_VENDOR_ID_INTEL,
36 .devices = pci_device_ids,
37};