From nobody Mon Aug 08 14:04:13 2022 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4M1dH14KhFz4Y4Nh; Mon, 8 Aug 2022 14:04:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4M1dH12S4zz3tX3; Mon, 8 Aug 2022 14:04:13 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659967453; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=duF1bWXddnohM65nYDczqLsQiOBiWa098baJXjav2Uc=; b=hPwyEiPrfiYAPWqjkgIgjcjOZZe+//PzCHY+A2rSsEQF9O4nbKdemFlPgGLovwm4WOfUa0 BLZMl6NPy81Kof3kVVtuilUiYgluzolupcVz59d6y616fkTxMkvzcnh4eDXGCFX1EUhjKL Jd+vtHr+pPC4QeGM9cR8EeOZHx6P22zH+MZTWj3ga6aTl7uFezzgz8IoeKaAZ04p1KaPtL X1/0EmUM7ZKktglIAmoUnuVVa18HNWorHnwOHBJmj7KGlBfBGJYs6JwU27ql5XJZOkasML 7LfLBWfU4yluhxoSW8lDqYunMbektfuFGTZS4T6XdyHW+YbXtLEIhUFYosnUgg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4M1dH11Wjcztsb; Mon, 8 Aug 2022 14:04:13 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 278E4DmV088713; Mon, 8 Aug 2022 14:04:13 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 278E4Dj6088712; Mon, 8 Aug 2022 14:04:13 GMT (envelope-from git) Date: Mon, 8 Aug 2022 14:04:13 GMT Message-Id: <202208081404.278E4Dj6088712@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Emmanuel Vadot Subject: git: 6890e327a86d - main - linuxkpi: pci: Add more functions needed by drm List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: manu X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6890e327a86da0c268f2b21637bce4891626ada0 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1659967453; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=duF1bWXddnohM65nYDczqLsQiOBiWa098baJXjav2Uc=; b=FJb87l0lgGPG5S2gEL02txompEJLwqjkvBJpkUfzm4ISIuJIs19TB+QNGPri4qAv6moDdi HreKmz3ijZt8Q9Xyr6dt6Q5qVB2BGQ1wd8QhBiykcEAfxwTlhNLPpgxNs5AYlI4mNnDVmb 4SOtBiTc9pMqgZwuSgFZ/gZUTZlkXYzAG8JAPqwopJS1WzAjTJYKVGwpsTEmwkQOH+Q6gt x+EUY8eXd85gF7CXZyYjM7uSWe+jLAEyAtmSSB1wWW3Oda7+byZkzcGVXF+WS1AdQTc2lv t4k00dYgofPx6+ZoiQqFYATCVTknMOpEZJxX1DRJ16khWjZqOHAqoL/qXx3ZvA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1659967453; a=rsa-sha256; cv=none; b=GQBxrBvdcuXDtUWg99pfiDvb//kB4clxgizLKw8/TWr/xkeyq6Rn1FLW/bUmsY9wdSGAPt jPgWznG9nu8WYjzAxKW9RU7gY/GNU0V6uY/5QHdXP5/0+GM+5ECRSHIbiNtRm9lbvYTh7X RlWcvdrGhC8hWrmOIYxtPZLh2QSHCNCDvhTneSHHktQFxslqiYNH3u779jiNJlrm9c5IaM RkSOciunTOQoyO3KyUQJ2f3b9Vnteqa+yrFDfEq5LJm0dUXreYMM6E1kYOUa/Rlo51i0zP 1fvjnX1rm0R/XBnzSecwVAwJc0Qfuesw5WxwBbKzZPrxaTtCG70cQ52vNf7iJw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by manu: URL: https://cgit.FreeBSD.org/src/commit/?id=6890e327a86da0c268f2b21637bce4891626ada0 commit 6890e327a86da0c268f2b21637bce4891626ada0 Author: Emmanuel Vadot AuthorDate: 2022-07-26 08:07:39 +0000 Commit: Emmanuel Vadot 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_ */