1
0
Fork 0
Commit Graph

61 Commits (redonkable)

Author SHA1 Message Date
Rustam Kovhaev af707d9d7f staging: rtl8712: handle firmware load failure
commit b4383c971b upstream.

when firmware fails to load we should not call unregister_netdev()
this patch fixes a race condition between rtl871x_load_fw_cb() and
r871xu_dev_remove() and fixes the bug reported by syzbot

Reported-by: syzbot+80899a8a8efe8968cde7@syzkaller.appspotmail.com
Link: https://syzkaller.appspot.com/bug?extid=80899a8a8efe8968cde7
Signed-off-by: Rustam Kovhaev <rkovhaev@gmail.com>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20200716151324.1036204-1-rkovhaev@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-08-11 15:33:34 +02:00
Johan Hovold 601dc85996 staging: rtl8712: fix interface sanity check
commit c724f776f0 upstream.

Make sure to use the current alternate setting when verifying the
interface descriptors to avoid binding to an invalid interface.

Failing to do so could cause the driver to misbehave or trigger a WARN()
in usb_submit_urb() that kernels with panic_on_warn set would choke on.

Fixes: 2865d42c78 ("staging: r8712u: Add the new driver to the mainline kernel")
Cc: stable <stable@vger.kernel.org>     # 2.6.37
Signed-off-by: Johan Hovold <johan@kernel.org>
Link: https://lore.kernel.org/r/20191210114751.5119-3-johan@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-12-17 19:55:34 +01:00
Nishka Dasgupta 690407fdc9 staging: rtl8712: init_drv_sw(): Change return values
Change return values of init_drv_sw from _SUCCESS and _FAIL to 0 and
-ENOMEM. Change return type from u8 to int to allow this.
Add a return variable to streamline return of error codes of called
functions.
Modify call site to check for non-zero return value instead of _FAIL.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Link: https://lore.kernel.org/r/20190808064012.12661-7-nishkadg.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-08 19:58:15 +02:00
Deepak Mishra 6cc6677aee staging: rtl8712: Fixed CamelCase lockRxFF0Filter renamed to lock_rx_ff0_filter
In process of cleaning up struct _adapter in drv_types.h, lockRxFF0Filter
 is renamed to to lock_rx_ff0_filter to fix a checkpatch reported issue.

Signed-off-by: Deepak Mishra <linux.dkm@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-06-13 11:52:39 +02:00
Deepak Mishra 906ad742fd staging: rtl8712: Fixed CamelCase for EepromAddressSize
This patch renames CamelCase EepromAddressSizefrom to eeprom_address_size in
struct _adapter and in related files drv_types.h, rtl871x_eeprom.c, usb_intf.c

This was reported by checkpatch.pl

Signed-off-by: Deepak Mishra <linux.dkm@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-06-10 17:57:21 +02:00
Himadri Pandya 7e5173822c staging: rtl8712: rename bSuspended to suspended
- Rename structure field bSuspended to suspended to avoid camelcase.
Suggested by checkpatch.
 - Change type to bool as the variable is used as a boolean.

Signed-off-by: Himadri Pandya <himadri18.07@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-03-18 07:05:18 +01:00
Himadri Pandya 5b8d98f171 staging: rtl8712: rename bSurpriseRemoved to surprise_removed
- Rename structure field bSurprisedRemoved to surprised_removed to avoid
camelcase. Suggested by checkpatch.
 - Change type to bool as the variable is used as a boolean.

Signed-off-by: Himadri Pandya <himadri18.07@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-03-18 07:05:18 +01:00
Himadri Pandya 0ec6fc6f45 staging: rtl8712: rename bDriverStopped to driver_stopped
- Rename structure field bDriverStopped to driver_stopped to avoid
camelcase. Suggested by checkpatch.
 - Change type to bool as the variable is being used as boolean.

