aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/storage/usb.c8
-rw-r--r--drivers/usb/storage/usb.h1
2 files changed, 0 insertions, 9 deletions
diff --git a/drivers/usb/storage/usb.c b/drivers/usb/storage/usb.c
index eb1a53a3e5ca..099e07c6af7b 100644
--- a/drivers/usb/storage/usb.c
+++ b/drivers/usb/storage/usb.c
@@ -474,12 +474,6 @@ static int associate_dev(struct us_data *us, struct usb_interface *intf)
474 US_DEBUGP("I/O buffer allocation failed\n"); 474 US_DEBUGP("I/O buffer allocation failed\n");
475 return -ENOMEM; 475 return -ENOMEM;
476 } 476 }
477
478 us->sensebuf = kmalloc(US_SENSE_SIZE, GFP_KERNEL);
479 if (!us->sensebuf) {
480 US_DEBUGP("Sense buffer allocation failed\n");
481 return -ENOMEM;
482 }
483 return 0; 477 return 0;
484} 478}
485 479
@@ -875,8 +869,6 @@ static void dissociate_dev(struct us_data *us)
875{ 869{
876 US_DEBUGP("-- %s\n", __func__); 870 US_DEBUGP("-- %s\n", __func__);
877 871
878 kfree(us->sensebuf);
879
880 /* Free the device-related DMA-mapped buffers */ 872 /* Free the device-related DMA-mapped buffers */
881 if (us->cr) 873 if (us->cr)
882 usb_buffer_free(us->pusb_dev, sizeof(*us->cr), us->cr, 874 usb_buffer_free(us->pusb_dev, sizeof(*us->cr), us->cr,
diff --git a/drivers/usb/storage/usb.h b/drivers/usb/storage/usb.h
index a4ad73bd832d..e4674fc715e6 100644
--- a/drivers/usb/storage/usb.h
+++ b/drivers/usb/storage/usb.h
@@ -138,7 +138,6 @@ struct us_data {
138 struct usb_ctrlrequest *cr; /* control requests */ 138 struct usb_ctrlrequest *cr; /* control requests */
139 struct usb_sg_request current_sg; /* scatter-gather req. */ 139 struct usb_sg_request current_sg; /* scatter-gather req. */
140 unsigned char *iobuf; /* I/O buffer */ 140 unsigned char *iobuf; /* I/O buffer */
141 unsigned char *sensebuf; /* sense data buffer */
142 dma_addr_t cr_dma; /* buffer DMA addresses */ 141 dma_addr_t cr_dma; /* buffer DMA addresses */
143 dma_addr_t iobuf_dma; 142 dma_addr_t iobuf_dma;
144 struct task_struct *ctl_thread; /* the control thread */ 143 struct task_struct *ctl_thread; /* the control thread */