USB Host Controller Access to System Memory
14-87
Universal Serial Bus Host
14.6.3.5
PAtoLBVA()—Physical Address to Local Bus Virtual Address Conversion Function
This function is a reverse version of the local bus virtual address to physical
address conversion function. It accepts a processor physical address as its
argument and returns the equivalent local bus virtual address.
It is possible to program the local bus MMU to allow two (or more) different local
bus virtual addresses to map to the same physical address. System software
implementers must be careful to avoid that situation.
It is advisable to implement a checking function in this routine that verifies that
the resulting local bus virtual address is in the usable local bus virtual address
range of 0x30000000 to 0x3FFFFFFF. If the USB host controller attempts to
access a local bus virtual address outside of the valid range, an OHCI unrecov-
erable error occurs if the USB host controller local bus time-out feature is
enabled. If the time-out feature is disabled and the USB host controller
attempts an access outside of the valid range, the USB host controller local
bus interface locks up and the USB host controller is not able to access the
system memory data structures needed to issue USB packets.
14.6.3.6
PAtoMPUVA()—Physical Address to MPU Virtual Address Conversion Function
This function is a reverse version of the MPU virtual address to physical
address conversion. It accepts a physical address as an argument and returns
the equivalent MPU virtual address.
It is possible to program the MPU MMU to allow two (or more) different MPU
virtual addresses to map to the same physical address. This is especially
common in systems that use linear addressing within a task. System software
implementers must be careful to avoid that situation or to perform the conver-
sion in a way that understands the task-specific conversion requirements.
14.6.3.7
Physical, MPU Virtual, and Local Bus Virtual Addresses—an Example
An example helps show the requirements. Consider a system where the MPU
places the HCCA and ED and TD lists in SRAM on OMAP5910 CS0 and where
the USB data buffers are in external SDRAM. The MPU MMU is set up, in part,
as shown in Table 14–31.
Table 14–31. MPU MMU Programming for Address Conversion Example
MPU Virtual Address
Physical Address
Page Size
0x00000000 to 0x000000FFF
0x0005E000 to 0x0005EFFF
Small (4K bytes)
0x00010000 to 0x0001FFFF
0x10170000 to 0x1017FFFF
Large (64K bytes)