Signed-off-by: Himadri Pandya <himadri18.07@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-03-18 07:05:18 +01:00
Kai-Heng Feng ac544a459a staging: rtl8712u: Fix suspend and resume callbacks
When system resume and the rtl8712u dongle didn't lose its power, it
doesn't work quite right:
[  146.844241] r8712u 2-3:1.0 wlp0s4f1u3: Unable to resume
...
[  154.029573] r8712u 2-3:1.0 wlp0s4f1u3: In r8711_wx_set_scan: bDriverStopped=1

The !netif_running() check in PM callbacks aren't correct because
rtl8712u doesn't support runtime suspend, so the when the PM ops get
called, it's system suspend or system resume, hence we want to "stop
everthing" or "resume everything".

The NULL check on pnetdev is also redundant, the only place pnetdev can
become NULL is the disconnect callback, which is mutually exclusive to
PM callbacks.

This can make rtl8712u starts working after system resume.

Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-15 16:11:50 +01:00
Kai-Heng Feng 2b2bbb561f staging: rtl8712u: Remove dummy reset-resume callback
An USB wireless dongle uses rtl8712u stops working after system
suspend/resume.

When a USB device lost its power during suspend, the USB core knows the
power was lost and a reset-resume or a re-probe is required. But rtl8712u
provides a dummy reset-resume callback, which gets called and renders
the device dead after resume.

So remove the reset-resume call back, if power was lost during suspend,
let the USB core unbind and probe the device to solve the issue.

Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-01-15 16:11:50 +01:00
Michael Straube e24c1f8658 staging: rtl8712: add SPDX identifiers
This satisfies a checkpatch warning and is the preferred
method for notating the license.

The SPDX identifier is a legally binding shorthand, which
can be used instead of the full boiler plate text.

Signed-off-by: Michael Straube <straube.linux@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-10-03 11:36:09 -07:00
Liam Ryan a7e585918e staging: rtl8712: Fix unbalanced braces around else statement
Fix checkpath-reported unbalanced braces in the following areas

221: FILE: drivers/staging/rtl8712/hal_init.c:221:
392: FILE: drivers/staging/rtl8712/os_intfs.c:392:
363: FILE: drivers/staging/rtl8712/rtl8712_cmd.c:363:
889: FILE: drivers/staging/rtl8712/rtl8712_recv.c:889:
902: FILE: drivers/staging/rtl8712/rtl871x_cmd.c:902:
84: FILE: drivers/staging/rtl8712/rtl871x_ioctl_set.c:84:
580: FILE: drivers/staging/rtl8712/rtl871x_mlme.c:580:
593: FILE: drivers/staging/rtl8712/usb_intf.c:593:

Signed-off-by: Liam Ryan <liamryandev@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-09-17 16:35:27 +02:00
Arvind Yadav 9b40a01738 staging: rtl8712: constify usb_device_id
usb_device_id are not supposed to change at runtime. All functions
working with usb_device_id provided by <linux/usb.h> work with
const usb_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-08-18 15:57:16 -07:00
Gonçalo Salazar 1140c8a61a staging: rtl8172: usb_intf.c: Fixed block comment coding style
Fixed a block comment indentation in the rtl8712 usb_intf.c file.

Signed-off-by: Gonçalo Salazar <glbsalazar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-09-26 22:22:13 +02:00
Raphaël Beamonte bef611a92e staging: rtl8712: checkpatch cleanup: block comments using a trailing */
Fix checkpatch.pl warning "Block comments use a trailing */ on
a separate line" on multiple files of the driver by editing the
affected comments.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-09-12 11:43:52 +02:00
Amitoj Kaur Chawla ecf2e02cd4 staging: rtl8712: Remove exceptional & on function name
Remove exceptional '&' operator in front of a function name.

The Coccinelle semantic patch that is used to make this change is as
follows:

