Hi Bin,
Hi Nicolas,
On 20.11.20 01:31, Bin Meng wrote:
+Stefan
On Fri, Nov 20, 2020 at 1:49 AM Nicolas Saenz Julienne
<nsaenzjulie...@suse.de> wrote:
So far we've been content with passing physical addresses when
configuring memory addresses into XHCI controllers, but not all
platforms have buses with transparent mappings. Specifically the
Raspberry Pi 4 might introduce an offset to memory accesses incoming
from its PCIe port.
Introduce xhci_virt_to_bus() and xhci_bus_to_virt() to cater with these
limitations and make sure we don't break non DM users.
I believe this was already addressed by Stefan before, to support xHCI in MIPS.
I believe from taking a quick look at the code, that Nicolas not only
needs to transfer between phys and virt addresses, but also needs to
support different "offsets" on multiple devices. IIUTC, it's an
extension to the already available support for mapped addresses (virtual
!= physical).
BTW: Do we really need to support non-DM code with this new approach in
this late phase of DM conversion?
Thanks,
Stefan
Signed-off-by: Nicolas Saenz Julienne <nsaenzjulie...@suse.de>
---
drivers/usb/host/xhci-mem.c | 45 +++++++++++++++++++-----------------
drivers/usb/host/xhci-ring.c | 11 +++++----
drivers/usb/host/xhci.c | 4 ++--
include/usb/xhci.h | 22 +++++++++++++++++-
4 files changed, 54 insertions(+), 28 deletions(-)
Regards,
Bin
Viele Grüße,
Stefan
--
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: s...@denx.de