mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-25 16:31:13 +00:00
3c7cd63b72
Signed-off-by: Felix Fietkau <nbd@openwrt.org> SVN-Revision: 41917
49 lines
1.5 KiB
Diff
49 lines
1.5 KiB
Diff
--- a/drivers/usb/Kconfig
|
|
+++ b/drivers/usb/Kconfig
|
|
@@ -136,6 +136,8 @@ source "drivers/usb/musb/Kconfig"
|
|
|
|
source "drivers/usb/renesas_usbhs/Kconfig"
|
|
|
|
+source "drivers/usb/dwc/Kconfig"
|
|
+
|
|
source "drivers/usb/class/Kconfig"
|
|
|
|
source "drivers/usb/storage/Kconfig"
|
|
--- a/drivers/usb/core/urb.c
|
|
+++ b/drivers/usb/core/urb.c
|
|
@@ -17,7 +17,11 @@ static void urb_destroy(struct kref *kre
|
|
|
|
if (urb->transfer_flags & URB_FREE_BUFFER)
|
|
kfree(urb->transfer_buffer);
|
|
-
|
|
+ if (urb->aligned_transfer_buffer) {
|
|
+ kfree(urb->aligned_transfer_buffer);
|
|
+ urb->aligned_transfer_buffer = 0;
|
|
+ urb->aligned_transfer_dma = 0;
|
|
+ }
|
|
kfree(urb);
|
|
}
|
|
|
|
--- a/include/linux/usb.h
|
|
+++ b/include/linux/usb.h
|
|
@@ -1404,6 +1404,9 @@ struct urb {
|
|
unsigned int transfer_flags; /* (in) URB_SHORT_NOT_OK | ...*/
|
|
void *transfer_buffer; /* (in) associated data buffer */
|
|
dma_addr_t transfer_dma; /* (in) dma addr for transfer_buffer */
|
|
+ void *aligned_transfer_buffer; /* (in) associeated data buffer */
|
|
+ dma_addr_t aligned_transfer_dma;/* (in) dma addr for transfer_buffer */
|
|
+ u32 aligned_transfer_buffer_length; /* (in) data buffer length */
|
|
struct scatterlist *sg; /* (in) scatter gather buffer list */
|
|
int num_mapped_sgs; /* (internal) mapped sg entries */
|
|
int num_sgs; /* (in) number of entries in the sg list */
|
|
--- a/drivers/usb/Makefile
|
|
+++ b/drivers/usb/Makefile
|
|
@@ -7,6 +7,7 @@
|
|
obj-$(CONFIG_USB) += core/
|
|
|
|
obj-$(CONFIG_USB_DWC3) += dwc3/
|
|
+obj-$(CONFIG_USB_DWC_OTG) += dwc/
|
|
|
|
obj-$(CONFIG_USB_MON) += mon/
|
|
|