r8168-8.038.00 doesn't build on kernel 3.16.x (PREPARE_DELAYED_WORK, SET_ETHTOOL_OPS)

Bug #1345548 reported by Henning Pingel
74
This bug affects 14 people
Affects Status Importance Assigned to Milestone
r8168-dkms (Ubuntu)
Confirmed
Medium
Unassigned
Utopic
Won't Fix
Medium
Unassigned

Bug Description

dkms package builds fine with kernel 3.13 but not with kernel 3.16 any more.

Tested with
a) Ubuntu 14.10 Alpha and
b) Ubuntu 14.04 with PPA package linux-meta-lts-utopic

Other Linux users also report this issue with newer kernels (as of 3.15 I guess):
https://code.google.com/p/r8168/issues/detail?id=19

Please check attached make.log for details.

I was able to resolve the issues with a quick-n-dirty patch that I have also pasted into this bug report. This patch might not be the best solution and may not be downward compatible to kernel 3.13.

--- r8168-8.038.00.orig/src/r8168_n.c
+++ r8168-8.038.00/src/r8168_n.c
@@ -17542,7 +17542,8 @@ rtl8168_init_one(struct pci_dev *pdev,

     RTL_NET_DEVICE_OPS(rtl8168_netdev_ops);

- SET_ETHTOOL_OPS(dev, &rtl8168_ethtool_ops);
+ //SET_ETHTOOL_OPS(dev, &rtl8168_ethtool_ops);
+ dev->ethtool_ops = &rtl8168_ethtool_ops;

     dev->watchdog_timeo = RTL8168_TX_TIMEOUT;
     dev->irq = pdev->irq;
@@ -19119,7 +19120,7 @@ static void rtl8168_schedule_work(struct
 {
     struct rtl8168_private *tp = netdev_priv(dev);

- PREPARE_DELAYED_WORK(&tp->task, task);
+ INIT_DELAYED_WORK(&tp->task, task);
     schedule_delayed_work(&tp->task, 4);
 }
 #endif

Cheers,
Henning

Revision history for this message
Henning Pingel (henningpingel) wrote :
Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

The attachment "dkms make log with two error messages" seems to be a patch. If it isn't, please remove the "patch" flag from the attachment, remove the "patch" tag, and if you are a member of the ~ubuntu-reviewers, unsubscribe the team.

[This is an automated message performed by a Launchpad user owned by ~brian-murray, for any issues please contact him.]

tags: added: patch
Revision history for this message
Henning Pingel (henningpingel) wrote :

Experimental patch to make build work again (works for me, but may be not the best solution and may break build on older kernels)

Revision history for this message
jose (o1485726) wrote :

Attached is my suggestion, just a slight modification.

Revision history for this message
jose (o1485726) wrote :

I made a small mistake: where it says "3,14", it should say "3,15".

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in r8168-dkms (Ubuntu):
status: New → Confirmed
Revision history for this message
jose (o1485726) wrote :

seems to have been fixed in r8168-8.039.00

Revision history for this message
Henning Pingel (henningpingel) wrote :

Debian Sid offers the package in new version 8.039.00-1:
https://packages.debian.org/sid/r8168-dkms

tags: added: kernel-da-key
Revision history for this message
Jan Schnackenberg (yehaa) wrote :

So, since the r8168-dkms package that is shipped with 14.10 does not work with the kernel shipped with 14.10, is there any chance, that this package will be updated to a working version?

Since the r8169 module continuously crashes when handling heavy load (and I've experienced this behaviour with many different systems) the r8168-dkms is really not a "nice to have" package.

Revision history for this message
Dan Lee (danlee) wrote :

going back to 14.04 14.10 is causing too many issues for me with this problem outstanding,

Revision history for this message
jose (o1485726) wrote :

I suggest you guys download and install the .deb package for ubuntu 15.04 directly from here:
https://launchpad.net/ubuntu/+source/r8168
I doubt anyone will update this package, since these are "different" versions... and the one I'm suggesting should be compatible anyway (I installed it, works just fine).

Changed in r8168-dkms (Ubuntu):
importance: Undecided → Medium
Changed in r8168-dkms (Ubuntu Utopic):
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Thanks for the patch in comment #4, Jose! I modified the patch to say "3,15" instead of "3,14" and attached it as:
delayed_work_ethtool_ops_fix3.patch

Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Also, I built a test package using version r8168-8.038.00 with the patch. The .deb package is attached and named:
r8168-dkms_8.038.00-1_all-PATCHED.deb

Can folks affected by this bug test that package and see if it installs/builds correctly. It would also be great to test the functionality of the package, to confirm there are no regressions.

Revision history for this message
Gabriele Tozzi (gabriele-tozzi) wrote :

Same problem here. I have solved by downloading and installing the Debian sid package r8168-dkms_8.039.00-1_all.deb.

Revision history for this message
Iiro Laiho (iiro) wrote :

This bug is over a year old and the patch has also been released ages ago. Is there any change that the version in the repository would be fixed?

Revision history for this message
Rolf Leggewie (r0lf) wrote :

utopic has seen the end of its life and is no longer receiving any updates. Marking the utopic task for this ticket as "Won't Fix".

Changed in r8168-dkms (Ubuntu Utopic):
status: Confirmed → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.