Lines Matching +full:external +full:- +full:rising
1 // SPDX-License-Identifier: GPL-2.0+
4 * Intel PXA27x on-chip full speed USB device controller
28 #define UDCOTGICR 0x0018 /* UDC On-The-Go interrupt control */
36 #define UDCCR_OEN (1 << 31) /* On-the-Go Enable */
37 #define UDCCR_AALTHNP (1 << 30) /* A-device Alternate Host Negotiation
39 #define UDCCR_AHNP (1 << 29) /* A-device Host Negotiation Protocol
41 #define UDCCR_BHNP (1 << 28) /* B-device Host Negotiation Protocol
43 #define UDCCR_DWRE (1 << 16) /* Device Remote Wake-up Enable */
60 #define UDCICR1_IECC (1 << 31) /* IntEn - Configuration Change */
61 #define UDCICR1_IESOF (1 << 30) /* IntEn - Start of Frame */
62 #define UDCICR1_IERU (1 << 29) /* IntEn - Resume */
63 #define UDCICR1_IESU (1 << 28) /* IntEn - Suspend */
64 #define UDCICR1_IERS (1 << 27) /* IntEn - Reset */
70 #define UDCISR1_IRCC (1 << 31) /* IntReq - Configuration Change */
71 #define UDCISR1_IRSOF (1 << 30) /* IntReq - Start of Frame */
72 #define UDCISR1_IRRU (1 << 29) /* IntReq - Resume */
73 #define UDCISR1_IRSU (1 << 28) /* IntReq - Suspend */
74 #define UDCISR1_IRRS (1 << 27) /* IntReq - Reset */
79 Rising Edge Interrupt Enable */
82 #define UDCOTGICR_IEVV40R (1 << 9) /* OTG Vbus Valid 4.0V Rising Edge
86 #define UDCOTGICR_IEVV44R (1 << 7) /* OTG Vbus Valid 4.4V Rising Edge
90 #define UDCOTGICR_IESVR (1 << 5) /* OTG Session Valid Rising Edge
94 #define UDCOTGICR_IESDR (1 << 3) /* OTG A-Device SRP Detect Rising
96 #define UDCOTGICR_IESDF (1 << 2) /* OTG A-Device SRP Detect Falling
98 #define UDCOTGICR_IEIDR (1 << 1) /* OTG ID Change Rising Edge
108 #define UP2OCR_DMPDE (1 << 3) /* D- Pull Down Enable */
110 #define UP2OCR_DMPUE (1 << 5) /* D- Pull Up Enable */
112 #define UP2OCR_DMPUBE (1 << 7) /* D- Pull Up Bypass Enable */
113 #define UP2OCR_EXSP (1 << 8) /* External Transceiver Speed Control */
114 #define UP2OCR_EXSUS (1 << 9) /* External Transceiver Speed Enable */
118 #define UP2OCR_SEOS (1 << 24) /* Single-Ended Output Select */
174 #define ofs_UDCCR(ep) (UDCCRn(ep->idx))
175 #define ofs_UDCCSR(ep) (UDCCSRn(ep->idx))
176 #define ofs_UDCBCR(ep) (UDCBCRn(ep->idx))
177 #define ofs_UDCDR(ep) (UDCDRn(ep->idx))
181 __raw_readl((ep)->dev->regs + ofs_##reg(ep))
183 __raw_writel((value), ep->dev->regs + ofs_##reg(ep))
185 __raw_readb((ep)->dev->regs + ofs_##reg(ep))
187 __raw_writeb((value), ep->dev->regs + ofs_##reg(ep))
189 __raw_readl((dev)->regs + (reg))
191 __raw_writel((value), (udc)->regs + (reg))
198 #define EPIDX(ep) (ep->idx)
199 #define EPADDR(ep) (ep->addr)
200 #define EPXFERTYPE(ep) (ep->type)
201 #define EPNAME(ep) (ep->name)
202 #define is_ep0(ep) (!ep->idx)
220 * - "ep1-in" matches pxa endpoint EPA (which is an IN ep at addr 1, when
222 * - "ep1-in" matches pxa endpoint EPB (which is an IN ep at addr 1, when
224 * - "ep1-in" matches pxa endpoint EPC (which is an IN ep at addr 1, when
250 #define USB_EP_IN_BULK(n) USB_EP_BULK(n, "ep" #n "in-bulk", 1, \
252 #define USB_EP_OUT_BULK(n) USB_EP_BULK(n, "ep" #n "out-bulk", 0, \
254 #define USB_EP_IN_ISO(n) USB_EP_ISO(n, "ep" #n "in-iso", 1, \
256 #define USB_EP_OUT_ISO(n) USB_EP_ISO(n, "ep" #n "out-iso", 0, \
258 #define USB_EP_IN_INT(n) USB_EP_INT(n, "ep" #n "in-int", 1, \
299 * struct udc_usb_ep - container of each usb_ep structure
313 * struct pxa_ep - pxa endpoint
320 * irq->handle_ep()->req_done()->req.complete()->pxa_ep_queue()->handle_ep()
322 * pxa_ep_queue()->handle_ep()->req_done()->req.complete()->pxa_ep_queue()
375 * struct pxa27x_request - container of each usb_request structure
379 * @queue: linked list of requests, linked on pxa_ep->queue
404 #define EP0_STNAME(udc) ep0_state_name[(udc)->ep0state]
418 #define NR_USB_ENDPOINTS (1 + 5) /* ep0 + ep1in-bulk + .. + ep3in-iso */
422 * struct pxa_udc - udc structure
431 * @transceiver: external transceiver to handle vbus sense and D+ pullup
488 dev_dbg(ep->dev->dev, "%s:%s: " fmt, EPNAME(ep), __func__, ## arg)
490 dev_vdbg(ep->dev->dev, "%s:%s: " fmt, EPNAME(ep), __func__, ## arg)
492 dev_err(ep->dev->dev, "%s:%s: " fmt, EPNAME(ep), __func__, ## arg)
494 dev_info(ep->dev->dev, "%s:%s: " fmt, EPNAME(ep), __func__, ## arg)
496 dev_warn(ep->dev->dev, "%s:%s:" fmt, EPNAME(ep), __func__, ## arg)