// <smpl>
@r@
identifier f;
@@
f(...) { ... }
@@
identifier r.f;
@@
- &f
+ f
@m@
type T;
identifier f;
@@
T f(...);
@@
identifier m.f;
@@
- &f
+ f
// </smpl>

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-03-11 22:09:09 -08:00
Amitoj Kaur Chawla f99ca86646 staging: rtl8712: Declare function as static
Declare rtl871x_intf_resume() function static since it is defined and called
in this file only.

This fixes the following sparse warning:
warning: symbol 'rtl871x_intf_resume' was not declared. Should it be static?

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-20 15:18:33 -08:00
Hemmo Nieminen 39e9526cec staging: rtl8712: Improve suspend/resume functionality.
Cancel pending URBs during suspend operation to avoid receiving ESHUTDOWN
in read/write completion callbacks while the device is suspended.

Receiving ESHUTDOWN in read/write completion callbacks will cause the
driver to enter a non-functioning "stopped" state from which the driver is
unable to recover without reloading the module.

Signed-off-by: Hemmo Nieminen <hemmo.nieminen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-07 19:52:30 -08:00
Luis de Bethencourt 4ef2de5ae0 staging: rtl8712: spaces preferred around operands
Clean up all instances of checkpatch.pl checks:
CHECK: spaces preferred around that '+'
(and other operands)

Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24 19:26:59 -07:00
Luis de Bethencourt 168a2c1028 staging: rtl8712: braces should be used on all arms
Fix all instances of the following checkpatch.pl check:
CHECK: braces {} should be used on all arms of this statement

Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24 19:26:59 -07:00
Luis de Bethencourt 1ca96884b1 staging: rtl8712: Remove boolean comparisons
Boolean tests do not need explicit comparison to true or false.

Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24 19:26:59 -07:00
Larry Finger 1e6e632836 staging: rtl8712: Add device ID for Sitecom WLA2100
This adds the USB ID for the Sitecom WLA2100. The Windows 10 inf file
was checked to verify that the addition is correct.

Reported-by: Frans van de Wiel <fvdw@fvdw.eu>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Frans van de Wiel <fvdw@fvdw.eu>
Cc: Stable <stable@vger.kernel.org> [All stable versions]
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-24 19:12:48 -07:00
Shraddha Barke eef6c808d3 Staging: rtl8712: Use ARRAY_SIZE macro
ARRAY_SIZE is more concise to use when the size of an array is divided
by the size of its type

Changes made using Coccinelle-

@@
type T;
T[] E;
@@

- (sizeof(E)/sizeof(T))
+ ARRAY_SIZE(E)

Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-12 20:43:20 -07:00
Heba Aamer 36e4d8826b staging: rtl8712: fix Prefer ether_addr_copy() over memcpy()
This patch fixes the following checkpatch.pl warning:
Prefer ether_addr_copy() over memcpy()
if the Ethernet addresses are __aligned(2)

pahole showed that the struct used pnetdev->dev_addr
is aligned to u16.

Moreover mac is a simple array, pdata is a pointer that
starts from an even offset.

Signed-off-by: Heba Aamer <heba93aamer@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-02-07 17:15:43 +08:00
Heba Aamer 1007c69226 staging: rtl8712: remove useless printing line
This patch removes an unneeded call to printk.

Signed-off-by: Heba Aamer <heba93aamer@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-28 10:56:49 -08:00
Sudip Mukherjee e29d3ebcda staging: rtl8712: remove unused variables
unused variables are removed. These variables were only assigned some
values and after that they were never being used. So they are safe to
be removed , and it has been build tested.

I left a call to r8712_read32(padapter, TCR) and
r8712_read8(padapter, SDIO_HCPWM) .

r8712_read32() and r8712_read8() is ultimately calling usb_read32()
and usb_read8() respectively. and they are again calling
r8712_usbctrl_vendorreq().
this r8712_usbctrl_vendorreq() is communicating through the usb bus
and is sending and receiving the control msg.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-10-29 17:37:26 +08:00
Tapasweni Pathak 366ba42703 staging: rtl8712: Delete explicit comparison with false and NULL
This patch delete explicit comparison to false and NULL in files of
rtl8712.

