summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt73usb.c
diff options
context:
space:
mode:
authorIvo van Doorn <ivdoorn@gmail.com>2008-02-03 15:54:11 +0100
committerJohn W. Linville <linville@tuxdriver.com>2008-02-29 15:37:00 -0500
commit3b640f21af4b6b36b546fecbd3fe5109981360da (patch)
tree5fce049b149283f8864d60b5b265a12b08827b3f /drivers/net/wireless/rt2x00/rt73usb.c
parenta9450b70a755abf093600035ef5361c53343fe9a (diff)
downloadblackbird-op-linux-3b640f21af4b6b36b546fecbd3fe5109981360da.tar.gz
blackbird-op-linux-3b640f21af4b6b36b546fecbd3fe5109981360da.zip
rt2x00: Enable LED class support for rt2500usb/rt73usb
Add kerneldoc for vendor request functions in rt2x00usb. Add asynchroneous vendor request function in rt2x00usb. With the availability of the asynchroneuous vendor request we can now enable LED class support for rt2500usb and rt73usb. Since LED handling is not important, it doesn't really matter if a register call fails (This solution is better then no LED class support at all). Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt73usb.c')
-rw-r--r--drivers/net/wireless/rt2x00/rt73usb.c21
1 files changed, 9 insertions, 12 deletions
diff --git a/drivers/net/wireless/rt2x00/rt73usb.c b/drivers/net/wireless/rt2x00/rt73usb.c
index ca5a9855adbd..92c8f601296f 100644
--- a/drivers/net/wireless/rt2x00/rt73usb.c
+++ b/drivers/net/wireless/rt2x00/rt73usb.c
@@ -294,28 +294,25 @@ static void rt73usb_led_brightness(struct led_classdev *led_cdev,
rt2x00_set_field16(&led->rt2x00dev->led_mcu_reg,
MCU_LEDCS_RADIO_STATUS, enabled);
- rt2x00usb_vendor_request_sw(led->rt2x00dev, USB_LED_CONTROL, 0,
- led->rt2x00dev->led_mcu_reg,
- REGISTER_TIMEOUT);
+ rt2x00usb_vendor_request_async(led->rt2x00dev, USB_LED_CONTROL,
+ 0, led->rt2x00dev->led_mcu_reg);
} else if (led->type == LED_TYPE_ASSOC) {
rt2x00_set_field16(&led->rt2x00dev->led_mcu_reg,
MCU_LEDCS_LINK_BG_STATUS, bg_mode);
rt2x00_set_field16(&led->rt2x00dev->led_mcu_reg,
MCU_LEDCS_LINK_A_STATUS, a_mode);
- rt2x00usb_vendor_request_sw(led->rt2x00dev, USB_LED_CONTROL, 0,
- led->rt2x00dev->led_mcu_reg,
- REGISTER_TIMEOUT);
+ rt2x00usb_vendor_request_async(led->rt2x00dev, USB_LED_CONTROL,
+ 0, led->rt2x00dev->led_mcu_reg);
} else if (led->type == LED_TYPE_QUALITY) {
/*
* The brightness is divided into 6 levels (0 - 5),
* this means we need to convert the brightness
* argument into the matching level within that range.
*/
- rt2x00usb_vendor_request_sw(led->rt2x00dev, USB_LED_CONTROL,
- brightness / (LED_FULL / 6),
- led->rt2x00dev->led_mcu_reg,
- REGISTER_TIMEOUT);
+ rt2x00usb_vendor_request_async(led->rt2x00dev, USB_LED_CONTROL,
+ brightness / (LED_FULL / 6),
+ led->rt2x00dev->led_mcu_reg);
}
}
#else
@@ -871,7 +868,7 @@ static int rt73usb_load_firmware(struct rt2x00_dev *rt2x00dev, void *data,
rt2x00usb_vendor_request(rt2x00dev, USB_MULTI_WRITE,
USB_VENDOR_REQUEST_OUT,
- FIRMWARE_IMAGE_BASE + i, 0x0000,
+ FIRMWARE_IMAGE_BASE + i, 0,
cache, buflen, timeout);
ptr += buflen;
@@ -884,7 +881,7 @@ static int rt73usb_load_firmware(struct rt2x00_dev *rt2x00dev, void *data,
* we need to specify a long timeout time.
*/
status = rt2x00usb_vendor_request_sw(rt2x00dev, USB_DEVICE_MODE,
- 0x0000, USB_MODE_FIRMWARE,
+ 0, USB_MODE_FIRMWARE,
REGISTER_TIMEOUT_FIRMWARE);
if (status < 0) {
ERROR(rt2x00dev, "Failed to write Firmware to device.\n");
OpenPOWER on IntegriCloud