aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Rigby <john.rigby@linaro.org>2012-05-02 15:31:30 -0600
committerJohn Rigby <john.rigby@linaro.org>2012-05-02 19:44:13 -0600
commitc4a60b0558e41c9ed5801b02ff6dfc3e6daff76a (patch)
treea05daa01bf7a8951a070309e752e14cd857eda34
parenteb64555ff3e23b1d88d2fbac3ee64f562c343053 (diff)
downloadu-boot-linaro-stable-c4a60b0558e41c9ed5801b02ff6dfc3e6daff76a.tar.gz
dsuboot: fix warnings
Fix warnings introduced by OMAP4: Panda: Add usb peripheral boot Signed-off-by: John Rigby <john.rigby@linaro.org>
-rw-r--r--drivers/usb/gadget/core.c3
-rw-r--r--drivers/usb/gadget/dsuboot.c12
2 files changed, 7 insertions, 8 deletions
diff --git a/drivers/usb/gadget/core.c b/drivers/usb/gadget/core.c
index d1b7c7f3a..235efbcad 100644
--- a/drivers/usb/gadget/core.c
+++ b/drivers/usb/gadget/core.c
@@ -117,7 +117,7 @@ char *usbd_device_status[] = {
/* Descriptor support functions ************************************************************** */
-unsigned char *usb_string_NA = "\010\003N\000/\000A\000";
+char *usb_string_NA = "\010\003N\000/\000A\000";
/**
* usbd_get_string - find and return a string descriptor
@@ -588,7 +588,6 @@ struct urb *usbd_alloc_urb (struct usb_device_instance *device,
*/
void usbd_dealloc_urb (struct urb *urb)
{
- serial_printf("udu %x\n", urb);
if (urb) {
free (urb);
}
diff --git a/drivers/usb/gadget/dsuboot.c b/drivers/usb/gadget/dsuboot.c
index 0bc06dc0f..cb5212557 100644
--- a/drivers/usb/gadget/dsuboot.c
+++ b/drivers/usb/gadget/dsuboot.c
@@ -202,7 +202,7 @@ static struct usb_endpoint_instance endpoint_instance[NUM_ENDPOINTS + 1];
extern char version_string[];
struct priv_data {
- unsigned long transfer_buffer;
+ void *transfer_buffer;
int transfer_buffer_size;
char *serial_no;
int flag;
@@ -219,7 +219,7 @@ struct priv_data {
static struct priv_data priv =
{
- .transfer_buffer = CONFIG_DSUBOOT_TRANSFER_BUFFER,
+ .transfer_buffer = (void *)CONFIG_DSUBOOT_TRANSFER_BUFFER,
.transfer_buffer_size = CONFIG_DSUBOOT_TRANSFER_BUFFER_SIZE,
};
@@ -486,7 +486,7 @@ static int dsubt_dsuboot_init(void)
priv.d_size = 0;
priv.exit = 0;
priv.serial_no = (char *)"00123";
- priv.product_name = DSUBOOT_PRODUCT_NAME;
+ priv.product_name = (unsigned char *)DSUBOOT_PRODUCT_NAME;
priv.bs = 1024;
return 0;
}
@@ -621,14 +621,14 @@ static int dsubt_handle_response(void)
return 0;
}
-void *dsudownload(u32 *loadaddr, u32 *loadsize)
+int dsudownload(u32 *loadaddr, u32 *loadsize)
{
printf("booting from usb peripheral port\n");
dsubt_dsuboot_init();
dsubt_init_endpoint_ptrs();
if (udc_init() < 0) {
DSUBTERR("%s: MUSB UDC init failure\n", __func__);
- return;
+ return -1;
}
dsubt_init_strings();
dsubt_init_instances();
@@ -651,7 +651,7 @@ void *dsudownload(u32 *loadaddr, u32 *loadsize)
}
}
- *loadaddr = priv.transfer_buffer;
+ *loadaddr = (u32)priv.transfer_buffer;
*loadsize = priv.d_bytes;
return 0;
}