1 /* SPDX-License-Identifier: GPL-2.0+ */
5 #ifndef EP0_MAX_PACKET_SIZE
6 #define EP0_MAX_PACKET_SIZE 64
9 #ifndef EP_MAX_PACKET_SIZE
10 #define EP_MAX_PACKET_SIZE 64
13 #if !defined(CONFIG_PPC)
14 /* mpc8xx_udc.h will set these values */
15 #define UDC_OUT_PACKET_SIZE EP_MAX_PACKET_SIZE
16 #define UDC_IN_PACKET_SIZE EP_MAX_PACKET_SIZE
17 #define UDC_INT_PACKET_SIZE EP_MAX_PACKET_SIZE
18 #define UDC_BULK_PACKET_SIZE EP_MAX_PACKET_SIZE
21 #define UDC_BULK_HS_PACKET_SIZE 512
23 #ifndef UDC_INT_ENDPOINT
24 #define UDC_INT_ENDPOINT 1
27 #ifndef UDC_OUT_ENDPOINT
28 #define UDC_OUT_ENDPOINT 2
31 #ifndef UDC_IN_ENDPOINT
32 #define UDC_IN_ENDPOINT 3
35 /* function declarations */
38 int udc_endpoint_write(struct usb_endpoint_instance *endpoint);
39 void udc_setup_ep(struct usb_device_instance *device, unsigned int ep,
40 struct usb_endpoint_instance *endpoint);
41 void udc_connect(void);
42 void udc_disconnect(void);
43 void udc_enable(struct usb_device_instance *device);
44 void udc_disable(void);
45 void udc_startup_events(struct usb_device_instance *device);
48 void udc_set_nak(int epid);
49 void udc_unset_nak(int epid);