mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-24 11:16:51 +00:00
bcm_sta: update to 6.30.223.271 which rolls-up patches and supports current kernels
This commit is contained in:
parent
870a543196
commit
308c747ce8
@ -20,7 +20,7 @@
|
||||
# http://www.broadcom.com/support/802.11/linux_sta.php
|
||||
|
||||
PKG_NAME="bcm_sta"
|
||||
PKG_VERSION="6.30.223.248"
|
||||
PKG_VERSION="6.30.223.271"
|
||||
PKG_REV="1"
|
||||
PKG_ARCH="x86_64"
|
||||
PKG_LICENSE="nonfree"
|
||||
@ -36,11 +36,6 @@ PKG_LONGDESC="These packages contain Broadcom's IEEE 802.11a/b/g/n hybrid Linux
|
||||
PKG_IS_ADDON="no"
|
||||
PKG_AUTORECONF="no"
|
||||
|
||||
pre_make_target() {
|
||||
# rename binary to comply with upstream patches
|
||||
mv $ROOT/$PKG_BUILD/x86-64/lib/wlc_hybrid.o_shipped $ROOT/$PKG_BUILD/x86-64/lib/wlc_hybrid.o_shipped_x86_64
|
||||
}
|
||||
|
||||
make_target() {
|
||||
cd x86-64
|
||||
KBUILD_NOPEDANTIC=1 make V=1 CC=$CC -C $(kernel_path) M=`pwd` BINARCH=$TARGET_ARCH
|
||||
|
@ -1,24 +0,0 @@
|
||||
From 2903f0610336ac96411206c9458bd2885d11ea2d Mon Sep 17 00:00:00 2001
|
||||
From: Alberto Milone <alberto.milone@canonical.com>
|
||||
Date: Tue, 11 Dec 2012 15:51:26 +0100
|
||||
Subject: [PATCH 1/2] Make sure that the module licence is "MIXED/Proprietary"
|
||||
|
||||
---
|
||||
src/wl/sys/wl_linux.c | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/x86-64/src/wl/sys/wl_linux.c b/x86-64/src/wl/sys/wl_linux.c
|
||||
index f64496b..af3bea6 100644
|
||||
--- a/x86-64/src/wl/sys/wl_linux.c
|
||||
+++ b/x86-64/src/wl/sys/wl_linux.c
|
||||
@@ -159,6 +159,8 @@ static int wl_set_radio_block(void *data, bool blocked);
|
||||
static void wl_report_radio_state(wl_info_t *wl);
|
||||
#endif
|
||||
|
||||
+MODULE_LICENSE("MIXED/Proprietary");
|
||||
+
|
||||
static struct pci_device_id wl_id_table[] =
|
||||
{
|
||||
{ PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID,
|
||||
--
|
||||
1.7.9.5
|
@ -1,37 +0,0 @@
|
||||
From 15bdf69c7c1fc0d674261b08a22c958e4826bc6b Mon Sep 17 00:00:00 2001
|
||||
From: Alberto Milone <alberto.milone@canonical.com>
|
||||
Date: Tue, 11 Dec 2012 15:55:08 +0100
|
||||
Subject: [PATCH 2/2] Make sure to use the binary for the correct architecture
|
||||
|
||||
---
|
||||
Makefile | 8 +++++++-
|
||||
1 file changed, 7 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index bf30b03..1f9b974 100644
|
||||
--- a/x86-64/Makefile
|
||||
+++ b/x86-64/Makefile
|
||||
@@ -113,6 +113,12 @@ ifeq ($(APIFINAL),WEXT)
|
||||
$(info Using Wireless Extension API)
|
||||
endif
|
||||
|
||||
+ifeq ($(shell dpkg --print-architecture),amd64)
|
||||
+BINARCH = x86_64
|
||||
+else
|
||||
+BINARCH = i386
|
||||
+endif
|
||||
+
|
||||
obj-m += wl.o
|
||||
|
||||
wl-objs :=
|
||||
@@ -125,7 +131,7 @@ EXTRA_CFLAGS += -I$(src)/src/include
|
||||
EXTRA_CFLAGS += -I$(src)/src/wl/sys -I$(src)/src/wl/clm/api -I$(src)/src/wl/phy
|
||||
#EXTRA_CFLAGS += -DBCMDBG_ASSERT
|
||||
|
||||
-EXTRA_LDFLAGS := $(src)/lib/wlc_hybrid.o_shipped
|
||||
+EXTRA_LDFLAGS := $(src)/lib/wlc_hybrid.o_shipped_$(BINARCH)
|
||||
|
||||
KBASE ?= /lib/modules/`uname -r`
|
||||
KBUILD_DIR ?= $(KBASE)/build
|
||||
--
|
||||
1.7.9.5
|
@ -1,32 +0,0 @@
|
||||
From 9dab8884095e0710d62c41c45191a85d0dae59b3 Mon Sep 17 00:00:00 2001
|
||||
From: Henrik Rydberg <rydberg@euromail.se>
|
||||
Date: Sun, 9 Jan 2011 19:47:43 +0100
|
||||
Subject: [PATCH] Make up for the missing init_MUTEX
|
||||
|
||||
The init_MUTEX is a wrapper for sema_init(), and has been
|
||||
deprecated and removed in 2.6.37. In order for the dkms
|
||||
package to work also for earlier kernel versions, simply
|
||||
define the wrapper if it is missing.
|
||||
|
||||
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
|
||||
---
|
||||
src/src/wl/sys/wl_linux.c | 4 ++++
|
||||
1 files changed, 4 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/x86-64/src/src/wl/sys/wl_linux.c b/x86-64/src/src/wl/sys/wl_linux.c
|
||||
index c11678f..6f4b7a6 100644
|
||||
--- a/x86-64/src.orig/wl/sys/wl_linux.c
|
||||
+++ b/x86-64/src/wl/sys/wl_linux.c
|
||||
@@ -99,6 +99,10 @@ static void wl_dpc_rxwork(struct wl_task *task);
|
||||
|
||||
#endif
|
||||
|
||||
+#ifndef init_MUTEX
|
||||
+#define init_MUTEX(sem) sema_init(sem, 1)
|
||||
+#endif
|
||||
+
|
||||
static int wl_linux_watchdog(void *ctx);
|
||||
static
|
||||
int wl_found = 0;
|
||||
--
|
||||
1.7.2.3
|
@ -1,30 +0,0 @@
|
||||
From 463082d4d3141d89f5d174d4a85800501f71d5db Mon Sep 17 00:00:00 2001
|
||||
From: Alberto Milone <alberto.milone@canonical.com>
|
||||
Date: Fri, 22 Nov 2013 10:15:22 +0100
|
||||
Subject: [PATCH 1/1] Do not define __devinit as __init in linux >= 3.8 as
|
||||
__init was removed
|
||||
|
||||
Thanks to Krzysztof Kolasa for the patch.
|
||||
---
|
||||
src/include/linuxver.h | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/x86-64/src/include/linuxver.h b/x86-64/src/include/linuxver.h
|
||||
index 5548e71..5044739 100644
|
||||
--- a/x86-64/src/include/linuxver.h
|
||||
+++ b/x86-64/src/include/linuxver.h
|
||||
@@ -169,8 +169,12 @@ typedef irqreturn_t(*FN_ISR) (int irq, void *dev_id, struct pt_regs *ptregs);
|
||||
#define __devexit
|
||||
#endif
|
||||
#ifndef __devinit
|
||||
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 8, 0)
|
||||
+#define __devinit
|
||||
+#else
|
||||
#define __devinit __init
|
||||
#endif
|
||||
+#endif
|
||||
#ifndef __devinitdata
|
||||
#define __devinitdata
|
||||
#endif
|
||||
--
|
||||
1.7.9.5
|
@ -1,45 +0,0 @@
|
||||
From 05dd11abffe27c2fd8f618e79036be026f71b20c Mon Sep 17 00:00:00 2001
|
||||
From: Alberto Milone <alberto.milone@canonical.com>
|
||||
Date: Mon, 12 May 2014 17:32:44 +0200
|
||||
Subject: [PATCH 1/1] Add support for Linux 3.15
|
||||
|
||||
Make sure to pass the channel to cfg80211_ibss_joined().
|
||||
|
||||
This should fix LP: #1307744
|
||||
---
|
||||
src/wl/sys/wl_cfg80211_hybrid.c | 19 +++++++++++++++++++
|
||||
1 file changed, 19 insertions(+)
|
||||
|
||||
diff --git a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
index 3a5e46b..6384e58 100644
|
||||
--- a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
+++ b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
@@ -1841,7 +1841,26 @@ wl_notify_connect_status(struct wl_cfg80211_priv *wl, struct net_device *ndev,
|
||||
wl_get_assoc_ies(wl);
|
||||
memcpy(&wl->bssid, &e->addr, ETHER_ADDR_LEN);
|
||||
wl_update_bss_info(wl);
|
||||
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 15, 0)
|
||||
+ {
|
||||
+ struct wl_bss_info *bi;
|
||||
+ u16 bss_info_channel;
|
||||
+ struct ieee80211_channel *channel;
|
||||
+ u32 freq;
|
||||
+
|
||||
+ bi = (struct wl_bss_info *)(wl->extra_buf + 4);
|
||||
+ bss_info_channel = bi->ctl_ch ? bi->ctl_ch : CHSPEC_CHANNEL(bi->chanspec);
|
||||
+
|
||||
+ freq = ieee80211_channel_to_frequency(bss_info_channel,
|
||||
+ (bss_info_channel <= CH_MAX_2G_CHANNEL) ?
|
||||
+ IEEE80211_BAND_2GHZ : IEEE80211_BAND_5GHZ);
|
||||
+
|
||||
+ channel = ieee80211_get_channel(wl_to_wiphy(wl), freq);
|
||||
+ cfg80211_ibss_joined(ndev, (u8 *)&wl->bssid, channel, GFP_KERNEL);
|
||||
+ }
|
||||
+#else
|
||||
cfg80211_ibss_joined(ndev, (u8 *)&wl->bssid, GFP_KERNEL);
|
||||
+#endif
|
||||
set_bit(WL_STATUS_CONNECTED, &wl->status);
|
||||
wl->profile->active = true;
|
||||
}
|
||||
--
|
||||
1.9.1
|
@ -1,11 +0,0 @@
|
||||
--- a/x86-64/Makefile 2014-06-26 10:42:08.000000000 +0000
|
||||
+++ b/x86-64/Makefile 2014-07-17 22:44:01.662297228 +0000
|
||||
@@ -132,6 +132,8 @@
|
||||
EXTRA_CFLAGS += -I$(src)/src/shared/bcmwifi/include
|
||||
#EXTRA_CFLAGS += -DBCMDBG_ASSERT -DBCMDBG_ERR
|
||||
|
||||
+EXTRA_CFLAGS += -Wno-date-time
|
||||
+
|
||||
EXTRA_LDFLAGS := $(src)/lib/wlc_hybrid.o_shipped_$(BINARCH)
|
||||
|
||||
KBASE ?= /lib/modules/`uname -r`
|
@ -1,29 +0,0 @@
|
||||
From 05dd11abffe27c2fd8f618e79036be026f71b20c Mon Sep 17 00:00:00 2001
|
||||
From: Brian Norris <computersforpeace@gmail.com>
|
||||
Date: Tue, 26 Aug 2014 01:21:19 -0800
|
||||
|
||||
Subject: [PATCH] Add support for Linux 3.17
|
||||
|
||||
---
|
||||
src/wl/sys/wl_linux.c | 19 +++++++++++++++++++
|
||||
1 file changed, 19 insertions(+)
|
||||
|
||||
diff --git a/x86-64/src/wl/sys/wl_linux.c b/x86-64/src/wl/sys/wl_linux.c
|
||||
index 3a5e46b..6384e58 100644
|
||||
--- a/x86-64/src/wl/sys/wl_linux.c
|
||||
+++ b/x86-64/src/wl/sys/wl_linux.c
|
||||
@@ -1351,7 +1351,12 @@
|
||||
dev->priv = priv_link;
|
||||
#else
|
||||
|
||||
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(3, 17, 0))
|
||||
dev = alloc_netdev(sizeof(priv_link_t), intf_name, ether_setup);
|
||||
+#else
|
||||
+ dev = alloc_netdev(sizeof(priv_link_t), intf_name, NET_NAME_UNKNOWN,
|
||||
+ ether_setup);
|
||||
+#endif
|
||||
if (!dev) {
|
||||
WL_ERROR(("wl%d: %s: alloc_netdev failed\n",
|
||||
(wl->pub)?wl->pub->unit:wlif->subunit, __FUNCTION__));
|
||||
--
|
||||
1.9.1
|
@ -1,36 +0,0 @@
|
||||
From 8b6f3f87c81fa35eef24831e9a93eff1e6e1444f Mon Sep 17 00:00:00 2001
|
||||
From: Alberto Milone <alberto.milone@canonical.com>
|
||||
Date: Mon, 10 Nov 2014 09:22:09 +0100
|
||||
Subject: [PATCH 1/1] Update cfg80211_inform_bss() to use
|
||||
CFG80211_BSS_FTYPE_UNKNOWN
|
||||
|
||||
This is only necessary with Linux >= 3.18.
|
||||
|
||||
Original author: Krzysztof Kolasa
|
||||
Source: https://raw.githubusercontent.com/kolasa/bcmwl-6.30.223.248/master/patches/0015-CFG80211_BSS_FTYPE_UNKNOWN-linux-3.18.0.patch
|
||||
---
|
||||
src/wl/sys/wl_cfg80211_hybrid.c | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
index ea0726f..ee0d3a0 100644
|
||||
--- a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
+++ b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
@@ -2010,9 +2010,15 @@ static s32 wl_inform_single_bss(struct wl_cfg80211_priv *wl, struct wl_bss_info
|
||||
|
||||
notify_ie = (u8 *)bi + le16_to_cpu(bi->ie_offset);
|
||||
notify_ielen = le32_to_cpu(bi->ie_length);
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 18, 0)
|
||||
cbss = cfg80211_inform_bss(wiphy, channel, (const u8 *)(bi->BSSID.octet),
|
||||
0, beacon_proberesp->capab_info, beacon_proberesp->beacon_int,
|
||||
(const u8 *)notify_ie, notify_ielen, signal, GFP_KERNEL);
|
||||
+#else
|
||||
+ cbss = cfg80211_inform_bss(wiphy, channel, CFG80211_BSS_FTYPE_UNKNOWN, (const u8 *)(bi->BSSID.octet),
|
||||
+ 0, beacon_proberesp->capab_info, beacon_proberesp->beacon_int,
|
||||
+ (const u8 *)notify_ie, notify_ielen, signal, GFP_KERNEL);
|
||||
+#endif
|
||||
|
||||
if (unlikely(!cbss))
|
||||
return -ENOMEM;
|
||||
--
|
||||
1.9.1
|
@ -1,56 +0,0 @@
|
||||
From 92fc12028553831a87cfa87ffa8d676ab0f60522 Mon Sep 17 00:00:00 2001
|
||||
From: Simon Eisenmann <simon@longsleep.org>
|
||||
Date: Sat, 14 Mar 2015 15:02:08 +0100
|
||||
Subject: [PATCH] Repair make warnings
|
||||
|
||||
Orginal author: Krzysztof Kolasa
|
||||
Source: https://raw.githubusercontent.com/kolasa/bcmwl-6.30.223.248/9fafc1faa6dc410bf8aba340a7929f404c73d30e/patches/0016-repair-make-warnings.patch
|
||||
---
|
||||
src/wl/sys/wl_cfg80211_hybrid.c | 13 ++++++++++++-
|
||||
1 file changed, 12 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
index ea0726f..b265e25 100644
|
||||
--- a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
+++ b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
@@ -63,8 +63,13 @@ static s32 wl_cfg80211_set_wiphy_params(struct wiphy *wiphy, u32 changed);
|
||||
static s32 wl_cfg80211_join_ibss(struct wiphy *wiphy, struct net_device *dev,
|
||||
struct cfg80211_ibss_params *params);
|
||||
static s32 wl_cfg80211_leave_ibss(struct wiphy *wiphy, struct net_device *dev);
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0)
|
||||
static s32 wl_cfg80211_get_station(struct wiphy *wiphy,
|
||||
struct net_device *dev, u8 *mac, struct station_info *sinfo);
|
||||
+#else
|
||||
+static s32 wl_cfg80211_get_station(struct wiphy *wiphy,
|
||||
+ struct net_device *dev, const u8 *mac, struct station_info *sinfo);
|
||||
+#endif
|
||||
static s32 wl_cfg80211_set_power_mgmt(struct wiphy *wiphy,
|
||||
struct net_device *dev, bool enabled, s32 timeout);
|
||||
static int wl_cfg80211_connect(struct wiphy *wiphy, struct net_device *dev,
|
||||
@@ -1387,7 +1392,7 @@ wl_cfg80211_get_key(struct wiphy *wiphy, struct net_device *dev,
|
||||
key_endian_to_host(&key);
|
||||
|
||||
params.key_len = (u8) min_t(u8, DOT11_MAX_KEY_SIZE, key.len);
|
||||
- memcpy(params.key, key.data, params.key_len);
|
||||
+ memcpy((char *)params.key, key.data, params.key_len);
|
||||
|
||||
if ((err = wl_dev_ioctl(dev, WLC_GET_WSEC, &wsec, sizeof(wsec)))) {
|
||||
return err;
|
||||
@@ -1421,9 +1426,15 @@ wl_cfg80211_get_key(struct wiphy *wiphy, struct net_device *dev,
|
||||
return err;
|
||||
}
|
||||
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 16, 0)
|
||||
static s32
|
||||
wl_cfg80211_get_station(struct wiphy *wiphy, struct net_device *dev,
|
||||
u8 *mac, struct station_info *sinfo)
|
||||
+#else
|
||||
+static s32
|
||||
+wl_cfg80211_get_station(struct wiphy *wiphy, struct net_device *dev,
|
||||
+ const u8 *mac, struct station_info *sinfo)
|
||||
+#endif
|
||||
{
|
||||
struct wl_cfg80211_priv *wl = wiphy_to_wl(wiphy);
|
||||
scb_val_t scb_val;
|
||||
--
|
||||
2.1.0
|
@ -1,39 +0,0 @@
|
||||
From a97b0a39f016589e38706d7d32f902847dcbbf27 Mon Sep 17 00:00:00 2001
|
||||
From: Simon Eisenmann <simon@longsleep.org>
|
||||
Date: Sat, 14 Mar 2015 15:10:48 +0100
|
||||
Subject: [PATCH] Add support for Linux 4.0
|
||||
|
||||
---
|
||||
src/wl/sys/wl_cfg80211_hybrid.c | 8 ++++++++
|
||||
1 file changed, 8 insertions(+)
|
||||
|
||||
diff --git a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
index b265e25..425c7c5 100644
|
||||
--- a/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
+++ b/x86-64/src/wl/sys/wl_cfg80211_hybrid.c
|
||||
@@ -1452,7 +1452,11 @@ wl_cfg80211_get_station(struct wiphy *wiphy, struct net_device *dev,
|
||||
WL_DBG(("Could not get rate (%d)\n", err));
|
||||
} else {
|
||||
rate = dtoh32(rate);
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 0, 0)
|
||||
sinfo->filled |= STATION_INFO_TX_BITRATE;
|
||||
+#else
|
||||
+ sinfo->filled |= BIT(NL80211_STA_INFO_TX_BITRATE);
|
||||
+#endif
|
||||
sinfo->txrate.legacy = rate * 5;
|
||||
WL_DBG(("Rate %d Mbps\n", (rate / 2)));
|
||||
}
|
||||
@@ -1465,7 +1469,11 @@ wl_cfg80211_get_station(struct wiphy *wiphy, struct net_device *dev,
|
||||
return err;
|
||||
}
|
||||
rssi = dtoh32(scb_val.val);
|
||||
+#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 0, 0)
|
||||
sinfo->filled |= STATION_INFO_SIGNAL;
|
||||
+#else
|
||||
+ sinfo->filled |= BIT(NL80211_STA_INFO_SIGNAL);
|
||||
+#endif
|
||||
sinfo->signal = rssi;
|
||||
WL_DBG(("RSSI %d dBm\n", rssi));
|
||||
}
|
||||
--
|
||||
2.1.0
|
@ -1,26 +0,0 @@
|
||||
diff -Naur bcm_sta-6.30.223.248/x86-32/src/wl/sys/wl_linux.c bcm_sta-6.30.223.248.patch/x86-32/src/wl/sys/wl_linux.c
|
||||
--- bcm_sta-6.30.223.248/x86-32/src/wl/sys/wl_linux.c 2014-06-26 12:41:38.000000000 +0200
|
||||
+++ bcm_sta-6.30.223.248.patch/x86-32/src/wl/sys/wl_linux.c 2015-09-04 19:58:10.496600089 +0200
|
||||
@@ -2157,8 +2157,8 @@
|
||||
wlif = WL_DEV_IF(dev);
|
||||
wl = WL_INFO(dev);
|
||||
|
||||
+ skb->prev = NULL;
|
||||
if (WL_ALL_PASSIVE_ENAB(wl) || (WL_RTR() && WL_CONFIG_SMP())) {
|
||||
- skb->prev = NULL;
|
||||
|
||||
TXQ_LOCK(wl);
|
||||
|
||||
diff -Naur bcm_sta-6.30.223.248/x86-64/src/wl/sys/wl_linux.c bcm_sta-6.30.223.248.patch/x86-64/src/wl/sys/wl_linux.c
|
||||
--- bcm_sta-6.30.223.248/x86-64/src/wl/sys/wl_linux.c 2014-06-26 12:42:08.000000000 +0200
|
||||
+++ bcm_sta-6.30.223.248.patch/x86-64/src/wl/sys/wl_linux.c 2015-09-04 19:56:31.957374783 +0200
|
||||
@@ -2157,8 +2157,8 @@
|
||||
wlif = WL_DEV_IF(dev);
|
||||
wl = WL_INFO(dev);
|
||||
|
||||
+ skb->prev = NULL;
|
||||
if (WL_ALL_PASSIVE_ENAB(wl) || (WL_RTR() && WL_CONFIG_SMP())) {
|
||||
- skb->prev = NULL;
|
||||
|
||||
TXQ_LOCK(wl);
|
||||
|
Loading…
x
Reference in New Issue
Block a user