问题 Realtak 以太网驱动程序 ubuntu 20.04,内核 5.4 构建 rtl r8101-1.037.01 驱动程序

问题 Realtak 以太网驱动程序 ubuntu 20.04,内核 5.4 构建 rtl r8101-1.037.01 驱动程序

我的笔记本电脑装有 Realtek RTL 810xE PCI Express 快速以太网控制器,运行 Ubuntu 20.04,内核版本 5.4.0-1074-gke。当我尝试更新 ubuntu 时,缺少此驱动程序,我从https://www.realtek.com/en/component/zoo/category/network-interface-controllers-10-100m-fast-ethernet-pci-express-software 我下载了适用于 ubuntu 的驱动程序,当我尝试构建 r9101-1.037.01 时出现以下错误

make[2]: Entering directory '/usr/src/linux-headers-5.4.0-1074-gke'
  CC [M]  /home/gowtham/RTLdriver/r8101-1.036.00/src/r8101_n.o
/home/gowtham/RTLdriver/r8101-1.036.00/src/r8101_n.c:11288:28: error: initialization of ‘void (*)(struct net_device *, unsigned int)’ from incompatible pointer type ‘void (*)(struct net_device *)’ [-Werror=incompatible-pointer-types]
11288 |         .ndo_tx_timeout  = rtl8101_tx_timeout,
      |                            ^~~~~~~~~~~~~~~~~~
/home/gowtham/RTLdriver/r8101-1.036.00/src/r8101_n.c:11288:28: note: (near initialization for ‘rtl8101_netdev_ops.ndo_tx_timeout’)
cc1: some warnings being treated as errors
make[3]: *** [scripts/Makefile.build:270: /home/gowtham/RTLdriver/r8101-1.036.00/src/r8101_n.o] Error 1
make[2]: *** [Makefile:1762: /home/gowtham/RTLdriver/r8101-1.036.00/src] Error 2
make[2]: Leaving directory '/usr/src/linux-headers-5.4.0-1074-gke'
make[1]: *** [Makefile:117: modules] Error 2

我无法通过以太网或 WiFi 连接,因为它基于 QCA9377 芯片组,而且驱动程序也缺失。您能帮忙解决一下吗?

答案1

请在其他计算机上下载此文件:http://security.ubuntu.com/ubuntu/pool/main/l/linux-gke/linux-modules-extra-5.4.0-1074-gke_5.4.0-1074.79_amd64.deb将其传输到 USB 密钥上或类似于 Ubuntu 计算机桌面的地方。

打开终端并执行:

sudo dpkg -i ~/Desktop/linux*.deb

重启。您的以太网和无线应该可以正常工作。

相关内容