summaryrefslogtreecommitdiff
path: root/net-misc/r8125
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-06-29 12:04:12 +0100
committerV3n3RiX <venerix@koprulu.sector>2022-06-29 12:04:12 +0100
commit0f558761aa2dee1017b4751e4017205e015a9560 (patch)
tree037df795519468a25d9362b4e95cdaeb84eb1cf9 /net-misc/r8125
parent752d6256e5204b958b0ef7905675a940b5e9172f (diff)
gentoo resync : 29.12.2022
Diffstat (limited to 'net-misc/r8125')
-rw-r--r--net-misc/r8125/Manifest5
-rw-r--r--net-misc/r8125/files/r8125-9.008.00-linux-5.18.patch31
-rw-r--r--net-misc/r8125/r8125-9.008.00.ebuild1
-rw-r--r--net-misc/r8125/r8125-9.009.01.ebuild40
4 files changed, 76 insertions, 1 deletions
diff --git a/net-misc/r8125/Manifest b/net-misc/r8125/Manifest
index 95944c164d5b..fc75ee2c9cbb 100644
--- a/net-misc/r8125/Manifest
+++ b/net-misc/r8125/Manifest
@@ -1,4 +1,7 @@
AUX r8125-9.008.00-linux-5.17.patch 4449 BLAKE2B d00d43f1efae664d02a5c8e7fb6716114bd6cc1b78a5b94f99ea72400f9e9c776eaed60c5dc0593b32857e73aa27883e971b570e7b561cad4b85db1d706194b1 SHA512 a3459c78d55561ae703977e147965b04aa854eff1035c273a703936e6f069d5d501c91cf1db746d0ef93dbfe61c3d28b5d35be34a4982fcbe9f0c42d9204b1bf
+AUX r8125-9.008.00-linux-5.18.patch 1247 BLAKE2B 47f7aa546b6df11b8e1a95ff4be4c6964120421026da8977d67da0050395e5f1cff64f5cdbba28da5f502eff95e3db728b1acc834b82a8d186843b7fd0a14964 SHA512 577c0c5b69f6b41b4474404abd99bb946939373612eb23e320a9c014011f643d173c1597ba6f60a8a350f4c095eeddd99ce837fe5da884320229b047616309df
DIST r8125-9.008.00.tar.bz2 89622 BLAKE2B d1106086d1bca53484f8536072cddd506087b5d49983cbb91e921e86674c074b38c8a01cb51d2ea5793d8ffbff6e97ab05e48720ff00a805c4096a1d62a0cc30 SHA512 ff740a49fcc94b3de826f6299c489ed3f92ba9123ca2b2fe3c9035eecd16d518b6a4e6c2fa2531bb670c52097a52a0fb2fdf71b721efb20c83bb59d94d99c6c6
-EBUILD r8125-9.008.00.ebuild 1339 BLAKE2B f2c89508a6f3342eb2a55dca67a43e08da455a9d816ca70ea61dfe557c60676ed74423d5da8b1ab2e417da4ccefe42467d6a807f21a06b296e5f16177b68be9d SHA512 2933786074e2524225d3ecbb641e48b51bf593cbeef76ef18c26e6a74be004b67a8de77f81abbe0016d151239716e697c9783a709eca901b1d7e377491e38527
+DIST r8125-9.009.01.tar.bz2 89897 BLAKE2B 65f64f504cedc7244bdae10fd1638e031eb103f562cd71d32b5f36b15541704086df8cea16829b289e8be61bacf3de559616884d1672a4d6b8e47211816de8d3 SHA512 8b717447e2048df0d88d8350da2edb58f704e893498fbebea4aa2a3ac45ea050d70e73e78d41ab94562228b9c01e6fe59810c501c5bb880db446c05b9b6aee0d
+EBUILD r8125-9.008.00.ebuild 1399 BLAKE2B 59bb8848b09ee1ca476abbfbb156ded1e7cb3961aa287359aff792be2bd0b96b19d74a923ff545c3f6a53427c8536f190ee50d7ba837d5665e1d1e182f677b5c SHA512 45950f83abd6ac72475b58969c3c665eb7aa9fa31e7c6b4ec7aa356e06c58a5c5acc6287c23663a1b24902c8257907c6bb7c333df5370f4fbbc37d36d7a112ac
+EBUILD r8125-9.009.01.ebuild 1185 BLAKE2B b50ff489d98dd5fdf4fa8439c2414a47c71dab9782e3cc0eb052ef833bce84b34ed73dfae16abaaf24fbcaa6b4e9e6e3d4a60653092874c64169e861b80ceae4 SHA512 856ce45440f4e1d47c910588d5f88f85506dcffb01295e868c7033b85289f00fa6d9b2e7727f6c74cf33a7854640da06d4492c8b77cf141c9fb5da4c665b8b9a
MISC metadata.xml 840 BLAKE2B 6fa88a6b1b49f0abd18ca64abf2ab93a04e89d51c66ebb602ca5070c56723fbe79e4a0fcfa49b4cc90e3ec904730c8e39b1a2159fcae0f036035d5696537a5a4 SHA512 f15e195ac564002f169610c0490f1f377716260e758241d5228a3b6c7d481de135c03a4da1e5c2eb121e4539a2abceabc3a4e1d26d8d987e093b981dd6eaea9f
diff --git a/net-misc/r8125/files/r8125-9.008.00-linux-5.18.patch b/net-misc/r8125/files/r8125-9.008.00-linux-5.18.patch
new file mode 100644
index 000000000000..6da1bdae6b6a
--- /dev/null
+++ b/net-misc/r8125/files/r8125-9.008.00-linux-5.18.patch
@@ -0,0 +1,31 @@
+Added compatibility with Linux Kernel 5.18+.
+
+Author: Karlson2k (Evgeny Grin)
+Gentoo bug: https://bugs.gentoo.org/852311
+
+diff --git a/src/r8125_n.c b/src/r8125_n.c
+
+--- a/src/r8125_n.c
++++ b/src/r8125_n.c
+@@ -11852,11 +11852,20 @@ rtl8125_init_board(struct pci_dev *pdev,
+
+ if ((sizeof(dma_addr_t) > 4) &&
+ use_dac &&
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5,18,0)
+ !pci_set_dma_mask(pdev, DMA_BIT_MASK(64)) &&
+ !pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(64))) {
++#else // LINUX_VERSION_CODE >= KERNEL_VERSION(5,18,0)
++ !dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)) &&
++ !dma_set_coherent_mask(&pdev->dev, DMA_BIT_MASK(64))) {
++#endif // LINUX_VERSION_CODE >= KERNEL_VERSION(5,18,0)
+ dev->features |= NETIF_F_HIGHDMA;
+ } else {
++#if LINUX_VERSION_CODE < KERNEL_VERSION(5,18,0)
+ rc = pci_set_dma_mask(pdev, DMA_BIT_MASK(32));
++#else // LINUX_VERSION_CODE >= KERNEL_VERSION(5,18,0)
++ rc = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));
++#endif // LINUX_VERSION_CODE >= KERNEL_VERSION(5,18,0)
+ if (rc < 0) {
+ #if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,0)
+ if (netif_msg_probe(tp))
+
diff --git a/net-misc/r8125/r8125-9.008.00.ebuild b/net-misc/r8125/r8125-9.008.00.ebuild
index 7b0093e09b81..b848421ede7e 100644
--- a/net-misc/r8125/r8125-9.008.00.ebuild
+++ b/net-misc/r8125/r8125-9.008.00.ebuild
@@ -22,6 +22,7 @@ IUSE="+multi-tx-q ptp +rss use-firmware"
PATCHES=(
"${FILESDIR}/${PN}-9.008.00-linux-5.17.patch" # bug 839282
+ "${FILESDIR}/${PN}-9.008.00-linux-5.18.patch" # bug 852311
)
CONFIG_CHECK="~!R8169"
diff --git a/net-misc/r8125/r8125-9.009.01.ebuild b/net-misc/r8125/r8125-9.009.01.ebuild
new file mode 100644
index 000000000000..2a1b7c235358
--- /dev/null
+++ b/net-misc/r8125/r8125-9.009.01.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit linux-info linux-mod
+
+DESCRIPTION="r8125 vendor driver for Realtek RTL8125 PCI-E NICs"
+HOMEPAGE="https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100-1000m-gigabit-ethernet-pci-express-software"
+
+SRC_URI="http://rtitwww.realtek.com/rtdrivers/cn/nic1/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+MODULE_NAMES="r8125(net:${S}/src)"
+BUILD_TARGETS="modules"
+IUSE="+multi-tx-q ptp +rss use-firmware"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-9.008.00-linux-5.18.patch" # bug 852311
+)
+
+CONFIG_CHECK="~!R8169"
+WARNING_R8169="CONFIG_R8169 is enabled. ${PN} will not be loaded unless kernel driver Realtek 8169 PCI Gigabit Ethernet (CONFIG_R8169) is DISABLED."
+
+pkg_setup() {
+ linux-mod_pkg_setup
+ BUILD_PARAMS="KERNELDIR=${KV_DIR}"
+ BUILD_PARAMS+=" ENABLE_PTP_SUPPORT=$(usex ptp y n)"
+ BUILD_PARAMS+=" ENABLE_RSS_SUPPORT=$(usex rss y n)"
+ BUILD_PARAMS+=" ENABLE_MULTIPLE_TX_QUEUE=$(usex multi-tx-q y n)"
+ BUILD_PARAMS+=" ENABLE_USE_FIRMWARE_FILE=$(usex use-firmware y n)"
+}
+
+src_install() {
+ linux-mod_src_install
+ einstalldocs
+}