Bagaimana saya bisa memperbaiki Wifi Broadcom driver dengan 4.15.0-xx kernel pada Ubuntu 16.04

24

Saya menginstal ulang driver pada Windows untuk Broadcom Network Adapter dan setelah itu WiFi saya berhenti bekerja di Ubuntu (16.04) sepenuhnya.

Saya mencoba menginstal ulang driver, menggunakan perintah ini:

1. sudo apt-get purge bcmwl-kernel-source
2. sudo apt-get install bcmwl-kernel-source

Tapi itu tidak membantu

Output dari perintah kedua (install bcmwl-kernel-source):

Unpacking bcmwl-kernel-source (6.30.223.271+bdcom-0ubuntu1~1.2) ...
Setting up bcmwl-kernel-source (6.30.223.271+bdcom-0ubuntu1~1.2) ...
Loading new bcmwl-6.30.223.271+bdcom DKMS files...
First Installation: checking all kernels...
Building only for 4.15.0-24-generic
Building for architecture x86_64
Building initial module for 4.15.0-24-generic
ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/bcmwl-kernel-source.0.crash'
Error! Bad return status for module build on kernel: 4.15.0-24-generic (x86_64)
Consult /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/make.log for more information.
modprobe: FATAL: Module wl not found in directory /lib/modules/4.15.0-24-generic
update-initramfs: deferring update (trigger activated)
Processing triggers for initramfs-tools (0.122ubuntu8.11) ...
update-initramfs: Generating /boot/initrd.img-4.15.0-24-generic
W: Possible missing firmware /lib/firmware/i915/kbl_guc_ver9_14.bin for module i915
W: Possible missing firmware /lib/firmware/i915/bxt_guc_ver8_7.bin for module i915
root@roman-Lenovo-G510:~# apt-get install bcmwl-kernel-source
Reading package lists... Done
Building dependency tree       
Reading state information... Done
bcmwl-kernel-source is already the newest version (6.30.223.271+bdcom-0ubuntu1~1.2).

Perintah ini lspci -nn -d 14e4menghasilkan:

08:00.0 Network controller [0280]: Broadcom Limited BCM43142 802.11b/g/n [14e4:4365] (rev 01)

Bisakah Anda memberi tahu saya cara memperbaiki masalah saya?

/var/crash/bcmwl-kernel-source.0.crash

ProblemType: Package
DKMSBuildLog:
 DKMS make.log for bcmwl-6.30.223.271+bdcom for kernel 4.15.0-24-generic (x86_64)
 Вт июл  3 16:26:40 MSK 2018
 make: Entering directory '/usr/src/linux-headers-4.15.0-24-generic'
 Makefile:976: "Cannot use CONFIG_STACK_VALIDATION=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel"
 CFG80211 API is prefered for this kernel version
 Using CFG80211 API
   CC [M]  /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.o
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c: In function ‘osl_os_get_image_block’:
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:1083:26: warning: passing argument 2 of ‘kernel_read’ makes pointer from integer without a cast [-Wint-conversion]
   rdlen = kernel_read(fp, fp->f_pos, buf, len);
                           ^
 In file included from ./include/linux/huge_mm.h:7:0,
                  from ./include/linux/mm.h:463,
                  from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/include/linuxver.h:65,
                  from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:25:
 ./include/linux/fs.h:2858:16: note: expected ‘void *’ but argument is of type ‘loff_t {aka long long int}’
  extern ssize_t kernel_read(struct file *, void *, size_t, loff_t *);
                 ^
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:1083:37: warning: passing argument 3 of ‘kernel_read’ makes integer from pointer without a cast [-Wint-conversion]
   rdlen = kernel_read(fp, fp->f_pos, buf, len);
                                      ^
 In file included from ./include/linux/huge_mm.h:7:0,
                  from ./include/linux/mm.h:463,
                  from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/include/linuxver.h:65,
                  from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:25:
 ./include/linux/fs.h:2858:16: note: expected ‘size_t {aka long unsigned int}’ but argument is of type ‘char *’
  extern ssize_t kernel_read(struct file *, void *, size_t, loff_t *);
                 ^
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:1083:42: warning: passing argument 4 of ‘kernel_read’ makes pointer from integer without a cast [-Wint-conversion]
   rdlen = kernel_read(fp, fp->f_pos, buf, len);
                                           ^
 In file included from ./include/linux/huge_mm.h:7:0,
                  from ./include/linux/mm.h:463,
                  from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/include/linuxver.h:65,
                  from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:25:
 ./include/linux/fs.h:2858:16: note: expected ‘loff_t * {aka long long int *}’ but argument is of type ‘int’
  extern ssize_t kernel_read(struct file *, void *, size_t, loff_t *);
                 ^
   CC [M]  /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.o
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c: In function ‘wl_init_timer’:
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c:2359:2: error: implicit declaration of function ‘init_timer’ [-Werror=implicit-function-declaration]
   init_timer(&t->timer);
   ^
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c:2360:10: error: ‘struct timer_list’ has no member named ‘data’
   t->timer.data = (ulong) t;
           ^
 /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c:2361:20: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
   t->timer.function = wl_timer;
                     ^
 cc1: some warnings being treated as errors
 scripts/Makefile.build:332: recipe for target '/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.o' failed
 make[1]: *** [/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.o] Error 1
 Makefile:1552: recipe for target '_module_/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build' failed
 make: *** [_module_/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build] Error 2
 make: Leaving directory '/usr/src/linux-headers-4.15.0-24-generic'
