Home
last modified time | relevance | path

Searched refs:ep0 (Results 1 - 25 of 180) sorted by relevance

12345678

/kernel/linux/linux-5.10/drivers/usb/gadget/udc/aspeed-vhub/
H A Dep0.c5 * ep0.c - Endpoint 0 handling
37 struct usb_request *req = &ep->ep0.req.req; in ast_vhub_reply()
42 if (WARN_ON(!ep->ep0.dir_in)) in ast_vhub_reply()
98 memcpy_fromio(&crq, ep->ep0.setup, sizeof(crq)); in ast_vhub_ep0_handle_setup()
106 ep->ep0.state); in ast_vhub_ep0_handle_setup()
118 if (ep->ep0.state != ep0_state_token && in ast_vhub_ep0_handle_setup()
119 ep->ep0.state != ep0_state_stall) { in ast_vhub_ep0_handle_setup()
125 ep->ep0.state = ep0_state_data; in ast_vhub_ep0_handle_setup()
126 ep->ep0.dir_in = !!(crq.bRequestType & USB_DIR_IN); in ast_vhub_ep0_handle_setup()
169 writel(VHUB_EP0_CTRL_STALL, ep->ep0 in ast_vhub_ep0_handle_setup()
[all...]
H A Ddev.c44 ast_vhub_ep0_handle_ack(&d->ep0, true); in ast_vhub_dev_irq()
46 ast_vhub_ep0_handle_ack(&d->ep0, false); in ast_vhub_dev_irq()
48 ast_vhub_ep0_handle_setup(&d->ep0); in ast_vhub_dev_irq()
77 writel(d->ep0.buf_dma, d->regs + AST_VHUB_DEV_EP0_DATA); in ast_vhub_dev_enable()
172 return ast_vhub_simple_reply(&d->ep0, st0, 0); in ast_vhub_dev_status()
197 return ast_vhub_simple_reply(&d->ep0, st0, 0); in ast_vhub_ep_status()
548 ast_vhub_init_ep0(vhub, &d->ep0, d); in ast_vhub_init_dev()
580 d->gadget.ep0 = &d->ep0.ep; in ast_vhub_init_dev()
/kernel/linux/linux-6.6/drivers/usb/gadget/udc/aspeed-vhub/
H A Dep0.c5 * ep0.c - Endpoint 0 handling
31 struct usb_request *req = &ep->ep0.req.req; in ast_vhub_reply()
36 if (WARN_ON(!ep->ep0.dir_in)) in ast_vhub_reply()
92 memcpy_fromio(&crq, ep->ep0.setup, sizeof(crq)); in ast_vhub_ep0_handle_setup()
100 ep->ep0.state); in ast_vhub_ep0_handle_setup()
112 if (ep->ep0.state != ep0_state_token && in ast_vhub_ep0_handle_setup()
113 ep->ep0.state != ep0_state_stall) { in ast_vhub_ep0_handle_setup()
119 ep->ep0.state = ep0_state_data; in ast_vhub_ep0_handle_setup()
120 ep->ep0.dir_in = !!(crq.bRequestType & USB_DIR_IN); in ast_vhub_ep0_handle_setup()
163 writel(VHUB_EP0_CTRL_STALL, ep->ep0 in ast_vhub_ep0_handle_setup()
[all...]
H A Ddev.c38 ast_vhub_ep0_handle_ack(&d->ep0, true); in ast_vhub_dev_irq()
40 ast_vhub_ep0_handle_ack(&d->ep0, false); in ast_vhub_dev_irq()
42 ast_vhub_ep0_handle_setup(&d->ep0); in ast_vhub_dev_irq()
71 writel(d->ep0.buf_dma, d->regs + AST_VHUB_DEV_EP0_DATA); in ast_vhub_dev_enable()
177 return ast_vhub_simple_reply(&d->ep0, st0, 0); in ast_vhub_dev_status()
202 return ast_vhub_simple_reply(&d->ep0, st0, 0); in ast_vhub_ep_status()
553 ast_vhub_init_ep0(vhub, &d->ep0, d); in ast_vhub_init_dev()
585 d->gadget.ep0 = &d->ep0.ep; in ast_vhub_init_dev()
/kernel/linux/linux-5.10/tools/usb/ffs-aio-example/simple/device_app/
H A Daio_simple.c164 static void handle_ep0(int ep0, bool *ready) in handle_ep0() argument
170 pfds[0].fd = ep0; in handle_ep0()
176 ret = read(ep0, &event, sizeof(event)); in handle_ep0()
178 perror("unable to read event from ep0"); in handle_ep0()
185 write(ep0, NULL, 0); in handle_ep0()
187 read(ep0, NULL, 0); in handle_ep0()
209 int ep0; in main() local
234 sprintf(ep_path, "%s/ep0", argv[1]); in main()
235 ep0 = open(ep_path, O_RDWR); in main()
236 if (ep0 < in main()
[all...]
/kernel/linux/linux-6.6/tools/usb/ffs-aio-example/simple/device_app/
H A Daio_simple.c182 static void handle_ep0(int ep0, bool *ready) in handle_ep0() argument
188 pfds[0].fd = ep0; in handle_ep0()
194 ret = read(ep0, &event, sizeof(event)); in handle_ep0()
196 perror("unable to read event from ep0"); in handle_ep0()
203 write(ep0, NULL, 0); in handle_ep0()
205 read(ep0, NULL, 0); in handle_ep0()
227 int ep0; in main() local
252 sprintf(ep_path, "%s/ep0", argv[1]); in main()
253 ep0 = open(ep_path, O_RDWR); in main()
254 if (ep0 < in main()
[all...]
/kernel/linux/linux-5.10/tools/usb/ffs-aio-example/multibuff/device_app/
H A Daio_multibuff.c176 static void handle_ep0(int ep0, bool *ready) in handle_ep0() argument
181 ret = read(ep0, &event, sizeof(event)); in handle_ep0()
183 perror("unable to read event from ep0"); in handle_ep0()
190 write(ep0, NULL, 0); in handle_ep0()
192 read(ep0, NULL, 0); in handle_ep0()
240 int ep0, ep1; in main() local
263 sprintf(ep_path, "%s/ep0", argv[1]); in main()
264 ep0 = open(ep_path, O_RDWR); in main()
265 if (ep0 < 0) { in main()
266 perror("unable to open ep0"); in main()
[all...]
/kernel/linux/linux-6.6/tools/usb/ffs-aio-example/multibuff/device_app/
H A Daio_multibuff.c176 static void handle_ep0(int ep0, bool *ready) in handle_ep0() argument
181 ret = read(ep0, &event, sizeof(event)); in handle_ep0()
183 perror("unable to read event from ep0"); in handle_ep0()
190 write(ep0, NULL, 0); in handle_ep0()
192 read(ep0, NULL, 0); in handle_ep0()
240 int ep0, ep1; in main() local
263 sprintf(ep_path, "%s/ep0", argv[1]); in main()
264 ep0 = open(ep_path, O_RDWR); in main()
265 if (ep0 < 0) { in main()
266 perror("unable to open ep0"); in main()
[all...]
/kernel/linux/linux-6.6/drivers/usb/gadget/udc/
H A Drenesas_usbf.c344 /* ep0: buf @0x0000 64 bytes, fixed 32 words */
345 [0] = USBF_EP_INFO("ep0-ctrl",
547 static void usbf_ep0_send_null(struct usbf_ep *ep0, bool is_data1) in usbf_ep0_send_null() argument
555 usbf_ep_reg_bitset(ep0, USBF_REG_EP0_CONTROL, set); in usbf_ep0_send_null()
558 static int usbf_ep0_pio_in(struct usbf_ep *ep0, struct usbf_req *req) in usbf_ep0_pio_in() argument
571 dev_dbg(ep0->udc->dev, "ep0 send null\n"); in usbf_ep0_pio_in()
572 usbf_ep0_send_null(ep0, false); in usbf_ep0_pio_in()
576 if ((req->req.actual % ep0->ep.maxpacket) == 0) { in usbf_ep0_pio_in()
578 dev_dbg(ep0 in usbf_ep0_pio_in()
617 usbf_ep0_pio_out(struct usbf_ep *ep0, struct usbf_req *req) usbf_ep0_pio_out() argument
704 usbf_ep0_fifo_flush(struct usbf_ep *ep0) usbf_ep0_fifo_flush() argument
1785 usbf_ep0_enable(struct usbf_ep *ep0) usbf_ep0_enable() argument
1916 usbf_ep0_queue(struct usbf_ep *ep0, struct usbf_req *req, gfp_t gfp_flags) usbf_ep0_queue() argument
2176 usbf_ep0_fill_req(struct usbf_ep *ep0, struct usbf_req *req, void *buf, unsigned int length, void (*complete)(struct usb_ep *_ep, struct usb_request *_req)) usbf_ep0_fill_req() argument
2444 usbf_handle_ep0_setup(struct usbf_ep *ep0) usbf_handle_ep0_setup() argument
2520 usbf_handle_ep0_data_status(struct usbf_ep *ep0, const char *ep0state_name, enum usbf_ep0state next_ep0state) usbf_handle_ep0_data_status() argument
2551 usbf_handle_ep0_out_status_start(struct usbf_ep *ep0) usbf_handle_ep0_out_status_start() argument
2576 usbf_handle_ep0_in_status_start(struct usbf_ep *ep0) usbf_handle_ep0_in_status_start() argument
2622 usbf_ep0_interrupt(struct usbf_ep *ep0) usbf_ep0_interrupt() argument
[all...]
H A Dudc-xilinx.c202 static const char ep0name[] = "ep0";
261 struct xusb_ep *ep0 = &udc->ep[XUSB_EP_NUMBER_ZERO]; in xudc_wrstatus() local
264 epcfgreg = udc->read_fn(udc->addr + ep0->offset)| in xudc_wrstatus()
266 udc->write_fn(udc->addr, ep0->offset, epcfgreg); in xudc_wrstatus()
267 udc->write_fn(udc->addr, ep0->offset + XUSB_EP_BUF0COUNT_OFFSET, 0); in xudc_wrstatus()
996 * @ep0: pointer to the xusb endpoint 0 structure.
1001 static int __xudc_ep0_queue(struct xusb_ep *ep0, struct xusb_req *req) in __xudc_ep0_queue() argument
1003 struct xusb_udc *udc = ep0->udc; in __xudc_ep0_queue()
1011 if (!list_empty(&ep0->queue)) { in __xudc_ep0_queue()
1012 dev_dbg(udc->dev, "%s:ep0 bus in __xudc_ep0_queue()
1056 struct xusb_ep *ep0 = to_xusb_ep(_ep); xudc_ep0_queue() local
1378 struct xusb_ep *ep0 = &udc->ep[XUSB_EP_NUMBER_ZERO]; xudc_start() local
1567 struct xusb_ep *ep0 = &udc->ep[XUSB_EP_NUMBER_ZERO]; xudc_ep0_stall() local
1582 struct xusb_ep *ep0 = &udc->ep[0]; xudc_setaddress() local
1603 struct xusb_ep *ep0 = &udc->ep[0]; xudc_getstatus() local
1660 struct xusb_ep *ep0 = &udc->ep[0]; xudc_set_clear_feature() local
1753 struct xusb_ep *ep0 = &udc->ep[0]; global() variable
1819 struct xusb_ep *ep0 = &udc->ep[0]; xudc_ep0_out() local
1868 struct xusb_ep *ep0 = &udc->ep[0]; xudc_ep0_in() local
[all...]
H A Dlpc32xx_udc.c1381 INIT_LIST_HEAD(&udc->gadget.ep0->ep_list); in udc_reinit()
1443 struct lpc32xx_ep *ep0 = &udc->ep[0]; in udc_ep0_in_req() local
1446 if (list_empty(&ep0->queue)) in udc_ep0_in_req()
1450 req = list_entry(ep0->queue.next, struct lpc32xx_request, in udc_ep0_in_req()
1457 done(ep0, req, 0); in udc_ep0_in_req()
1459 } else if (ts > ep0->ep.maxpacket) in udc_ep0_in_req()
1460 ts = ep0->ep.maxpacket; /* Just send what we can */ in udc_ep0_in_req()
1468 if (tsend >= ep0->ep.maxpacket) in udc_ep0_in_req()
1473 done(ep0, req, 0); in udc_ep0_in_req()
1481 struct lpc32xx_ep *ep0 in udc_ep0_out_req() local
2186 struct lpc32xx_ep *ep, *ep0 = &udc->ep[0]; udc_handle_ep0_setup() local
2325 struct lpc32xx_ep *ep0 = &udc->ep[0]; udc_handle_ep0_in() local
2359 struct lpc32xx_ep *ep0 = &udc->ep[0]; udc_handle_ep0_out() local
[all...]
/kernel/linux/linux-5.10/drivers/usb/gadget/udc/
H A Dudc-xilinx.c201 static const char ep0name[] = "ep0";
260 struct xusb_ep *ep0 = &udc->ep[XUSB_EP_NUMBER_ZERO]; in xudc_wrstatus() local
263 epcfgreg = udc->read_fn(udc->addr + ep0->offset)| in xudc_wrstatus()
265 udc->write_fn(udc->addr, ep0->offset, epcfgreg); in xudc_wrstatus()
266 udc->write_fn(udc->addr, ep0->offset + XUSB_EP_BUF0COUNT_OFFSET, 0); in xudc_wrstatus()
995 * @ep0: pointer to the xusb endpoint 0 structure.
1000 static int __xudc_ep0_queue(struct xusb_ep *ep0, struct xusb_req *req) in __xudc_ep0_queue() argument
1002 struct xusb_udc *udc = ep0->udc; in __xudc_ep0_queue()
1010 if (!list_empty(&ep0->queue)) { in __xudc_ep0_queue()
1011 dev_dbg(udc->dev, "%s:ep0 bus in __xudc_ep0_queue()
1055 struct xusb_ep *ep0 = to_xusb_ep(_ep); xudc_ep0_queue() local
1374 struct xusb_ep *ep0 = &udc->ep[XUSB_EP_NUMBER_ZERO]; xudc_start() local
1563 struct xusb_ep *ep0 = &udc->ep[XUSB_EP_NUMBER_ZERO]; xudc_ep0_stall() local
1578 struct xusb_ep *ep0 = &udc->ep[0]; xudc_setaddress() local
1599 struct xusb_ep *ep0 = &udc->ep[0]; xudc_getstatus() local
1656 struct xusb_ep *ep0 = &udc->ep[0]; xudc_set_clear_feature() local
1747 struct xusb_ep *ep0 = &udc->ep[0]; global() variable
1813 struct xusb_ep *ep0 = &udc->ep[0]; xudc_ep0_out() local
1862 struct xusb_ep *ep0 = &udc->ep[0]; xudc_ep0_in() local
[all...]
H A Dlpc32xx_udc.c1382 INIT_LIST_HEAD(&udc->gadget.ep0->ep_list); in udc_reinit()
1444 struct lpc32xx_ep *ep0 = &udc->ep[0]; in udc_ep0_in_req() local
1447 if (list_empty(&ep0->queue)) in udc_ep0_in_req()
1451 req = list_entry(ep0->queue.next, struct lpc32xx_request, in udc_ep0_in_req()
1458 done(ep0, req, 0); in udc_ep0_in_req()
1460 } else if (ts > ep0->ep.maxpacket) in udc_ep0_in_req()
1461 ts = ep0->ep.maxpacket; /* Just send what we can */ in udc_ep0_in_req()
1469 if (tsend >= ep0->ep.maxpacket) in udc_ep0_in_req()
1474 done(ep0, req, 0); in udc_ep0_in_req()
1482 struct lpc32xx_ep *ep0 in udc_ep0_out_req() local
2185 struct lpc32xx_ep *ep, *ep0 = &udc->ep[0]; udc_handle_ep0_setup() local
2324 struct lpc32xx_ep *ep0 = &udc->ep[0]; udc_handle_ep0_in() local
2358 struct lpc32xx_ep *ep0 = &udc->ep[0]; udc_handle_ep0_out() local
[all...]
/kernel/linux/linux-5.10/drivers/usb/mtu3/
H A Dmtu3_gadget_ep0.c3 * mtu3_gadget_ep0.c - MediaTek USB3 DRD peripheral driver ep0 handling
17 /* ep0 is always mtu3->in_eps[0] */
18 #define next_ep0_request(mtu) next_request((mtu)->ep0)
59 mtu3_req_complete(mtu->ep0, req, 0); in ep0_req_giveback()
123 * because the length of test packet is less than max packet of HS ep0, in ep0_load_test_packet()
126 ep0_write_fifo(mtu->ep0, mtu3_test_packet, sizeof(mtu3_test_packet)); in ep0_load_test_packet()
152 dev_dbg(mtu->dev, "ep0: %s STALL, ep0_state: %s\n", in ep0_stall_set()
196 mtu->ep0_req.mep = mtu->ep0; in ep0_set_sel()
200 ret = ep0_queue(mtu->ep0, &mtu->ep0_req); in ep0_set_sel()
263 mtu->ep0_req.mep = mtu->ep0; in ep0_get_status()
[all...]
/kernel/linux/linux-6.6/drivers/usb/mtu3/
H A Dmtu3_gadget_ep0.c3 * mtu3_gadget_ep0.c - MediaTek USB3 DRD peripheral driver ep0 handling
17 /* ep0 is always mtu3->in_eps[0] */
18 #define next_ep0_request(mtu) next_request((mtu)->ep0)
59 mtu3_req_complete(mtu->ep0, req, 0); in ep0_req_giveback()
123 * because the length of test packet is less than max packet of HS ep0, in ep0_load_test_packet()
126 ep0_write_fifo(mtu->ep0, mtu3_test_packet, sizeof(mtu3_test_packet)); in ep0_load_test_packet()
152 dev_dbg(mtu->dev, "ep0: %s STALL, ep0_state: %s\n", in ep0_stall_set()
196 mtu->ep0_req.mep = mtu->ep0; in ep0_set_sel()
200 ret = ep0_queue(mtu->ep0, &mtu->ep0_req); in ep0_set_sel()
265 mtu->ep0_req.mep = mtu->ep0; in ep0_get_status()
[all...]
/kernel/linux/linux-5.10/drivers/usb/host/
H A Dfhci-tds.c100 ep = usb->ep0; in fhci_ep0_free()
136 usb->ep0 = NULL; in fhci_ep0_free()
224 usb->ep0 = ep; in fhci_create_ep()
279 struct endpoint *ep = usb->ep0; in fhci_td_transaction_confirm()
385 struct endpoint *ep = usb->ep0; in fhci_host_transaction()
472 struct endpoint *ep = usb->ep0; in fhci_flush_bds()
528 struct endpoint *ep = usb->ep0; in fhci_flush_actual_frame()
592 struct endpoint *ep = usb->ep0; in fhci_host_transmit_actual_frame()
/kernel/linux/linux-6.6/drivers/usb/host/
H A Dfhci-tds.c100 ep = usb->ep0; in fhci_ep0_free()
136 usb->ep0 = NULL; in fhci_ep0_free()
224 usb->ep0 = ep; in fhci_create_ep()
279 struct endpoint *ep = usb->ep0; in fhci_td_transaction_confirm()
385 struct endpoint *ep = usb->ep0; in fhci_host_transaction()
472 struct endpoint *ep = usb->ep0; in fhci_flush_bds()
528 struct endpoint *ep = usb->ep0; in fhci_flush_actual_frame()
592 struct endpoint *ep = usb->ep0; in fhci_host_transmit_actual_frame()
/kernel/linux/linux-6.6/drivers/usb/cdns3/
H A DMakefile18 cdns3-$(CONFIG_USB_CDNS3_GADGET) += cdns3-gadget.o cdns3-ep0.o
40 cdnsp-mem.o cdnsp-ep0.o
/kernel/linux/linux-5.10/drivers/usb/gadget/legacy/
H A Ddbgp.c226 usb_ep_free_request(gadget->ep0, dbgp.req); in dbgp_unbind()
284 dbgp.req = usb_ep_alloc_request(gadget->ep0, GFP_KERNEL); in dbgp_bind()
367 device_desc.bMaxPacketSize0 = gadget->ep0->maxpacket; in dbgp_setup()
401 return usb_ep_queue(gadget->ep0, req, GFP_ATOMIC); in dbgp_setup()
H A Dinode.c45 * are two types of files. One type is for the device, implementing ep0.
83 /* /dev/gadget/$CHIP represents ep0 and the whole device */
89 * ep0/device i/o modes and binding to the controller. Driver
95 /* From then on, ep0 fd is in either of two basic modes:
104 /* UNBOUND means the driver closed ep0, so the device won't be
125 /* drivers reading ep0 MUST handle control requests (SETUP)
148 /* except this scratch i/o buffer for ep0 */
237 * at the end of ep0 configuration, or after unbind.
895 DBG (dev, "ep0 request busy!\n"); in setup_req()
935 (void) usb_ep_set_halt (dev->gadget->ep0); in ep0_read()
[all...]
/kernel/linux/linux-5.10/drivers/usb/usbip/
H A Dvudc_sysfs.c26 struct vep *ep0 = to_vep(udc->gadget.ep0); in get_gadget_descs() local
47 usb_req = list_last_entry(&ep0->req_queue, struct vrequest, req_entry); in get_gadget_descs()
61 usb_gadget_giveback_request(&(ep0->ep), &(usb_req->req)); in get_gadget_descs()
/kernel/linux/linux-6.6/drivers/usb/gadget/legacy/
H A Ddbgp.c226 usb_ep_free_request(gadget->ep0, dbgp.req); in dbgp_unbind()
284 dbgp.req = usb_ep_alloc_request(gadget->ep0, GFP_KERNEL); in dbgp_bind()
367 device_desc.bMaxPacketSize0 = gadget->ep0->maxpacket; in dbgp_setup()
401 return usb_ep_queue(gadget->ep0, req, GFP_ATOMIC); in dbgp_setup()
/kernel/linux/linux-6.6/drivers/usb/usbip/
H A Dvudc_sysfs.c26 struct vep *ep0 = to_vep(udc->gadget.ep0); in get_gadget_descs() local
47 usb_req = list_last_entry(&ep0->req_queue, struct vrequest, req_entry); in get_gadget_descs()
61 usb_gadget_giveback_request(&(ep0->ep), &(usb_req->req)); in get_gadget_descs()
/kernel/linux/linux-5.10/drivers/usb/gadget/
H A Dcomposite.c250 ERROR(cdev, "ep0 bMaxBurst must be 0\n"); in config_ep_by_speed_and_alt()
795 qual->bMaxPacketSize0 = cdev->gadget->ep0->maxpacket; in device_qual()
1443 * REVIST The same ep0 requests are shared with function drivers in composite_setup_complete()
1467 ret = usb_ep_queue(cdev->gadget->ep0, req, gfp_flags); in composite_ep0_queue()
1631 * The setup() callback implements all the ep0 functionality that's
1671 gadget->ep0->driver_data = cdev; in composite_setup()
1692 cdev->gadget->ep0->maxpacket; in composite_setup()
2051 composite_setup_complete(gadget->ep0, req); in composite_setup()
2175 cdev->req = usb_ep_alloc_request(gadget->ep0, GFP_KERNEL); in composite_dev_prepare()
2189 gadget->ep0 in composite_dev_prepare()
2215 composite_os_desc_req_prepare(struct usb_composite_dev *cdev, struct usb_ep *ep0) composite_os_desc_req_prepare() argument
[all...]
/kernel/linux/linux-6.6/drivers/usb/gadget/
H A Dcomposite.c261 ERROR(cdev, "ep0 bMaxBurst must be 0\n"); in config_ep_by_speed_and_alt()
921 qual->bMaxPacketSize0 = cdev->gadget->ep0->maxpacket; in device_qual()
1582 * REVIST The same ep0 requests are shared with function drivers in composite_setup_complete()
1606 ret = usb_ep_queue(cdev->gadget->ep0, req, gfp_flags); in composite_ep0_queue()
1770 * The setup() callback implements all the ep0 functionality that's
1811 gadget->ep0->driver_data = cdev; in composite_setup()
1832 cdev->gadget->ep0->maxpacket; in composite_setup()
2284 composite_setup_complete(gadget->ep0, req); in composite_setup()
2425 cdev->req = usb_ep_alloc_request(gadget->ep0, GFP_KERNEL); in composite_dev_prepare()
2439 gadget->ep0 in composite_dev_prepare()
2465 composite_os_desc_req_prepare(struct usb_composite_dev *cdev, struct usb_ep *ep0) composite_os_desc_req_prepare() argument
[all...]

Completed in 28 milliseconds

12345678