diff options
author | Amaury Pouly <pamaury@rockbox.org> | 2010-06-19 20:49:06 +0000 |
---|---|---|
committer | Amaury Pouly <pamaury@rockbox.org> | 2010-06-19 20:49:06 +0000 |
commit | b40c300d594ede952f612ff7ea3e4db71a5d1d30 (patch) | |
tree | 7fa1ca29058ae42705dcb6570fc16354ccc68fd7 | |
parent | 9b8659315ee6a84ae8318501355a7e8314ddef94 (diff) | |
download | rockbox-b40c300d594ede952f612ff7ea3e4db71a5d1d30.tar.gz rockbox-b40c300d594ede952f612ff7ea3e4db71a5d1d30.zip |
as3525v2-usb: fix yellow about unused functions (they can be resurrected from an older revision if needed)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26976 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r-- | firmware/target/arm/as3525/usb-drv-as3525v2.c | 75 |
1 files changed, 2 insertions, 73 deletions
diff --git a/firmware/target/arm/as3525/usb-drv-as3525v2.c b/firmware/target/arm/as3525/usb-drv-as3525v2.c index d420c113b7..e408236b1a 100644 --- a/firmware/target/arm/as3525/usb-drv-as3525v2.c +++ b/firmware/target/arm/as3525/usb-drv-as3525v2.c | |||
@@ -155,38 +155,6 @@ static void flush_tx_fifos(int nums) | |||
155 | udelay(1); | 155 | udelay(1); |
156 | } | 156 | } |
157 | 157 | ||
158 | static void flush_rx_fifo(void) | ||
159 | { | ||
160 | unsigned int i = 0; | ||
161 | |||
162 | GRSTCTL = GRSTCTL_rxfflsh_flush; | ||
163 | while(GRSTCTL & GRSTCTL_rxfflsh_flush && i < 0x300) | ||
164 | i++; | ||
165 | if(GRSTCTL & GRSTCTL_rxfflsh_flush) | ||
166 | panicf("usb: hang of flush rx fifo"); | ||
167 | /* wait 3 phy clocks */ | ||
168 | udelay(1); | ||
169 | } | ||
170 | |||
171 | static void core_reset(void) | ||
172 | { | ||
173 | unsigned int i = 0; | ||
174 | /* Wait for AHB master IDLE state. */ | ||
175 | while((GRSTCTL & GRSTCTL_ahbidle) == 0) | ||
176 | udelay(10); | ||
177 | /* Core Soft Reset */ | ||
178 | GRSTCTL |= GRSTCTL_csftrst; | ||
179 | /* Waits for the hardware to clear reset bit */ | ||
180 | while(GRSTCTL & GRSTCTL_csftrst && i < 0x300) | ||
181 | i++; | ||
182 | |||
183 | if(GRSTCTL & GRSTCTL_csftrst) | ||
184 | panicf("oops, usb core soft reset hang :("); | ||
185 | |||
186 | /* Wait for 3 PHY Clocks */ | ||
187 | udelay(1); | ||
188 | } | ||
189 | |||
190 | static void reset_endpoints(void) | 158 | static void reset_endpoints(void) |
191 | { | 159 | { |
192 | int i, ep; | 160 | int i, ep; |
@@ -404,6 +372,8 @@ void usb_drv_init(void) | |||
404 | void usb_drv_exit(void) | 372 | void usb_drv_exit(void) |
405 | { | 373 | { |
406 | logf("usb_drv_exit"); | 374 | logf("usb_drv_exit"); |
375 | |||
376 | disable_global_interrupts(); | ||
407 | } | 377 | } |
408 | 378 | ||
409 | static bool handle_reset(void) | 379 | static bool handle_reset(void) |
@@ -480,43 +450,6 @@ static bool handle_out_ep_int(void) | |||
480 | return false; | 450 | return false; |
481 | } | 451 | } |
482 | 452 | ||
483 | static void dump_intsts(char *buffer, size_t size, unsigned long sts) | ||
484 | { | ||
485 | (void) size; | ||
486 | buffer[0] = 0; | ||
487 | #define DUMP_CASE(name) \ | ||
488 | if(sts & GINTMSK_##name) strcat(buffer, #name " "); | ||
489 | |||
490 | DUMP_CASE(modemismatch) | ||
491 | DUMP_CASE(otgintr) | ||
492 | DUMP_CASE(sofintr) | ||
493 | DUMP_CASE(rxstsqlvl) | ||
494 | DUMP_CASE(nptxfempty) | ||
495 | DUMP_CASE(ginnakeff) | ||
496 | DUMP_CASE(goutnakeff) | ||
497 | DUMP_CASE(i2cintr) | ||
498 | DUMP_CASE(erlysuspend) | ||
499 | DUMP_CASE(usbsuspend) | ||
500 | DUMP_CASE(usbreset) | ||
501 | DUMP_CASE(enumdone) | ||
502 | DUMP_CASE(isooutdrop) | ||
503 | DUMP_CASE(eopframe) | ||
504 | DUMP_CASE(epmismatch) | ||
505 | DUMP_CASE(inepintr) | ||
506 | DUMP_CASE(outepintr) | ||
507 | DUMP_CASE(incomplisoin) | ||
508 | DUMP_CASE(incomplisoout) | ||
509 | DUMP_CASE(portintr) | ||
510 | DUMP_CASE(hcintr) | ||
511 | DUMP_CASE(ptxfempty) | ||
512 | DUMP_CASE(conidstschng) | ||
513 | DUMP_CASE(disconnect) | ||
514 | DUMP_CASE(sessreqintr) | ||
515 | DUMP_CASE(wkupintr) | ||
516 | |||
517 | buffer[strlen(buffer) - 1] = 0; | ||
518 | } | ||
519 | |||
520 | /* interrupt service routine */ | 453 | /* interrupt service routine */ |
521 | void INT_USB(void) | 454 | void INT_USB(void) |
522 | { | 455 | { |
@@ -541,12 +474,8 @@ void INT_USB(void) | |||
541 | /* device part */ | 474 | /* device part */ |
542 | HANDLED_CASE(GINTMSK_usbreset, handle_reset) | 475 | HANDLED_CASE(GINTMSK_usbreset, handle_reset) |
543 | HANDLED_CASE(GINTMSK_enumdone, handle_enum_done) | 476 | HANDLED_CASE(GINTMSK_enumdone, handle_enum_done) |
544 | /* | ||
545 | HANDLED_CASE(GINTMSK_inepintr, handle_in_ep_int) | 477 | HANDLED_CASE(GINTMSK_inepintr, handle_in_ep_int) |
546 | HANDLED_CASE(GINTMSK_outepintr, handle_out_ep_int) | 478 | HANDLED_CASE(GINTMSK_outepintr, handle_out_ep_int) |
547 | */ | ||
548 | UNHANDLED_CASE(GINTMSK_outepintr) | ||
549 | UNHANDLED_CASE(GINTMSK_inepintr) | ||
550 | 479 | ||
551 | /* common part */ | 480 | /* common part */ |
552 | UNHANDLED_CASE(GINTMSK_otgintr) | 481 | UNHANDLED_CASE(GINTMSK_otgintr) |