Commit 05108132 authored by Simon Glass's avatar Simon Glass
Browse files

dm: usb: Adjust usb_storage to work with sandbox



With a few tweaks we can compile this code with sandbox and enable testing
of the USB storage layer.
Signed-off-by: default avatarSimon Glass <sjg@chromium.org>
Reviewed-by: default avatarMarek Vasut <marex@denx.de>
parent 84073b6f
......@@ -34,6 +34,7 @@
#include <common.h>
#include <command.h>
#include <inttypes.h>
#include <mapmem.h>
#include <asm/byteorder.h>
#include <asm/processor.h>
......@@ -306,8 +307,9 @@ static int us_one_transfer(struct us_data *us, int pipe, char *buf, int length)
/* set up the transfer loop */
do {
/* transfer the data */
debug("Bulk xfer %p(%d) try #%d\n",
buf, this_xfer, 11 - maxtry);
debug("Bulk xfer 0x%lx(%d) try #%d\n",
(ulong)map_to_sysmem(buf), this_xfer,
11 - maxtry);
result = usb_bulk_msg(us->pusb_dev, pipe, buf,
this_xfer, &partial,
USB_CNTL_TIMEOUT * 5);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment