Date: Mon, 8 Aug 2022 14:04:13 GMT From: Emmanuel Vadot <manu@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 6890e327a86d - main - linuxkpi: pci: Add more functions needed by drm Message-ID: <202208081404.278E4Dj6088712@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by manu: URL: https://cgit.FreeBSD.org/src/commit/?id=6890e327a86da0c268f2b21637bce4891626ada0 commit 6890e327a86da0c268f2b21637bce4891626ada0 Author: Emmanuel Vadot <manu@FreeBSD.org> AuthorDate: 2022-07-26 08:07:39 +0000 Commit: Emmanuel Vadot <manu@FreeBSD.org> CommitDate: 2022-08-08 13:22:34 +0000 linuxkpi: pci: Add more functions needed by drm Mostly stubs to satisfy building Reviewed by: hselasky Obtained from: drm-kmod Sponsored by: Beckhoff Automation GmbH & Co. KG Differential Revision: https://reviews.freebsd.org/D35938 --- sys/compat/linuxkpi/common/include/linux/pci.h | 30 ++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index 695965673050..0652a250c697 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -1514,4 +1514,34 @@ linuxkpi_pcim_want_to_use_bus_functions(struct pci_dev *pdev) pdev->want_iomap_res = true; } +static inline bool +pci_is_thunderbolt_attached(struct pci_dev *pdev) +{ + + return (false); +} + +static inline void * +pci_platform_rom(struct pci_dev *pdev, size_t *size) +{ + + return (NULL); +} + +static inline void +pci_ignore_hotplug(struct pci_dev *pdev) +{ +} + +static inline int +pcie_get_readrq(struct pci_dev *dev) +{ + u16 ctl; + + if (pcie_capability_read_word(dev, PCI_EXP_DEVCTL, &ctl)) + return (-EINVAL); + + return (128 << ((ctl & PCI_EXP_DEVCTL_READRQ) >> 12)); +} + #endif /* _LINUXKPI_LINUX_PCI_H_ */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202208081404.278E4Dj6088712>