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.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00usb.c b/drivers/net/wireless/rt2x00/rt2x00usb.c
index 44ab2167c6ee..4219057d85cb 100644
--- a/drivers/net/wireless/rt2x00/rt2x00usb.c
+++ b/drivers/net/wireless/rt2x00/rt2x00usb.c
@@ -84,20 +84,20 @@ int rt2x00usb_vendor_req_buff_lock(struct rt2x00_dev *rt2x00dev,
84 /* 84 /*
85 * Check for Cache availability. 85 * Check for Cache availability.
86 */ 86 */
87 if (unlikely(!rt2x00dev->csr_cache || buffer_length > CSR_CACHE_SIZE)) { 87 if (unlikely(!rt2x00dev->csr.cache || buffer_length > CSR_CACHE_SIZE)) {
88 ERROR(rt2x00dev, "CSR cache not available.\n"); 88 ERROR(rt2x00dev, "CSR cache not available.\n");
89 return -ENOMEM; 89 return -ENOMEM;
90 } 90 }
91 91
92 if (requesttype == USB_VENDOR_REQUEST_OUT) 92 if (requesttype == USB_VENDOR_REQUEST_OUT)
93 memcpy(rt2x00dev->csr_cache, buffer, buffer_length); 93 memcpy(rt2x00dev->csr.cache, buffer, buffer_length);
94 94
95 status = rt2x00usb_vendor_request(rt2x00dev, request, requesttype, 95 status = rt2x00usb_vendor_request(rt2x00dev, request, requesttype,
96 offset, 0, rt2x00dev->csr_cache, 96 offset, 0, rt2x00dev->csr.cache,
97 buffer_length, timeout); 97 buffer_length, timeout);
98 98
99 if (!status && requesttype == USB_VENDOR_REQUEST_IN) 99 if (!status && requesttype == USB_VENDOR_REQUEST_IN)
100 memcpy(buffer, rt2x00dev->csr_cache, buffer_length); 100 memcpy(buffer, rt2x00dev->csr.cache, buffer_length);
101 101
102 return status; 102 return status;
103} 103}
@@ -562,14 +562,14 @@ static void rt2x00usb_free_reg(struct rt2x00_dev *rt2x00dev)
562 kfree(rt2x00dev->eeprom); 562 kfree(rt2x00dev->eeprom);
563 rt2x00dev->eeprom = NULL; 563 rt2x00dev->eeprom = NULL;
564 564
565 kfree(rt2x00dev->csr_cache); 565 kfree(rt2x00dev->csr.cache);
566 rt2x00dev->csr_cache = NULL; 566 rt2x00dev->csr.cache = NULL;
567} 567}
568 568
569static int rt2x00usb_alloc_reg(struct rt2x00_dev *rt2x00dev) 569static int rt2x00usb_alloc_reg(struct rt2x00_dev *rt2x00dev)
570{ 570{
571 rt2x00dev->csr_cache = kzalloc(CSR_CACHE_SIZE, GFP_KERNEL); 571 rt2x00dev->csr.cache = kzalloc(CSR_CACHE_SIZE, GFP_KERNEL);
572 if (!rt2x00dev->csr_cache) 572 if (!rt2x00dev->csr.cache)
573 goto exit; 573 goto exit;
574 574
575 rt2x00dev->eeprom = kzalloc(rt2x00dev->ops->eeprom_size, GFP_KERNEL); 575 rt2x00dev->eeprom = kzalloc(rt2x00dev->ops->eeprom_size, GFP_KERNEL);