summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorLi Jun <jun.li@freescale.com>2015-11-23 15:44:31 +0800
committerNitin Garg <nitin.garg@nxp.com>2016-01-14 11:02:23 -0600
commit6ca8fd86e7974e3f96ec7ad9852e6ba41736af15 (patch)
tree68fa1796c9deeb9ea88f312e10e5a6ab009e8de4 /include
parent0b205e36656552e477d0968ca7f95412ff64ea2e (diff)
MLK-11891-1 usb: otg-fsm: allocate DMA buffer for host request flag separately
HNP polling need a one byte buffer for usb control transfer via DMA read, currently using a data field in a structure for DMA buffer may cause cache incoherent issue, because the cache line for the DMA buffer also contains other data in this structure, while dma from device is outstanding, the access on other data in the same cache line will cause we get the old data before DMA. This patch change the host_request_flag to be a pointer, its memory will be allocated through kmalloc by controller driver, with this way, the DMA buffer can be properly aligned and padded. Signed-off-by: Li Jun <jun.li@freescale.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/usb/otg-fsm.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/usb/otg-fsm.h b/include/linux/usb/otg-fsm.h
index 89cce2362415..aa5ba16c3d42 100644
--- a/include/linux/usb/otg-fsm.h
+++ b/include/linux/usb/otg-fsm.h
@@ -140,7 +140,7 @@ struct otg_fsm {
/* Current usb protocol used: 0:undefine; 1:host; 2:client */
int protocol;
struct mutex lock;
- u8 host_req_flag;
+ u8 *host_req_flag;
};
struct otg_fsm_ops {