summaryrefslogtreecommitdiff
path: root/drivers/usb/musb/musb_dma.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/musb/musb_dma.h')
-rw-r--r--drivers/usb/musb/musb_dma.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/drivers/usb/musb/musb_dma.h b/drivers/usb/musb/musb_dma.h
index 916065ba9e7..a114af6c330 100644
--- a/drivers/usb/musb/musb_dma.h
+++ b/drivers/usb/musb/musb_dma.h
@@ -36,7 +36,7 @@
#define __MUSB_DMA_H__
struct musb_hw_ep;
-
+struct musb_request;
/*
* DMA Controller Abstraction
*
@@ -91,6 +91,10 @@ struct musb_hw_ep;
# endif
#endif
+#ifdef CONFIG_USB_U8500_DMA
+#undef USE_MODE1
+#endif
+
/*
* DMA channel status ... updated by the dma controller driver whenever that
* status changes, and protected by the overall controller spinlock.
@@ -155,6 +159,10 @@ dma_channel_status(struct dma_channel *c)
* @channel_release: call this to release a DMA channel
* @channel_abort: call this to abort a pending DMA transaction,
* returning it to FREE (but allocated) state
+ * @is_compatible:allow dma code to indicate incompatibility
+ * with usb request. Gadget musb driver call this api, if
+ * available, before dma mappings to avoid any unnecessary
+ * mapping operations.
*
* Controllers manage dma channels.
*/
@@ -169,6 +177,8 @@ struct dma_controller {
dma_addr_t dma_addr,
u32 length);
int (*channel_abort)(struct dma_channel *);
+ int (*is_compatible)(struct dma_channel *channel,
+ struct musb_request *);
};
/* called after channel_program(), may indicate a fault */