aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2x00usb.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00usb.c')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00usb.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00usb.c b/drivers/net/wireless/rt2x00/rt2x00usb.c
index 3080969ae5b3..f91901ffda5b 100644
--- a/drivers/net/wireless/rt2x00/rt2x00usb.c
+++ b/drivers/net/wireless/rt2x00/rt2x00usb.c
@@ -40,7 +40,8 @@ int rt2x00usb_vendor_request(struct rt2x00_dev *rt2x00dev,
40 void *buffer, const u16 buffer_length, 40 void *buffer, const u16 buffer_length,
41 const int timeout) 41 const int timeout)
42{ 42{
43 struct usb_device *usb_dev = rt2x00dev_usb_dev(rt2x00dev); 43 struct usb_device *usb_dev =
44 interface_to_usbdev(to_usb_interface(rt2x00dev->dev));
44 int status; 45 int status;
45 unsigned int i; 46 unsigned int i;
46 unsigned int pipe = 47 unsigned int pipe =
@@ -176,7 +177,8 @@ static void rt2x00usb_interrupt_txdone(struct urb *urb)
176int rt2x00usb_write_tx_data(struct queue_entry *entry) 177int rt2x00usb_write_tx_data(struct queue_entry *entry)
177{ 178{
178 struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev; 179 struct rt2x00_dev *rt2x00dev = entry->queue->rt2x00dev;
179 struct usb_device *usb_dev = rt2x00dev_usb_dev(rt2x00dev); 180 struct usb_device *usb_dev =
181 interface_to_usbdev(to_usb_interface(rt2x00dev->dev));
180 struct queue_entry_priv_usb *entry_priv = entry->priv_data; 182 struct queue_entry_priv_usb *entry_priv = entry->priv_data;
181 struct skb_frame_desc *skbdesc; 183 struct skb_frame_desc *skbdesc;
182 u32 length; 184 u32 length;
@@ -364,7 +366,8 @@ EXPORT_SYMBOL_GPL(rt2x00usb_disable_radio);
364void rt2x00usb_init_rxentry(struct rt2x00_dev *rt2x00dev, 366void rt2x00usb_init_rxentry(struct rt2x00_dev *rt2x00dev,
365 struct queue_entry *entry) 367 struct queue_entry *entry)
366{ 368{
367 struct usb_device *usb_dev = rt2x00dev_usb_dev(rt2x00dev); 369 struct usb_device *usb_dev =
370 interface_to_usbdev(to_usb_interface(rt2x00dev->dev));
368 struct queue_entry_priv_usb *entry_priv = entry->priv_data; 371 struct queue_entry_priv_usb *entry_priv = entry->priv_data;
369 372
370 usb_fill_bulk_urb(entry_priv->urb, usb_dev, 373 usb_fill_bulk_urb(entry_priv->urb, usb_dev,
@@ -558,7 +561,7 @@ int rt2x00usb_probe(struct usb_interface *usb_intf,
558 usb_set_intfdata(usb_intf, hw); 561 usb_set_intfdata(usb_intf, hw);
559 562
560 rt2x00dev = hw->priv; 563 rt2x00dev = hw->priv;
561 rt2x00dev->dev = usb_intf; 564 rt2x00dev->dev = &usb_intf->dev;
562 rt2x00dev->ops = ops; 565 rt2x00dev->ops = ops;
563 rt2x00dev->hw = hw; 566 rt2x00dev->hw = hw;
564 mutex_init(&rt2x00dev->usb_cache_mutex); 567 mutex_init(&rt2x00dev->usb_cache_mutex);