Signed-off-by: Tapasweni Pathak <tapaswenipathak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-10-20 10:29:11 +08:00
Tapasweni Pathak 57b6686ebb Staging: rtl8712 : Fix line over 80 characters
This patch fixes checkpatch.pl warning in files of rtl8712
WARNING : line over 80 characters

Signed-off-by: Tapasweni Pathak <tapaswenipathak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-09-23 08:14:36 -07:00
Tapasweni Pathak fbdba9c10b Staging: rtl8712: remove void function return; statement
This patch fixes checkpatch.pl warning in files of rtl8712
WARNING : void function return statement are not generally useful

Signed-off-by: Tapasweni Pathak <tapaswenipathak@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-09-23 08:04:57 -07:00
Thomas Vegas 22649bb2b6 staging: rtl8712: Remove useless variable 'fw_found'
The net device only exists when firmware is loaded successfully.
Firmware presence variable is only used through r871xu_dev_remove() and
this function already checks for net device existence.

Signed-off-by: Thomas Vegas <thomas@grouk.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-19 16:40:07 -07:00
Thomas Vegas 5947956bdc staging: rtl8712: Fix oops on dongle removal if firmware is not available
When firmware is not available, net device is not created. Upon
disconnect, we must check for net device existence before trying to
release net device private data.

Signed-off-by: Thomas Vegas <thomas@grouk.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-06-19 16:40:07 -07:00
Rickard Strandqvist ac082bc52d staging: rtl8712: usb_intf.c: Fix for possible null pointer dereference
There is otherwise a risk of a possible null pointer dereference.

Was largely found by using a static code analysis program called cppcheck.

Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 01:58:22 +09:00
Larry Finger 3a21f00a50 staging: r8712u: Set device type to wlan
The latest version of NetworkManager does not recognize the device as wireless
without this change.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-01-09 10:35:25 -08:00
Andy Shevchenko 30765436fd staging: rtl8712: re-use native mac_pton() helper
There is a nice helper to parse MAC. Let's use it and remove custom
implementation.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-09-17 07:47:46 -07:00
Przemo Firszt 87a573ada0 rtl8712: replace printk with better solutions
Replace printk with netdev_printk helpers, dev_printk helpers or
pr_err/warn/info if there is no device info available.

Signed-off-by: Przemo Firszt <przemo@firszt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-11 16:39:11 -08:00
Larry Finger da849a92d3 staging: r8712u: Add new device ID
The ISY IWL 1000 USB WLAN stick with USB ID 050d:11f1 is a clone of
the Belkin F7D1101 V1 device.

Reported-by: Thomas Hartmann <hartmann@ict.tuwien.ac.at>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Thomas Hartmann <hartmann@ict.tuwien.ac.at>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-01-07 09:50:40 -08:00
Larry Finger 73ee07faee staging: r8712u: Remove defines that are not used
This driver has a number of defines, etc. that are not used.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-09-04 14:14:08 -07:00
Greg Kroah-Hartman bcc66c0b88 Merge 3.5-rc4 into staging-next
This picks up the staging changes made in 3.5-rc4 so that everyone can sync up
properly.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-06-25 09:31:00 -07:00
Larry Finger 1c1b862157 staging: r8712u: Remove useless driver version info
This driver contains version information that is outdated, has no real
value in terms of the Linux update process, and tends to confuse users.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-06-22 21:24:49 -07:00
Lubomir Schmidt 3026b0e942 staging: r8712u: Add new USB IDs
There are two new devices for this driver.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-06-15 14:50:04 -07:00
Larry Finger 1d73fad833 staging: r8712u: Remove needless test for NULL
In commit ee6aeff, a swatch warning was fixed by moving some code inside
an if block that is executed only when the pointer padapter is not NULL.
In fact, padapter can never be NULL and the corect fix should have been
the removal of the test of padapter.

