summaryrefslogtreecommitdiff
path: root/firmware/target/arm/as3525/usb-drv-as3525v2.c
diff options
context:
space:
mode:
authorAmaury Pouly <pamaury@rockbox.org>2010-06-19 20:39:28 +0000
committerAmaury Pouly <pamaury@rockbox.org>2010-06-19 20:39:28 +0000
commit3603f24370ee4cb50edc35b12e857892790c265c (patch)
treee2d71eb1195865c57b6b89e19a3efd135e2dd530 /firmware/target/arm/as3525/usb-drv-as3525v2.c
parentf83328c7b423a97732ec38ae645cbc54be57f05a (diff)
as3525v2-usb: reorganize thing, don't renable ep0 on enum because it's already done
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26966 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/as3525/usb-drv-as3525v2.c')
-rw-r--r--firmware/target/arm/as3525/usb-drv-as3525v2.c100
1 files changed, 50 insertions, 50 deletions
diff --git a/firmware/target/arm/as3525/usb-drv-as3525v2.c b/firmware/target/arm/as3525/usb-drv-as3525v2.c
index b570ddb6c8..37f5798e34 100644
--- a/firmware/target/arm/as3525/usb-drv-as3525v2.c
+++ b/firmware/target/arm/as3525/usb-drv-as3525v2.c
@@ -365,51 +365,6 @@ void usb_drv_exit(void)
logf("usb_drv_exit");
}
-int usb_drv_port_speed(void)
-{
- return 0;
-}
-
-int usb_drv_request_endpoint(int type, int dir)
-{
- (void) type;
- (void) dir;
- return -1;
-}
-
-void usb_drv_release_endpoint(int ep)
-{
- (void) ep;
-}
-
-void usb_drv_cancel_all_transfers(void)
-{
-}
-
-int usb_drv_recv(int ep, void *ptr, int len)
-{
- (void) ep;
- (void) ptr;
- (void) len;
- return -1;
-}
-
-int usb_drv_send(int ep, void *ptr, int len)
-{
- (void) ep;
- (void) ptr;
- (void) len;
- return -1;
-}
-
-int usb_drv_send_nonblocking(int ep, void *ptr, int len)
-{
- (void) ep;
- (void) ptr;
- (void) len;
- return -1;
-}
-
static void activate_ep0(void)
{
/* Setup EP0 OUT to receive setup packets and
@@ -436,7 +391,7 @@ static void activate_ep0(void)
}
/* Enable OUT ep for receive */
- USB_DOEPCTL(0) |= USB_DEPCTL_epena;
+ //USB_DOEPCTL(0) |= USB_DEPCTL_epena;
/* Clear non periodic NAK for IN ep */
USB_DCTL |= USB_DCTL_cgnpinnak;
@@ -449,7 +404,6 @@ static void ep0_out_start(void)
* setup packet count = 1
* transfer size = 8 (=sizeof setup packet)
*/
-
USB_DOEPTSIZ(0) = (1 << USB_DEPTSIZ0_supcnt_bit_pos)
| (1 << USB_DEPTSIZ0_pkcnt_bit_pos)
| 8;
@@ -519,13 +473,13 @@ static bool handle_enum_done(void)
static bool handle_in_ep_int(void)
{
- logf("usb: in ep int");
+ panicf("usb: in ep int");
return false;
}
static bool handle_out_ep_int(void)
{
- logf("usb: out ep int");
+ panicf("usb: out ep int");
return false;
}
@@ -607,13 +561,59 @@ void INT_USB(void)
Lunhandled:
dump_intsts(buffer, sizeof buffer, sts);
- panicf("unhandled usb int: %lx (%s)", sts, buffer);
+ panicf("unhandled usb int: %lx (%s)", sts, buffer);
Lerr:
dump_intsts(buffer, sizeof buffer, sts);
panicf("error in usb int: %lx (%s)", sts, buffer);
}
+int usb_drv_port_speed(void)
+{
+ return 0;
+}
+
+int usb_drv_request_endpoint(int type, int dir)
+{
+ (void) type;
+ (void) dir;
+ return -1;
+}
+
+void usb_drv_release_endpoint(int ep)
+{
+ (void) ep;
+}
+
+void usb_drv_cancel_all_transfers(void)
+{
+}
+
+int usb_drv_recv(int ep, void *ptr, int len)
+{
+ (void) ep;
+ (void) ptr;
+ (void) len;
+ return -1;
+}
+
+int usb_drv_send(int ep, void *ptr, int len)
+{
+ (void) ep;
+ (void) ptr;
+ (void) len;
+ return -1;
+}
+
+int usb_drv_send_nonblocking(int ep, void *ptr, int len)
+{
+ (void) ep;
+ (void) ptr;
+ (void) len;
+ return -1;
+}
+
+
void usb_drv_set_test_mode(int mode)
{
(void) mode;