usb: gadget: tegra: Add AHB prefetch buffer with IOMMU
authorHiroshi Doyu <hdoyu@nvidia.com>
Thu, 11 Oct 2012 09:02:30 +0000 (12:02 +0300)
committerMrutyunjay Sawant <msawant@nvidia.com>
Fri, 19 Oct 2012 13:49:14 +0000 (06:49 -0700)
commit5d3cbff77ff60fa7edc30b8d2033b91ceeaa2606
tree1995a795395c4773c695077204de0bb5fc7e7d23
parent732e2502a3bcffb13d8a708e6c6f4c7c8a12c20d
usb: gadget: tegra: Add AHB prefetch buffer with IOMMU

With PLATFORM_ENABLE_IOMMU, IOMMU'able devices need to work with
IOMMU, where only IOMMU mapped pages are valid. AHB prefetcher for USB
tried to access(read) beyond IOMMU mapped range. To avoid unnecessary
DECERR from IOMMU(SMMU), 128 bytes are appended at the end of USB
buffers at dma_{map,unmap}_single() but cache maint is done with the
original size.

Bug 1049290

Change-Id: I5646c83541eac263f9180bc6ae64e05d1e7c8a51
Signed-off-by: Hiroshi Doyu <hdoyu@nvidia.com>
Reviewed-on: http://git-master/r/143531
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Rakesh Bodla <rbodla@nvidia.com>
Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
drivers/usb/gadget/tegra_udc.c