TP-LINK TG-3468 network card not recognized correctly

Bug #1788730 reported by dienteperro
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Medium
Anthony Wong

Bug Description

A few days ago purchased a couple of TP-LINK TG-3468 network cards (reviewed by Phoronix here: https://www.phoronix.com/scan.php?page=news_item&px=MTY2ODQ), both brand new, not reused. After installed them to a pc, to my surprise, one of them was correctly identified and the other was incorrectly identified as "NCube Device 8168 (rev 06)".

After DuckDuckGoing for a while I found this kernel bud report for FreeBSD: https://forums.freebsd.org/threads/not-recognized-pci-e-network-card.57734/

IMHO is the same issue but I'm using Ubuntu 16.04.5 server i686. I wanted to report this so it can be fixed, please let me know wich logs/data should I provide.

When ran lspci -nv this is shown for the correct nic:
03:00.0 0200: 10ec:8168 (rev 06)
 Subsystem: 7470:3468
 Flags: bus master, fast devsel, latency 0, IRQ 27
 I/O ports at e800 [size=256]
 Memory at febff000 (64-bit, non-prefetchable) [size=4K]
 Memory at fdffc000 (64-bit, prefetchable) [size=16K]
 Capabilities: <access denied>
 Kernel driver in use: r8169
 Kernel modules: r8169

And this for the incorrect one:
01:00.0 0200: 10ff:8168 (rev 06)
 Subsystem: 7470:3468
 Flags: bus master, fast devsel, latency 0, IRQ 11
 I/O ports at c800 [size=256]
 Memory at fe9ff000 (64-bit, non-prefetchable) [size=4K]
 Memory at fdefc000 (64-bit, prefetchable) [size=16K]
 Capabilities: <access denied>

1) lsb_release -rd
Description: Ubuntu 16.04.5 LTS
Release: 16.04

2) In regard to the package I think this is related to the kernel itself?
3) Both cards should be identified as "Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller (rev 06)" and the r8169 driver should be used.
4) The network card was erroneously detected as a different one and the driver was not loaded by the kernel.

Best regards.
---
AlsaVersion: Advanced Linux Sound Architecture Driver Version k4.4.0-133-generic.
AplayDevices: Error: [Errno 2] No such file or directory
ApportVersion: 2.20.1-0ubuntu2.18
Architecture: i386
ArecordDevices: Error: [Errno 2] No such file or directory
AudioDevicesInUse: Error: command ['fuser', '-v', '/dev/snd/by-path', '/dev/snd/hwC0D0', '/dev/snd/pcmC0D1p', '/dev/snd/pcmC0D0c', '/dev/snd/pcmC0D0p', '/dev/snd/controlC0', '/dev/snd/seq', '/dev/snd/timer'] failed with exit code 1:
Card0.Amixer.info: Error: [Errno 2] No such file or directory
Card0.Amixer.values: Error: [Errno 2] No such file or directory
DistroRelease: Ubuntu 16.04
HibernationDevice: RESUME=UUID=652853e2-bd7e-44bb-9b13-f2c9c3823791
InstallationDate: Installed on 2017-12-06 (260 days ago)
InstallationMedia: Ubuntu-Server 16.04 LTS "Xenial Xerus" - Release i386 (20160420.3)
IwConfig: Error: [Errno 2] No such file or directory
MachineType: System manufacturer System Product Name
Package: linux (not installed)
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.4.0-133-generic root=UUID=89ec3fdb-2ccd-497a-8657-bbe2b53393ed ro
ProcVersionSignature: Ubuntu 4.4.0-133.159-generic 4.4.134
RelatedPackageVersions:
 linux-restricted-modules-4.4.0-133-generic N/A
 linux-backports-modules-4.4.0-133-generic N/A
 linux-firmware 1.157.20
RfKill: Error: [Errno 2] No such file or directory
Tags: xenial
Uname: Linux 4.4.0-133-generic i686
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dip lpadmin lxd plugdev sambashare sudo
_MarkForUpload: True
dmi.bios.date: 08/27/2010
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: 0702
dmi.board.asset.tag: To Be Filled By O.E.M.
dmi.board.name: P5KPL-CM
dmi.board.vendor: ASUSTeK Computer INC.
dmi.board.version: x.xx
dmi.chassis.asset.tag: Asset-1234567890
dmi.chassis.type: 3
dmi.chassis.vendor: Chassis Manufacture
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvr0702:bd08/27/2010:svnSystemmanufacturer:pnSystemProductName:pvrSystemVersion:rvnASUSTeKComputerINC.:rnP5KPL-CM:rvrx.xx:cvnChassisManufacture:ct3:cvrChassisVersion:
dmi.product.name: System Product Name
dmi.product.version: System Version
dmi.sys.vendor: System manufacturer

Paul White (paulw2u)
affects: ubuntu → linux (Ubuntu)
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1788730

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
tags: added: xenial
Revision history for this message
dienteperro (dienteperro1207) wrote : AlsaDevices.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
dienteperro (dienteperro1207) wrote : CRDA.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : Card0.Codecs.codec.0.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : CurrentDmesg.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : Lspci.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : Lsusb.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : PciMultimedia.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : ProcCpuinfo.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : ProcCpuinfoMinimal.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : ProcEnviron.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : ProcInterrupts.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : ProcModules.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : UdevDb.txt