Reported-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-14 13:27:24 -07:00
Justin P. Mattock be10ac2b96 staging: rtl8712: Fix typos.
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-05-09 13:46:01 -07:00
Larry Finger ee6aeff71e staging: r8712u: Fix Smatch warning
The patch 2080913e017a: "staging: r8712u: Fix regression caused by
commit 8c213fa" from Feb 25, 2012, leads to the following Smatch
complaint:

drivers/staging/rtl8712/usb_intf.c:629 r871xu_dev_remove()
	 warn: variable dereferenced before check 'padapter' (see line 625)

The fix is to move the new statements inside the block where padapter
is not NULL.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-07 13:36:45 -08:00
Martin Krause 07b99cf55c Staging: rtl8712/rtl8192u: move USB device ID within staging drivers.
It seems the USB device ID 0bda:8192 is wrongly assigned to the
RTL8192SU chip and not to the RTL8191SU chip in the USB database.
So this patch moves this device ID from the rtl8192u staging
driver to the rtl8712 staging driver.

This patch was tested with a Radicom WIFIHU embedded wireless
module with a RTL8191SU chip and the USB device ID 0bda:8192.
Without the patch the rtl8192u driver claims this device, but
it does not work. With the patch the rtl8712 driver services
this device and it works.

Signed-off-by: Martin Krause <martin.krause@tqs.de>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-02 16:36:38 -08:00
Martin Krause 534717020e Staging rtl8712: Remove double USB device IDs
Remove copies of the double USB device IDs:

- 0bda:8172
- 0bda:8174

Signed-off-by: Martin Krause <martin.krause@tqs.de>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-03-02 16:36:38 -08:00
Larry Finger 2080913e01 staging: r8712u: Fix regression caused by commit 8c213fa
In commit 8c213fa "staging: r8712u: Use asynchronous firmware loading",
the command to release the firmware was placed in the wrong routine.

In combination with the bug introduced in commit a5ee652 "staging: r8712u:
Interface-state not fully tracked", the driver attempts to upload firmware
that had already been released. This bug is the source of one of the
problems in https://bugs.archlinux.org/task/27996#comment89833.

Tested-by: Alberto Lago Ballesteros <saniukeokusainaya@gmail.com>
Tested-by: Adrian <agib@gmx.de>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-29 16:28:51 -08:00
Greg Kroah-Hartman b91867f2ee Merge tag 'staging-3.3-rc3' into staging-next
This was done to resolve some merge issues with the following files that
had changed in both branches:
	drivers/staging/rtl8712/rtl871x_sta_mgt.c
	drivers/staging/tidspbridge/rmgr/drv_interface.c
	drivers/staging/zcache/zcache-main.c

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-10 10:58:25 -08:00
Larry Finger 86587b671b staging: r8712u: Simplify semaphores
I am preparing to convert this driver from semaphore to mutex locking,
The first step has been to eliminate a number of semaphores that were
initialized but never used, and one whose only use was a single "up"
after initialization. A total of 9 semaphores were removed in this process.

One other change was to remove some inline semaphore routines that were
unused.

In addition, several cases had the following structure:

down()
if () {
   ...
}
up()

The locking overhead was reduced by moving the up/down inside the if
block.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-09 09:12:55 -08:00
Larry Finger 8c213fa591 staging: r8712u: Use asynchronous firmware loading
In https://bugs.archlinux.org/task/27996, failure of driver r8712u is
reported, with a timeout during module loading due to synchronous loading
of the firmware. The code now uses request_firmware_nowait().

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2012-02-08 14:14:15 -08:00
Larry Finger 1793bf1ded staging: r8712u: Add new Sitecom UsB ID
Add USB ID for SITECOM WLA-1000 V1 001 WLAN

Reported-and-tested-by: Roland Gruber <post@rolandgruber.de>
Reported-and-tested-by: Dario Lucia <dario.lucia@gmail.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2012-02-08 14:14:12 -08:00