Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 771107 Details for
Bug 836165
net-wireless/broadcom-sta-6.30.223.271-r6 fails to compile with linux kernel 5.17
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
broadcom-sta-6.30.223.271-r6-linux-5.17.patch
broadcom-sta-6.30.223.271-r6-linux-5.17.patch (text/plain), 2.86 KB, created by
tka
on 2022-04-17 12:20:52 UTC
(
hide
)
Description:
broadcom-sta-6.30.223.271-r6-linux-5.17.patch
Filename:
MIME Type:
Creator:
tka
Created:
2022-04-17 12:20:52 UTC
Size:
2.86 KB
patch
obsolete
>From 24eeb26f0febb213e8adffde2d4c50267a7c2767 Mon Sep 17 00:00:00 2001 >From: Joan Bruguera <joanbrugueram@gmail.com> >Date: Wed, 12 Jan 2022 20:49:20 +0100 >Subject: [PATCH] Tentative fix for broadcom-wl 6.30.223.271 driver for Linux 5.17-rc1 >Origin: https://gist.github.com/joanbm/37fd0590f30b41e7e89ade6e242ca16e > >Set netdev->dev_addr through dev_addr_mod + PDE_DATA fix > >Since Linux 5.17 netdev->dev_addr is const and must be changed through >dev_addr_mod, otherwise a warning is logged in dmesg and bad things may happen. > >NB: The #if is not wrong, dev_addr_mod is defined since Linux 5.15-rc1 > >Plus a trivial fix for PDE_DATA. > >Applies on top of all the patches applied to broadcom-wl-dkms 6.30.223.271-28 on Arch Linux. > >See also: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=adeef3e32146a8d2a73c399dc6f5d76a449131b1 > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=359745d78351c6f5442435f81549f0207ece28aa > >Adapted to apply on top of gentoo patches by tka. > >Signed-off-by: Timo Kamph <tka@kamph.org> >--- > src/wl/sys/wl_linux.c | 16 +++++++++++++--- > 1 file changed, 13 insertions(+), 3 deletions(-) > >diff --git a/src/wl/sys/wl_linux.c b/src/wl/sys/wl_linux.c >index 7ba336f..0537ec8 100644 >--- a/src/wl/sys/wl_linux.c >+++ b/src/wl/sys/wl_linux.c >@@ -93,6 +93,10 @@ struct iw_statistics *wl_get_wireless_stats(struct net_device *dev); > > #include <wlc_wowl.h> > >+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(5, 17, 0)) >+#define PDE_DATA pde_data >+#endif >+ > #ifdef HAVE_TIMER_SETUP > static void wl_timer(struct timer_list *list); > #else >@@ -493,6 +497,12 @@ wl_if_setup(struct net_device *dev) > #endif > } > >+#if LINUX_VERSION_CODE < KERNEL_VERSION(5, 15, 0) >+static inline void eth_hw_addr_set(struct net_device *dev, const void *addr) { >+ memcpy(dev->dev_addr, addr, ETHER_ADDR_LEN); >+} >+#endif >+ > static wl_info_t * > wl_attach(uint16 vendor, uint16 device, ulong regs, > uint bustype, void *btparam, uint irq, uchar* bar1_addr, uint32 bar1_size) >@@ -644,7 +654,7 @@ wl_attach(uint16 vendor, uint16 device, ulong regs, > WL_ERROR(("wl%d: Error setting MAC ADDRESS\n", unit)); > } > #endif >- bcopy(&wl->pub->cur_etheraddr, dev->dev_addr, ETHER_ADDR_LEN); >+ eth_hw_addr_set(dev, wl->pub->cur_etheraddr.octet); > > online_cpus = 1; > >@@ -1850,7 +1860,7 @@ wl_set_mac_address(struct net_device *dev, void *addr) > > WL_LOCK(wl); > >- bcopy(sa->sa_data, dev->dev_addr, ETHER_ADDR_LEN); >+ eth_hw_addr_set(dev, sa->sa_data); > err = wlc_iovar_op(wl->wlc, "cur_etheraddr", NULL, 0, sa->sa_data, ETHER_ADDR_LEN, > IOV_SET, (WL_DEV_IF(dev))->wlcif); > WL_UNLOCK(wl); >@@ -3029,7 +3039,7 @@ _wl_add_monitor_if(wl_task_t *task) > else > dev->type = ARPHRD_IEEE80211_RADIOTAP; > >- bcopy(wl->dev->dev_addr, dev->dev_addr, ETHER_ADDR_LEN); >+ eth_hw_addr_set(dev, wl->dev->dev_addr); > > #if defined(WL_USE_NETDEV_OPS) > dev->netdev_ops = &wl_netdev_monitor_ops; >-- >2.35.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 836165
:
767877
|
768771
|
768772
| 771107 |
842717
|
842719