apport information

Revision history for this message
dienteperro (dienteperro1207) wrote : WifiSyslog.txt

apport information

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Joseph Salisbury (jsalisbury) wrote :

Would it be possible for you to test the latest upstream kernel? Refer to https://wiki.ubuntu.com/KernelMainlineBuilds . Please test the latest v4.18 kernel[0].

If this bug is fixed in the mainline kernel, please add the following tag 'kernel-fixed-upstream'.

If the mainline kernel does not fix this bug, please add the tag: 'kernel-bug-exists-upstream'.

Once testing of the upstream kernel is complete, please mark this bug as "Confirmed".

Thanks in advance.

[0] http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.18.3

Changed in linux (Ubuntu):
importance: Undecided → Medium
status: Confirmed → Incomplete
tags: added: kernel-da-key
Revision history for this message
dienteperro (dienteperro1207) wrote :

Tried kernel 4.18.3, but it panicked. I'll try other 4.18 and see if any luck arises.

Revision history for this message
dienteperro (dienteperro1207) wrote :

Tested bionic 18.04 amd64 with standards kernels 4.15.0-29 and 4.15.0-33 and upstream kernels: 4.18.3 and 4.18.5 and both didn't identify correctly the pci-e nic.

tags: added: bionic kernel-bug-exists-upstream
Changed in linux (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Anthony Wong (anthonywong) wrote :

I built two kernels for your issue and hope one of them would work for you. Could you install the packages in https://people.canonical.com/~ypwong/lp1788730/1/ and verify if your network card works? After that, please install the packages in https://people.canonical.com/~ypwong/lp1788730/2/ and test again. Thanks.

Revision history for this message
dienteperro (dienteperro1207) wrote :

Installed files from folder 1. Card is recognized, module r8169 loaded, and is operational! I made some speed tests and all appears to be okay.

Also to note. I didn't have installed the linux-tools and linux-cloud-tools packages (from repositories, not yours). So I needed to install linux-tools-generic and linux-cloud-tools-generic from repos and then install yours. I made and image of the disk prior to deploy your files, If you want I can try the files without "tools" packages (repos and yours).

After that I installed files from folder 2. Not all went fine, after issuing command "sudo dpkg -i linux-image-unsigned-4.15.0-33-generic_4.15.0-33.36ubuntu2_amd64.deb" an error appeared:

Selecting previously unselected package linux-image-unsigned-4.15.0-33-generic.
dpkg: regarding linux-image-unsigned-4.15.0-33-generic_4.15.0-33.36ubuntu2_amd64.deb containing linux-image-unsigned-4.15.0-33-generic:
 linux-image-unsigned-4.15.0-33-generic conflicts with linux-image-4.15.0-33-generic
  linux-image-4.15.0-33-generic (version 4.15.0-33.36) is present and installed.

dpkg: error processing archive linux-image-unsigned-4.15.0-33-generic_4.15.0-33.36ubuntu2_amd64.deb (--install):
 conflicting packages - not installing linux-image-unsigned-4.15.0-33-generic
Errors were encountered while processing:
 linux-image-unsigned-4.15.0-33-generic_4.15.0-33.36ubuntu2_amd64.deb

I rebooted with a different kernel 4.15.0-29 and removed all files related to 4.15.0-33, after that rebooted and reinstalled all "folder 2" files, after reboot (again) the nic is sort-of detected but no operational, issuing command lspci -vv outputs the card with "Kernel modules: r8169" but no sign of "Kernel driver in use", this line of disappeared.

I'll try again tomorrow installing folder 2 files over folder 1. Fortunately I made an image prior to deployment of files.

Thanks a lot!

Revision history for this message
Anthony Wong (anthonywong) wrote :

You testing is good, the first kernel should work fine. I will build one more kernel soon and need your help to verify that. If the test result is again positive, I will send the fix to upstream.

Changed in linux (Ubuntu):
assignee: nobody → Anthony Wong (anthonywong)
status: Confirmed → In Progress
Revision history for this message
Anthony Wong (anthonywong) wrote :

Please download the 4.19rc1 kernel packages from https://people.canonical.com/~ypwong/lp1788730/4.19/, install them and then verify your network card's functionality. This is an RC kernel so you might see some other issues but please focus on your network card for now.

Revision history for this message
dienteperro (dienteperro1207) wrote :

Good news! I didn't have tried again "folder 2" files, went straight to 4.19rc1, and it worked fine! Nic is detected and operational as it should be.

Revision history for this message
dienteperro (dienteperro1207) wrote :

Is it possible to implement a fix available for xenial ubuntu official repositories? These kernels (4.15, 4.18 and 4.19) were tested just in bionic, xenial crashed and dependencies were not satisfied (I can provide further details if needed).

Revision history for this message
Anthony Wong (anthonywong) wrote :

Xenial will be fixed, but that will take some time.

Changed in linux (Ubuntu):
status: In Progress → Confirmed
Revision history for this message
dienteperro (dienteperro1207) wrote :

Great, thanks a lot!

Revision history for this message
Anthony Wong (anthonywong) wrote :

Patch submitted to upstream: https://lkml.org/lkml/2018/8/31/342

Changed in linux (Ubuntu):
status: Confirmed → Fix Released
Brad Figg (brad-figg)
tags: added: cscc
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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