DKMSKernelVersion: 4.15.0-24-generic
Date: Tue Jul  3 16:26:46 2018
DuplicateSignature: dkms:bcmwl-kernel-source:6.30.223.271+bdcom-0ubuntu1~1.2:/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c:2359:2: error: implicit declaration of function ‘init_timer’ [-Werror=implicit-function-declaration]
Package: bcmwl-kernel-source 6.30.223.271+bdcom-0ubuntu1~1.2
PackageVersion: 6.30.223.271+bdcom-0ubuntu1~1.2
SourcePackage: bcmwl
Title: bcmwl-kernel-source 6.30.223.271+bdcom-0ubuntu1~1.2: bcmwl kernel module failed to build

/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/make.log

DKMS make.log for bcmwl-6.30.223.271+bdcom for kernel 4.15.0-24-generic (x86_64)
Чт июл  5 16:26:16 MSK 2018
make: Entering directory '/usr/src/linux-headers-4.15.0-24-generic'
Makefile:976: "Cannot use CONFIG_STACK_VALIDATION=y, please install libelf-dev, libelf-devel or elfutils-libelf-devel"
CFG80211 API is prefered for this kernel version
Using CFG80211 API
  CC [M]  /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.o
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c: In function ‘osl_os_get_image_block’:
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:1083:26: warning: passing argument 2 of ‘kernel_read’ makes pointer from integer without a cast [-Wint-conversion]
  rdlen = kernel_read(fp, fp->f_pos, buf, len);
                          ^
In file included from ./include/linux/huge_mm.h:7:0,
                 from ./include/linux/mm.h:463,
                 from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/include/linuxver.h:65,
                 from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:25:
./include/linux/fs.h:2858:16: note: expected ‘void *’ but argument is of type ‘loff_t {aka long long int}’
 extern ssize_t kernel_read(struct file *, void *, size_t, loff_t *);
                ^
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:1083:37: warning: passing argument 3 of ‘kernel_read’ makes integer from pointer without a cast [-Wint-conversion]
  rdlen = kernel_read(fp, fp->f_pos, buf, len);
                                     ^
In file included from ./include/linux/huge_mm.h:7:0,
                 from ./include/linux/mm.h:463,
                 from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/include/linuxver.h:65,
                 from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:25:
./include/linux/fs.h:2858:16: note: expected ‘size_t {aka long unsigned int}’ but argument is of type ‘char *’
 extern ssize_t kernel_read(struct file *, void *, size_t, loff_t *);
                ^
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:1083:42: warning: passing argument 4 of ‘kernel_read’ makes pointer from integer without a cast [-Wint-conversion]
  rdlen = kernel_read(fp, fp->f_pos, buf, len);
                                          ^
In file included from ./include/linux/huge_mm.h:7:0,
                 from ./include/linux/mm.h:463,
                 from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/include/linuxver.h:65,
                 from /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/shared/linux_osl.c:25:
./include/linux/fs.h:2858:16: note: expected ‘loff_t * {aka long long int *}’ but argument is of type ‘int’
 extern ssize_t kernel_read(struct file *, void *, size_t, loff_t *);
                ^
  CC [M]  /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.o
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c: In function ‘wl_init_timer’:
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c:2359:2: error: implicit declaration of function ‘init_timer’ [-Werror=implicit-function-declaration]
  init_timer(&t->timer);
  ^
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c:2360:10: error: ‘struct timer_list’ has no member named ‘data’
  t->timer.data = (ulong) t;
          ^
/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.c:2361:20: error: assignment from incompatible pointer type [-Werror=incompatible-pointer-types]
  t->timer.function = wl_timer;
                    ^
