public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Pacho Ramos" <pacho@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-misc/r8168/files/, net-misc/r8168/
Date: Mon, 19 Dec 2022 09:49:33 +0000 (UTC)	[thread overview]
Message-ID: <1671443353.ac9de419ed2d6f29b84de420c318879164c38a08.pacho@gentoo> (raw)

commit:     ac9de419ed2d6f29b84de420c318879164c38a08
Author:     Pacho Ramos <pacho <AT> gentoo <DOT> org>
AuthorDate: Mon Dec 19 09:49:13 2022 +0000
Commit:     Pacho Ramos <pacho <AT> gentoo <DOT> org>
CommitDate: Mon Dec 19 09:49:13 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ac9de419

net-misc/r8168: Fix support for kernel 6.1

Signed-off-by: Pacho Ramos <pacho <AT> gentoo.org>

 net-misc/r8168/files/r8168-8.051.02-6.1-fix.patch | 25 +++++++++++++++++++++++
 net-misc/r8168/r8168-8.051.02.ebuild              |  4 ++++
 2 files changed, 29 insertions(+)

diff --git a/net-misc/r8168/files/r8168-8.051.02-6.1-fix.patch b/net-misc/r8168/files/r8168-8.051.02-6.1-fix.patch
new file mode 100644
index 000000000000..9a9e3e539259
--- /dev/null
+++ b/net-misc/r8168/files/r8168-8.051.02-6.1-fix.patch
@@ -0,0 +1,25 @@
+From 39dd0fd2e5dc45cd63113f33a9890e36c304916d Mon Sep 17 00:00:00 2001
+From: zu1k <i@zu1k.com>
+Date: Sat, 29 Oct 2022 21:57:39 +0800
+Subject: [PATCH] Adapted for Linux 6.1
+
+---
+ src/r8168.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/r8168.h b/src/r8168.h
+index 662974a..baf48c6 100755
+--- a/src/r8168.h
++++ b/src/r8168.h
+@@ -561,7 +561,11 @@ typedef int *napi_budget;
+ typedef struct napi_struct *napi_ptr;
+ typedef int napi_budget;
+ 
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)
++#define RTL_NAPI_CONFIG(ndev, priv, function, weight)   netif_napi_add(ndev, &priv->napi, function)
++#else
+ #define RTL_NAPI_CONFIG(ndev, priv, function, weight)   netif_napi_add(ndev, &priv->napi, function, weight)
++#endif
+ #define RTL_NAPI_QUOTA(budget, ndev)            min(budget, budget)
+ #define RTL_GET_PRIV(stuct_ptr, priv_struct)        container_of(stuct_ptr, priv_struct, stuct_ptr)
+ #define RTL_GET_NETDEV(priv_ptr)            struct net_device *dev = priv_ptr->dev;

diff --git a/net-misc/r8168/r8168-8.051.02.ebuild b/net-misc/r8168/r8168-8.051.02.ebuild
index 4258fbb99cdb..853cd629f555 100644
--- a/net-misc/r8168/r8168-8.051.02.ebuild
+++ b/net-misc/r8168/r8168-8.051.02.ebuild
@@ -24,6 +24,10 @@ IUSE="use-firmware"
 CONFIG_CHECK="~!R8169"
 WARNING_R8169="CONFIG_R8169 is enabled. ${P} will not be loaded unless kernel driver Realtek 8169 PCI Gigabit Ethernet (CONFIG_R8169) is DISABLED."
 
+PATCHES=(
+	"${FILESDIR}/${PN}-8.051.02-6.1-fix.patch"
+)
+
 pkg_setup() {
 	linux-mod_pkg_setup
 	BUILD_PARAMS="KERNELDIR=${KV_DIR}"


             reply	other threads:[~2022-12-19  9:49 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-19  9:49 Pacho Ramos [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-06-16  9:38 [gentoo-commits] repo/gentoo:master commit in: net-misc/r8168/files/, net-misc/r8168/ Pacho Ramos
2023-08-19 22:32 Conrad Kostecki
2023-02-26 15:51 Pacho Ramos
2022-12-04 14:50 Pacho Ramos
2022-08-02 17:36 Pacho Ramos
2022-05-26  9:44 Pacho Ramos
2022-03-27  9:30 Pacho Ramos
2020-04-03 18:50 Pacho Ramos
2018-04-27 21:09 James Le Cuirot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1671443353.ac9de419ed2d6f29b84de420c318879164c38a08.pacho@gentoo \
    --to=pacho@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox