[packages/kernel-net-wl] up to 6.30.223.141 (WEXT support is gone)
glen
glen at pld-linux.org
Sun Sep 29 21:21:04 CEST 2013
commit b2160a76f2c967cd990b6f3a2869ebac740a85a6
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Sun Sep 29 22:18:47 2013 +0300
up to 6.30.223.141 (WEXT support is gone)
- Upgraded to support 3.8.x.
- Added 4352 support.
- Dropped WEXT support.
kernel-net-wl-linux-3.10.patch | 334 -----------------------------------------
kernel-net-wl-linux-3.2.patch | 10 --
kernel-net-wl-linux-3.4.patch | 12 --
kernel-net-wl.spec | 31 ++--
4 files changed, 15 insertions(+), 372 deletions(-)
---
diff --git a/kernel-net-wl.spec b/kernel-net-wl.spec
index ff259df..91aecfb 100644
--- a/kernel-net-wl.spec
+++ b/kernel-net-wl.spec
@@ -2,24 +2,21 @@
%bcond_without dist_kernel # allow non-distribution kernel
%bcond_with verbose # verbose build (V=1)
-%define rel 19
+%define rel 1
%define pname wl
%define file_ver %(echo %{version} | tr . _)
Summary: Broadcom 802.11 a/b/g/n hybrid Linux networking device driver
Name: kernel%{_alt_kernel}-net-wl
-Version: 5.100.82.112
+Version: 6.30.223.141
Release: %{rel}@%{_kernel_ver_str}
License: other
Group: Base/Kernel
-Source0: http://www.broadcom.com/docs/linux_sta/hybrid-portsrc_x86_32-v%{file_ver}.tar.gz
-# Source0-md5: 62d04d148b99f993ef575a71332593a9
-Source1: http://www.broadcom.com/docs/linux_sta/hybrid-portsrc_x86_64-v%{file_ver}.tar.gz
-# Source1-md5: 310d7ce233a9a352fbe62c451b2ea309
+Source0: http://www.broadcom.com/docs/linux_sta/hybrid-v35-nodebug-pcoem-%{file_ver}.tar.gz
+# Source0-md5: f4809d9149e8e60ef95021ae93a4bf21
+Source1: http://www.broadcom.com/docs/linux_sta/hybrid-v35_64-nodebug-pcoem-%{file_ver}.tar.gz
+# Source1-md5: 039f33d2a3ff2890e42717092d1eb0c4
Source2: http://www.broadcom.com/docs/linux_sta/README.txt
-# Source2-md5: 6fd54aac59a53559d01520f35500693b
-Patch1: kernel-net-wl-linux-3.2.patch
-Patch2: kernel-net-wl-linux-3.4.patch
-Patch3: kernel-net-wl-linux-3.10.patch
+# Source2-md5: 8a6e8708a5e00ab6d841cde51d70eb1b
URL: http://www.broadcom.com/support/802.11/linux_sta.php
%{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.20.2}
BuildRequires: rpmbuild(macros) >= 1.379
@@ -39,26 +36,28 @@ device driver for use with Broadcom's BCM4311-, BCM4312-, BCM4313-,
BCM4321-, BCM4322-, BCM43224-, and BCM43225-, BCM43227- and
BCM43228-based hardware.
+This is an Official Release of Broadcom's hybrid Linux driver for use
+with Broadcom based hardware.
+
%prep
%ifarch %{x8664}
%define src 1
%else
%define src 0
%endif
-%setup -c -T -q -n %{pname}-%{version} -b%src
-%patch1 -p0
-%patch2 -p0
-%patch3 -p1
+%setup -c -T -q -n %{pname}-%{version} -b%{src}
cat > Makefile << EOF
obj-m += wl.o
-wl-objs := src/wl/sys/wl_linux.o
+wl-objs += src/wl/sys/wl_linux.o
wl-objs += src/wl/sys/wl_iw.o
wl-objs += src/shared/linux_osl.o
-EXTRA_CFLAGS := -I%{_builddir}/%{pname}-%{version}/src/include
+EXTRA_CFLAGS += -I%{_builddir}/%{pname}-%{version}/src/include
+EXTRA_CFLAGS += -I%{_builddir}/%{pname}-%{version}/src/common/include
EXTRA_CFLAGS += -I%{_builddir}/%{pname}-%{version}/src/wl/sys
+EXTRA_CFLAGS += -I%{_builddir}/%{pname}-%{version}/src/shared/bcmwifi/include
EXTRA_LDFLAGS := $PWD/lib/wlc_hybrid.o_shipped
EOF
diff --git a/kernel-net-wl-linux-3.10.patch b/kernel-net-wl-linux-3.10.patch
deleted file mode 100644
index f10e787..0000000
--- a/kernel-net-wl-linux-3.10.patch
+++ /dev/null
@@ -1,334 +0,0 @@
---- a/Makefile 2011-10-22 18:55:54.000000000 +0200
-+++ b/Makefile 2013-07-05 19:45:48.017337088 +0200
-@@ -16,7 +16,7 @@
- ifneq ($(KERNELRELEASE),)
-
- LINUXVER_GOODFOR_CFG80211:=$(strip $(shell \
-- if [ "$(VERSION)" -ge "2" -a "$(PATCHLEVEL)" -ge "6" -a "$(SUBLEVEL)" -ge "32" ]; then \
-+ if [ "$(VERSION)" -ge "3" -o "$(VERSION)" -ge "2" -a "$(PATCHLEVEL)" -ge "6" -a "$(SUBLEVEL)" -ge "32" ]; then \
- echo TRUE; \
- else \
- echo FALSE; \
-@@ -24,7 +24,7 @@
- ))
-
- LINUXVER_WEXT_ONLY:=$(strip $(shell \
-- if [ "$(VERSION)" -ge "2" -a "$(PATCHLEVEL)" -ge "6" -a "$(SUBLEVEL)" -ge "17" ]; then \
-+ if [ "$(VERSION)" -ge "3" -o "$(VERSION)" -ge "2" -a "$(PATCHLEVEL)" -ge "6" -a "$(SUBLEVEL)" -ge "17" ]; then \
- echo FALSE; \
- else \
- echo TRUE; \
---- a/src/include/bcmutils.h 2011-10-22 18:55:54.000000000 +0200
-+++ b/src/include/bcmutils.h 2013-07-05 19:45:48.017337088 +0200
-@@ -555,7 +555,11 @@
- extern void prhex(const char *msg, uchar *buf, uint len);
-
- extern bcm_tlv_t *BCMROMFN(bcm_next_tlv)(bcm_tlv_t *elt, int *buflen);
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 8, 0)
- extern bcm_tlv_t *BCMROMFN(bcm_parse_tlvs)(void *buf, int buflen, uint key);
-+#else
-+extern bcm_tlv_t *BCMROMFN(bcm_parse_tlvs)(const void *buf, int buflen, uint key);
-+#endif
- extern bcm_tlv_t *BCMROMFN(bcm_parse_ordered_tlvs)(void *buf, int buflen, uint key);
-
- extern const char *bcmerrorstr(int bcmerror);
---- a/src/wl/sys/wl_cfg80211.c 2011-10-22 18:55:54.000000000 +0200
-+++ b/src/wl/sys/wl_cfg80211.c 2013-07-05 19:58:00.993999187 +0200
-@@ -42,8 +42,7 @@
- enum nl80211_iftype type, u32 *flags, struct vif_params *params);
- static s32 __wl_cfg80211_scan(struct wiphy *wiphy, struct net_device *ndev,
- struct cfg80211_scan_request *request, struct cfg80211_ssid *this_ssid);
--static s32 wl_cfg80211_scan(struct wiphy *wiphy, struct net_device *ndev,
-- struct cfg80211_scan_request *request);
-+static s32 wl_cfg80211_scan(struct wiphy *wiphy, struct cfg80211_scan_request *request);
- 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);
-@@ -56,15 +55,12 @@
- struct cfg80211_connect_params *sme);
- static s32 wl_cfg80211_disconnect(struct wiphy *wiphy, struct net_device *dev, u16 reason_code);
-
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 36)
--static s32 wl_cfg80211_set_tx_power(struct wiphy *wiphy,
-- enum nl80211_tx_power_setting type, s32 dbm);
--#else
--static s32 wl_cfg80211_set_tx_power(struct wiphy *wiphy,
-- enum tx_power_setting type, s32 dbm);
--#endif
-+static int wl_cfg80211_set_tx_power(struct wiphy *wiphy,
-+ struct wireless_dev *wdev,
-+ enum nl80211_tx_power_setting type, int dbm);
-
--static s32 wl_cfg80211_get_tx_power(struct wiphy *wiphy, s32 *dbm);
-+static int wl_cfg80211_get_tx_power(struct wiphy *wiphy,
-+ struct wireless_dev *wdev, int *dbm);
-
- #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 38)
- static s32 wl_cfg80211_config_default_key(struct wiphy *wiphy,
-@@ -570,10 +566,11 @@
- }
-
- static s32
--wl_cfg80211_scan(struct wiphy *wiphy, struct net_device *ndev,
-- struct cfg80211_scan_request *request)
-+wl_cfg80211_scan(struct wiphy *wiphy, struct cfg80211_scan_request *request)
- {
- s32 err = 0;
-+ struct wl_priv *wl = wiphy_to_wl(wiphy);
-+ struct net_device *ndev = wl_to_ndev(wl);
-
- CHECK_SYS_UP();
- err = __wl_cfg80211_scan(wiphy, ndev, request, NULL);
-@@ -742,7 +739,7 @@
- else
- memset(&join_params.params.bssid, 0, ETHER_ADDR_LEN);
-
-- wl_ch_to_chanspec(params->channel, &join_params, &join_params_size);
-+ wl_ch_to_chanspec(params->chandef.chan, &join_params, &join_params_size);
-
- err = wl_dev_ioctl(dev, WLC_SET_SSID, &join_params, join_params_size);
- if (err) {
-@@ -1099,16 +1096,10 @@
- return err;
- }
-
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 36)
--static s32
--wl_cfg80211_set_tx_power(struct wiphy *wiphy, enum nl80211_tx_power_setting type, s32 dbm)
--#else
--#define NL80211_TX_POWER_AUTOMATIC TX_POWER_AUTOMATIC
--#define NL80211_TX_POWER_LIMITED TX_POWER_LIMITED
--#define NL80211_TX_POWER_FIXED TX_POWER_FIXED
--static s32
--wl_cfg80211_set_tx_power(struct wiphy *wiphy, enum tx_power_setting type, s32 dbm)
--#endif
-+static int
-+wl_cfg80211_set_tx_power(struct wiphy *wiphy,
-+ struct wireless_dev *wdev,
-+ enum nl80211_tx_power_setting type, int dbm)
- {
-
- struct wl_priv *wl = wiphy_to_wl(wiphy);
-@@ -1155,16 +1146,17 @@
- }
- wl->conf->tx_power = dbm;
-
-- return err;
-+ return (int) err;
- }
-
--static s32 wl_cfg80211_get_tx_power(struct wiphy *wiphy, s32 *dbm)
-+static int wl_cfg80211_get_tx_power(struct wiphy *wiphy,
-+ struct wireless_dev *wdev, int *dbm)
- {
- struct wl_priv *wl = wiphy_to_wl(wiphy);
- struct net_device *ndev = wl_to_ndev(wl);
- s32 txpwrdbm;
- u8 result;
-- s32 err = 0;
-+ int err = 0;
-
- CHECK_SYS_UP();
- err = wl_dev_intvar_get(ndev, "qtxpower", &txpwrdbm);
-@@ -1173,8 +1165,7 @@
- return err;
- }
- result = (u8) (txpwrdbm & ~WL_TXPWR_OVERRIDE);
-- *dbm = (s32) bcm_qdbm_to_mw(result);
--
-+ *dbm = (int) bcm_qdbm_to_mw(result);
- return err;
- }
-
-@@ -1466,7 +1457,10 @@
- scb_val.val = 0;
- err = wl_dev_ioctl(dev, WLC_GET_RSSI, &scb_val, sizeof(scb_val_t));
- if (err) {
-- WL_ERR(("Could not get rssi (%d)\n", err));
-+ if (err != -EINVAL) {
-+ // Don't fill syslog with EINVAL error
-+ WL_ERR(("Could not get rssi (%d)\n", err));
-+ }
- return err;
- }
- rssi = dtoh32(scb_val.val);
-@@ -1811,7 +1805,7 @@
- notif_bss_info->frame_len = offsetof(struct ieee80211_mgmt, u.beacon.variable) +
- wl_get_ielen(wl);
- freq = ieee80211_channel_to_frequency(notif_bss_info->channel
--#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 39)
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 39)
- ,(notif_bss_info->channel <= CH_MAX_2G_CHANNEL) ? IEEE80211_BAND_2GHZ : IEEE80211_BAND_5GHZ
- #endif
- );
-@@ -2042,9 +2036,10 @@
- struct bcm_tlv *tim;
- u16 beacon_interval;
- s32 dtim_period;
-- size_t ie_len;
-- u8 *ie;
- s32 err = 0;
-+ size_t ie_len;
-+ const u8 *ie;
-+ const struct cfg80211_bss_ies *ies;
-
- ssid = &wl->profile->ssid;
- bss = cfg80211_get_bss(wl_to_wiphy(wl), NULL, (s8 *)&wl->bssid,
-@@ -2074,10 +2069,16 @@
- beacon_interval = cpu_to_le16(bi->beacon_period);
- } else {
- WL_DBG(("Found the AP in the list - BSSID %pM\n", bss->bssid));
-- ie = bss->information_elements;
-- ie_len = bss->len_information_elements;
-+ ies = (const struct cfg80211_bss_ies*)rcu_dereference(bss->ies);
-+ if (!ies) {
-+ /* This should never happen */
-+ err = -EIO;
-+ goto update_bss_info_out;
-+ }
-+ ie = ies->data;
-+ ie_len = (size_t)(ies->len);
- beacon_interval = bss->beacon_interval;
-- cfg80211_put_bss(bss);
-+ cfg80211_put_bss(wl_to_wiphy(wl), bss);
- }
-
- tim = bcm_parse_tlvs(ie, ie_len, WLAN_EID_TIM);
---- a/src/wl/sys/wl_iw.h 2011-10-22 18:55:54.000000000 +0200
-+++ b/src/wl/sys/wl_iw.h 2013-07-05 19:45:48.020670421 +0200
-@@ -16,6 +16,7 @@
- #define _wl_iw_h_
-
- #include <linux/wireless.h>
-+#include <linux/semaphore.h>
-
- #include <typedefs.h>
- #include <proto/ethernet.h>
---- a/src/wl/sys/wl_linux.c 2011-10-22 18:55:54.000000000 +0200
-+++ b/src/wl/sys/wl_linux.c 2013-07-05 19:52:29.540667919 +0200
-@@ -843,7 +842,7 @@
- pci_set_drvdata(pdev, NULL);
- }
-
--static struct pci_driver wl_pci_driver = {
-+static struct pci_driver wl_pci_driver __refdata = {
- name: "wl",
- probe: wl_pci_probe,
- suspend: wl_suspend,
-@@ -1579,11 +1578,7 @@
- }
-
- WL_LOCK(wl);
-- if (!capable(CAP_NET_ADMIN)) {
-- bcmerror = BCME_EPERM;
-- } else {
-- bcmerror = wlc_ioctl(wl->wlc, ioc.cmd, buf, ioc.len, wlif->wlcif);
-- }
-+ bcmerror = wlc_ioctl(wl->wlc, ioc.cmd, buf, ioc.len, wlif->wlcif);
- WL_UNLOCK(wl);
-
- done1:
-@@ -2960,7 +2955,7 @@
- void
- wl_tkip_printstats(wl_info_t *wl, bool group_key)
- {
--#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 14)
-+#if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 14) && LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
- char debug_buf[512];
- int idx;
- if (wl->tkipmodops) {
-@@ -3120,6 +3115,7 @@
- }
-
- static int
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
- wl_proc_read(char *buffer, char **start, off_t offset, int length, int *eof, void *data)
- {
- wl_info_t * wl = (wl_info_t *)data;
-@@ -3120,19 +3115,86 @@
- }
- return length;
- }
-+#else
-+wl_proc_read(struct seq_file *seq, void *offset)
-+{
-+ wl_info_t * wl = (wl_info_t *)seq->private;
-+ int bcmerror, to_user;
-+
-+ WL_LOCK(wl);
-+ bcmerror = wlc_ioctl(wl->wlc, WLC_GET_MONITOR, &to_user, sizeof(int), NULL);
-+ WL_UNLOCK(wl);
-+
-+ seq_printf(seq, "%d\n", to_user);
-+ return bcmerror;
-+}
-+
-+static ssize_t wl_proc_write(struct file *file, const char __user *buff,
-+ size_t length, loff_t *ppos)
-+{
-+ struct seq_file *seq = file->private_data;
-+ wl_info_t * wl = (wl_info_t *)seq->private;
-+ int bcmerror, from_user = 0;
-+
-+ if (length != 1) {
-+ WL_ERROR(("%s: Invalid data length\n", __FUNCTION__));
-+ return -EIO;
-+ }
-+
-+ if (copy_from_user(&from_user, buff, 1)) {
-+ WL_ERROR(("%s: copy from user failed\n", __FUNCTION__));
-+ return -EFAULT;
-+ }
-+
-+ if (from_user >= 0x30)
-+ from_user -= 0x30;
-+
-+ WL_LOCK(wl);
-+ bcmerror = wlc_ioctl(wl->wlc, WLC_SET_MONITOR, &from_user, sizeof(int), NULL);
-+ WL_UNLOCK(wl);
-+
-+ if (bcmerror < 0) {
-+ WL_ERROR(("%s: SET_MONITOR failed with %d\n", __FUNCTION__, bcmerror));
-+ return -EIO;
-+ }
-+ *ppos += length;
-+ return length;
-+}
-+
-+static int wl_proc_open(struct inode *inode, struct file *file)
-+{
-+ return single_open(file, wl_proc_read, PDE_DATA(inode));
-+}
-+
-+static const struct file_operations wl_proc_fops = {
-+ .owner = THIS_MODULE,
-+ .open = wl_proc_open,
-+ .read = seq_read,
-+ .write = wl_proc_write,
-+ .llseek = seq_lseek,
-+ .release = single_release,
-+};
-+#endif
-
- static int
- wl_reg_proc_entry(wl_info_t *wl)
- {
- char tmp[32];
- sprintf(tmp, "%s%d", HYBRID_PROC, wl->pub->unit);
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
- if ((wl->proc_entry = create_proc_entry(tmp, 0644, NULL)) == NULL) {
-+#else
-+ wl->proc_entry = proc_create_data(tmp, 0644, NULL, &wl_proc_fops, wl);
-+ if (!wl->proc_entry) {
-+#endif
- WL_ERROR(("%s: create_proc_entry %s failed\n", __FUNCTION__, tmp));
- ASSERT(0);
- return -1;
- }
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 10, 0)
- wl->proc_entry->read_proc = wl_proc_read;
- wl->proc_entry->write_proc = wl_proc_write;
- wl->proc_entry->data = wl;
-+#endif
- return 0;
- }
diff --git a/kernel-net-wl-linux-3.2.patch b/kernel-net-wl-linux-3.2.patch
deleted file mode 100644
index 4e1be81..0000000
--- a/kernel-net-wl-linux-3.2.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- src/wl/sys/wl_linux.c 2012-02-07 22:50:48.712066171 +0200
-+++ src/wl/sys/wl_linux.c 2012-02-07 22:52:12.108479718 +0200
-@@ -391,7 +391,7 @@
- #endif
- .ndo_get_stats = wl_get_stats,
- .ndo_set_mac_address = wl_set_mac_address,
-- .ndo_set_multicast_list = wl_set_multicast_list,
-+ .ndo_set_rx_mode = wl_set_multicast_list,
- .ndo_do_ioctl = wl_ioctl
- };
diff --git a/kernel-net-wl-linux-3.4.patch b/kernel-net-wl-linux-3.4.patch
deleted file mode 100644
index e39be98..0000000
--- a/kernel-net-wl-linux-3.4.patch
+++ /dev/null
@@ -1,12 +0,0 @@
---- src/wl/sys/wl_linux.c
-+++ src/wl/sys/wl_linux.c
-@@ -40,7 +40,9 @@
- #include <linux/pci_ids.h>
- #define WLC_MAXBSSCFG 1
-
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 4, 0)
- #include <asm/system.h>
-+#endif
- #include <asm/io.h>
- #include <asm/irq.h>
- #include <asm/pgtable.h>
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/kernel-net-wl.git/commitdiff/283219f09b729f5d234abdbdd7f91f5f5a879ced
More information about the pld-cvs-commit
mailing list