cc1: some warnings being treated as errors
scripts/Makefile.build:332: recipe for target '/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.o' failed
make[1]: *** [/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/src/wl/sys/wl_linux.o] Error 1
Makefile:1552: recipe for target '_module_/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build' failed
make: *** [_module_/var/lib/dkms/bcmwl/6.30.223.271+bdcom/build] Error 2
make: Leaving directory '/usr/src/linux-headers-4.15.0-24-generic'
John Kent
sumber
Harap lampirkan konten /var/crash/bcmwl-kernel-source.0.crashdan /var/lib/dkms/bcmwl/6.30.223.271+bdcom/build/make.loguntuk informasi lebih lanjut.
SudoSURoot
@SudoSURoot Selesai!
John Kent
Saya melihat kedua log mengatakan: silakan instal libelf-dev, libelf-devel atau elfutils-libelf-devel. Coba jalankan: sudo apt-get install libelf-devdan kemudian bersihkan dan instal kembali.
SudoSURoot
@Terrance Bisakah saya memberi tahu saya cara menuju ke kernel itu?
John Kent
//, Berikut teks lengkap kesalahan yang saya dapatkan dari prompt "masalah sistem terdeteksi" prompt: bcmwl-kernel-source 6.30.223.271 + bdcom-0ubuntu1 ~ 1.2: modul bcmwl kerne l gagal dibangun Saya di pasar untuk komputer baru, dan dengan BS seperti ini, mac OS baru mulai terlihat semakin menarik.
Nathan Basanese

Jawaban:

31

Canonical memperbarui tumpukan HWE untuk Ubuntu 16.04 ke kernel 4.15. Tetapi mereka lupa memperbarui driver nirkabel Broadcom, sehingga dapat dibangun. Ini adalah bug kritis dan sangat bodoh, yang akan menyebabkan masalah bagi banyak orang yang menggunakan LTS.

Sekarang masalah sedang diperbaiki dan versi driver yang kompatibel telah dibangun

Masalah ini dapat diatasi dengan menginstal versi yang kompatibel bcmwl-kernel-sourceyang harus dibangun di atas 4,15 kernel.

Unduh http://archive.ubuntu.com/ubuntu/pool/restricted/b/bcmwl/bcmwl-kernel-source_6.30.223.271+bdcom-0ubuntu1~1.3_amd64.deb

dan instal menggunakan dkpg.

Ini bisa dilakukan oleh

wget http://archive.ubuntu.com/ubuntu/pool/restricted/b/bcmwl/bcmwl-kernel-source_6.30.223.271+bdcom-0ubuntu1~1.3_amd64.deb
sudo dpkg -i bcmwl-kernel-source_6.30.223.271+bdcom-0ubuntu1~1.3_amd64.deb

Windows tidak terkait sama sekali.

Masalahnya adalah Anda memiliki kernel yang tidak kompatibel dengan driver.

Penting: Jika Anda tidak memiliki koneksi jaringan lain selain Broadcom Wi-Fi, Anda dapat mem-boot dengan kernel sebelumnya menggunakan menu grub dan menginstal driver. Itu harus dibangun untuk semua kernel.

Pilot6
sumber
Komentar bukan untuk diskusi panjang; percakapan ini telah dipindahkan ke obrolan .
Thomas Ward
@ DavidFoerster Saya mengubah jawaban dan memberikan tautan ke driver yang dibuat untuk 16.04. Ini adalah versi yang akan ditambahkan segera ke repo. Tidak ada perbedaan kecuali nomor versi, tetapi Anda benar bahwa lebih baik menggunakan yang ini untuk kemungkinan peningkatan di masa depan jika ada.
Pilot6
Mereka juga mematahkan driver r8168-dkms. Lihat jawaban saya di askubuntu.com/questions/1052971/… untuk lebih jelasnya.
heynnema
@heynnema Bagaimana Anda semua mendapatkan kernel 4,15? Apakah proposedrepo diaktifkan. Tidak ada yang rusak untuk mereka yang tidak berlari sebelum kereta.
Pilot6
@ Pilot6 seperti yang Anda sebutkan dalam jawaban Anda, "Canonical memperbarui HWE stack untuk Ubuntu 16.04 ke kernel 4,15.". Pengguna lain mengatakan hal yang sama ... bahwa mereka menjalankan 4,15 pada 16,04 LTS, dan seperti yang ditunjukkan oleh tautan saya, juga memerlukan driver yang lebih baru untuk berfungsi 100% lagi. Saya belum bertanya apakah mereka sedang berjalan melamar, atau tidak.
heynnema
5

Apropos ke jawaban bagus Pilot6 untuk pertanyaan ini, sepertinya perbaikan resmi untuk xenial(yaitu tidak memerlukan satu untuk menginstal paket dari bionic) telah dirilis (jika Anda menggunakan paket broadcom-sta), atau yang dilakukan (jika Anda menggunakan paket bcmwlyang menyediakan bcmwl-kernel-source).

Untuk info lebih lanjut, lihat:

broadcom-sta: https://bugs.launchpad.net/ubuntu/+source/broadcom-sta/+bug/1777444

bcmwl: https://bugs.launchpad.net/ubuntu/+source/bcmwl/+bug/1777646

pengguna847003
sumber