summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmaury Pouly <pamaury@rockbox.org>2010-09-02 13:46:34 +0000
committerAmaury Pouly <pamaury@rockbox.org>2010-09-02 13:46:34 +0000
commitf3da8d0ee3dc61b2d106ef617b761da5ea459f37 (patch)
tree9ebafd7b589b202685b8fb558c43d23c9954f7b6
parente09a0857e8a31d29b77ee5d82e7db769403c11c0 (diff)
downloadrockbox-f3da8d0ee3dc61b2d106ef617b761da5ea459f37.tar.gz
rockbox-f3da8d0ee3dc61b2d106ef617b761da5ea459f37.zip
as3525v2: revert the USB_DEVBSS_ATTR and the panicf redefinition, don't protected #undef of USB_NUM_ENDPOINTS
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27987 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--firmware/export/as3525v2.h7
-rw-r--r--firmware/target/arm/as3525/usb-drv-as3525v2.c4
2 files changed, 1 insertions, 10 deletions
diff --git a/firmware/export/as3525v2.h b/firmware/export/as3525v2.h
index b983ad712a..e0c13df757 100644
--- a/firmware/export/as3525v2.h
+++ b/firmware/export/as3525v2.h
@@ -34,16 +34,9 @@
34 34
35#define CGU_SDSLOT (*(volatile unsigned long *)(CGU_BASE + 0x3C)) 35#define CGU_SDSLOT (*(volatile unsigned long *)(CGU_BASE + 0x3C))
36 36
37#ifdef USB_NUM_ENDPOINTS
38#undef USB_NUM_ENDPOINTS 37#undef USB_NUM_ENDPOINTS
39#endif
40
41#ifdef USB_DEVBSS_ATTR
42#undef USB_DEVBSS_ATTR
43#endif
44 38
45#define USB_NUM_ENDPOINTS 6 39#define USB_NUM_ENDPOINTS 6
46#define USB_DEVBSS_ATTR __attribute__((aligned(32)))
47 40
48#define CCU_USB (*(volatile unsigned long *)(CCU_BASE + 0x20)) 41#define CCU_USB (*(volatile unsigned long *)(CCU_BASE + 0x20))
49 42
diff --git a/firmware/target/arm/as3525/usb-drv-as3525v2.c b/firmware/target/arm/as3525/usb-drv-as3525v2.c
index 2dfc69b580..433606f6d0 100644
--- a/firmware/target/arm/as3525/usb-drv-as3525v2.c
+++ b/firmware/target/arm/as3525/usb-drv-as3525v2.c
@@ -36,8 +36,6 @@
36#include "usb-drv-as3525v2.h" 36#include "usb-drv-as3525v2.h"
37#include "usb_core.h" 37#include "usb_core.h"
38 38
39#define panicf(...) ({logf(__VA_ARGS__); DCTL |= DCTL_sftdiscon; /* disconnect */})
40
41static int __in_ep_list[NUM_IN_EP] = {IN_EP_LIST}; 39static int __in_ep_list[NUM_IN_EP] = {IN_EP_LIST};
42static int __out_ep_list[NUM_OUT_EP] = {OUT_EP_LIST}; 40static int __out_ep_list[NUM_OUT_EP] = {OUT_EP_LIST};
43static int __in_ep_list_ep0[NUM_IN_EP + 1] = {0, IN_EP_LIST}; 41static int __in_ep_list_ep0[NUM_IN_EP + 1] = {0, IN_EP_LIST};
@@ -101,7 +99,7 @@ enum ep0state
101/* endpoints[ep_num][DIR_IN/DIR_OUT] */ 99/* endpoints[ep_num][DIR_IN/DIR_OUT] */
102static struct usb_endpoint endpoints[USB_NUM_ENDPOINTS][2]; 100static struct usb_endpoint endpoints[USB_NUM_ENDPOINTS][2];
103/* setup packet for EP0 */ 101/* setup packet for EP0 */
104static struct usb_ctrlrequest ep0_setup_pkt USB_DEVBSS_ATTR; 102static struct usb_ctrlrequest ep0_setup_pkt __attribute__((aligned(32)));
105/* state of EP0 */ 103/* state of EP0 */
106static enum ep0state ep0_state; 104static enum ep0state ep0_state;
107 105