A few tweaks to get USB support compiling again on TCC targets (part of FS#9917 by Michaël Burtin).

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20264 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Rob Purchase 2009-03-09 22:02:30 +00:00
parent e92d9967d6
commit efe3ec86f1
4 changed files with 12 additions and 1 deletions

View file

@ -258,4 +258,7 @@
/* USB 2.0 device system MMR base address */
#define USB_BASE 0x90000b00
#define USB_NUM_ENDPOINTS 3
#define USB_DEVBSS_ATTR IBSS_ATTR
#endif

View file

@ -229,4 +229,7 @@
/* USB 2.0 device system MMR base address */
#define USB_BASE 0xf0010000
#define USB_NUM_ENDPOINTS 3
#define USB_DEVBSS_ATTR IBSS_ATTR
#endif

View file

@ -24,6 +24,7 @@
#include "kernel.h"
#include "thread.h"
#include "string.h"
#include "file.h"
#ifndef SIMULATOR
long cpu_frequency SHAREDBSS_ATTR = CPU_FREQ;

View file

@ -122,7 +122,7 @@ void usb_drv_release_endpoint(int ep)
int flags;
ep = ep & 0x7f;
if (ep < 1 || ep > NUM_ENDPOINTS)
if (ep < 1 || ep > USB_NUM_ENDPOINTS)
return ;
flags = disable_irq_save();
@ -744,6 +744,10 @@ void usb_enable(bool on)
usb_core_exit();
}
void usb_attach(void)
{
usb_enable(true);
}
int usb_detect(void)
{