1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2007 by Björn Stenberg
12 * All files in this archive are subject to the GNU General Public License.
13 * See the file COPYING in the source tree root for full license agreement.
15 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
16 * KIND, either express or implied.
18 ****************************************************************************/
26 #define USB_CHARGING_ONLY
27 #else /* BOOTLOADER */
28 #define USB_CHARGING_ONLY
29 #endif /* BOOTLOADER */
36 #if CONFIG_CPU == IMX31L
37 #define NUM_ENDPOINTS 8
38 #define USBDEVBSS_ATTR DEVBSS_ATTR
40 #define USBDEVBSS_ATTR IBSS_ATTR
41 #define NUM_ENDPOINTS 3
44 extern int usb_max_pkt_size
;
46 void usb_core_init(void);
47 void usb_core_exit(void);
48 void usb_core_control_request(struct usb_ctrlrequest
* req
);
49 void usb_core_transfer_complete(int endpoint
, bool in
, int status
, int length
);
50 void usb_core_bus_reset(void);
51 bool usb_core_exclusive_connection(void);
52 void usb_core_enable_driver(int driver
,bool enabled
);
53 bool usb_core_driver_enabled (int driver
);
54 void usb_core_handle_transfer_completion(
55 struct usb_transfer_completion_event_data
* event
);
56 int usb_core_ack_control(struct usb_ctrlrequest
* req
);
58 void usb_core_hotswap_event(int volume
,bool inserted
);