diff options
author | Rafaël Carré <rafael.carre@gmail.com> | 2010-06-18 01:47:39 +0000 |
---|---|---|
committer | Rafaël Carré <rafael.carre@gmail.com> | 2010-06-18 01:47:39 +0000 |
commit | b812465bfff2111e149a44d7041c1d62d7e1519c (patch) | |
tree | 18c654b306088c1e9a19aab2f5dc444845c922c7 /firmware/target/arm/as3525/usb-drv-as3525.c | |
parent | 6470a9ffd132f0315e1c62cbf01e2a1963b874ab (diff) |
as3525: bootloader USB mode
not working yet : an empty drive is detected
won't link on fuzev1: drivers allocated in usb_storage.c are too large
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26905 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/as3525/usb-drv-as3525.c')
-rw-r--r-- | firmware/target/arm/as3525/usb-drv-as3525.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/firmware/target/arm/as3525/usb-drv-as3525.c b/firmware/target/arm/as3525/usb-drv-as3525.c index 45dadebc85..fe3b38fdb5 100644 --- a/firmware/target/arm/as3525/usb-drv-as3525.c +++ b/firmware/target/arm/as3525/usb-drv-as3525.c @@ -684,8 +684,10 @@ int usb_drv_recv(int ep, void *ptr, int len) endpoints[ep][1].len = len; endpoints[ep][1].rc = -1; +#ifndef BOOTLOADER /* remove data buffer from cache */ invalidate_dcache(); +#endif /* DMA setup */ uc_desc->status = USB_DMA_DESC_BS_HST_RDY | USB_DMA_DESC_LAST | @@ -734,8 +736,10 @@ void ep_send(int ep, void *ptr, int len) endpoints[ep][0].len = len; endpoints[ep][0].rc = -1; +#ifndef BOOTLOADER /* Make sure data is committed to memory */ clean_dcache(); +#endif logf("xx%s\n", make_hex(ptr, len)); @@ -843,10 +847,12 @@ static void handle_out_ep(int ep) logf("EP%d OUT token, st:%08x len:%d frm:%x data=%s epstate=%d\n", ep, dma_mst, dma_len, dma_frm, make_hex(uc_desc->data_ptr, dma_len), endpoints[ep][1].state); +#ifndef BOOTLOADER /* * If parts of the just dmaed range are in cache, dump them now. */ dump_dcache_range(uc_desc->data_ptr, dma_len); +#endif } else{ logf("EP%d OUT token, st:%08x frm:%x (no data)\n", ep, dma_mst, dma_frm); |