/linux-4.1.27/include/linux/usb/ |
D | otg.h | 27 int (*set_host)(struct usb_otg *otg, struct usb_bus *host); 30 int (*set_peripheral)(struct usb_otg *otg, 34 int (*set_vbus)(struct usb_otg *otg, bool enabled); 37 int (*start_srp)(struct usb_otg *otg); 40 int (*start_hnp)(struct usb_otg *otg); 48 otg_start_hnp(struct usb_otg *otg) in otg_start_hnp() argument 50 if (otg && otg->start_hnp) in otg_start_hnp() 51 return otg->start_hnp(otg); in otg_start_hnp() 58 otg_set_vbus(struct usb_otg *otg, bool enabled) in otg_set_vbus() argument 60 if (otg && otg->set_vbus) in otg_set_vbus() [all …]
|
D | otg-fsm.h | 117 struct usb_otg *otg; member
|
D | phy.h | 82 struct usb_otg *otg; member
|
/linux-4.1.27/drivers/usb/phy/ |
D | phy-isp1301-omap.c | 237 return usb_otg_state_string(isp->phy.otg->state); in state_name() 252 isp->phy.otg->state = OTG_STATE_UNDEFINED; in power_down() 281 if (!isp->phy.otg->host) in host_suspend() 287 dev = isp->phy.otg->host->controller; in host_suspend() 299 if (!isp->phy.otg->host) in host_resume() 302 dev = isp->phy.otg->host->controller; in host_resume() 309 isp->phy.otg->gadget->b_hnp_enable = 0; in gadget_suspend() 310 isp->phy.otg->gadget->a_hnp_support = 0; in gadget_suspend() 311 isp->phy.otg->gadget->a_alt_hnp_support = 0; in gadget_suspend() 312 return usb_gadget_vbus_disconnect(isp->phy.otg->gadget); in gadget_suspend() [all …]
|
D | phy-tahvo.c | 84 switch (tu->phy.otg->state) { in check_vbus_state() 87 if (tu->phy.otg->gadget) in check_vbus_state() 88 usb_gadget_vbus_connect(tu->phy.otg->gadget); in check_vbus_state() 89 tu->phy.otg->state = OTG_STATE_B_PERIPHERAL; in check_vbus_state() 97 tu->phy.otg->state = OTG_STATE_A_HOST; in check_vbus_state() 104 switch (tu->phy.otg->state) { in check_vbus_state() 106 if (tu->phy.otg->gadget) in check_vbus_state() 107 usb_gadget_vbus_disconnect(tu->phy.otg->gadget); in check_vbus_state() 108 tu->phy.otg->state = OTG_STATE_B_IDLE; in check_vbus_state() 112 tu->phy.otg->state = OTG_STATE_A_IDLE; in check_vbus_state() [all …]
|
D | phy-mv-usb.c | 57 static int mv_otg_set_vbus(struct usb_otg *otg, bool on) in mv_otg_set_vbus() argument 59 struct mv_otg *mvotg = container_of(otg->usb_phy, struct mv_otg, phy); in mv_otg_set_vbus() 66 static int mv_otg_set_host(struct usb_otg *otg, in mv_otg_set_host() argument 69 otg->host = host; in mv_otg_set_host() 74 static int mv_otg_set_peripheral(struct usb_otg *otg, in mv_otg_set_peripheral() argument 77 otg->gadget = gadget; in mv_otg_set_peripheral() 205 struct usb_otg *otg = mvotg->phy.otg; in mv_otg_start_host() local 208 if (!otg->host) in mv_otg_start_host() 213 hcd = bus_to_hcd(otg->host); in mv_otg_start_host() 226 struct usb_otg *otg = mvotg->phy.otg; in mv_otg_start_periphrals() local [all …]
|
D | phy-generic.c | 109 struct usb_otg *otg = nop->phy.otg; in nop_gpio_vbus_thread() local 119 otg->state = OTG_STATE_B_PERIPHERAL; in nop_gpio_vbus_thread() 121 usb_gadget_vbus_connect(otg->gadget); in nop_gpio_vbus_thread() 127 otg->gadget); in nop_gpio_vbus_thread() 131 usb_gadget_vbus_disconnect(otg->gadget); in nop_gpio_vbus_thread() 133 otg->state = OTG_STATE_B_IDLE; in nop_gpio_vbus_thread() 137 otg->gadget); in nop_gpio_vbus_thread() 176 static int nop_set_peripheral(struct usb_otg *otg, struct usb_gadget *gadget) in nop_set_peripheral() argument 178 if (!otg) in nop_set_peripheral() 182 otg->gadget = NULL; in nop_set_peripheral() [all …]
|
D | phy-fsl-usb.c | 264 if ((fsl_otg_dev->phy.otg->state == OTG_STATE_B_SRP_INIT) && in b_srp_end() 277 if (!fsl_otg_dev->phy.otg->host->b_hnp_enable) in a_wait_enum() 465 struct usb_otg *otg = fsm->otg; in fsl_otg_start_host() local 468 container_of(otg->usb_phy, struct fsl_otg, phy); in fsl_otg_start_host() 471 if (!otg->host) in fsl_otg_start_host() 473 dev = otg->host->controller; in fsl_otg_start_host() 532 struct usb_otg *otg = fsm->otg; in fsl_otg_start_gadget() local 535 if (!otg->gadget || !otg->gadget->dev.parent) in fsl_otg_start_gadget() 539 dev = otg->gadget->dev.parent; in fsl_otg_start_gadget() 556 static int fsl_otg_set_host(struct usb_otg *otg, struct usb_bus *host) in fsl_otg_set_host() argument [all …]
|
D | phy-gpio-vbus-usb.c | 107 if (!gpio_vbus->phy.otg->gadget) in gpio_vbus_work() 124 gpio_vbus->phy.otg->state = OTG_STATE_B_PERIPHERAL; in gpio_vbus_work() 126 usb_gadget_vbus_connect(gpio_vbus->phy.otg->gadget); in gpio_vbus_work() 136 status, gpio_vbus->phy.otg->gadget); in gpio_vbus_work() 145 usb_gadget_vbus_disconnect(gpio_vbus->phy.otg->gadget); in gpio_vbus_work() 147 gpio_vbus->phy.otg->state = OTG_STATE_B_IDLE; in gpio_vbus_work() 151 status, gpio_vbus->phy.otg->gadget); in gpio_vbus_work() 162 struct usb_otg *otg = gpio_vbus->phy.otg; in gpio_vbus_irq() local 166 otg->gadget ? otg->gadget->name : "none"); in gpio_vbus_irq() 168 if (otg->gadget) in gpio_vbus_irq() [all …]
|
D | phy-msm-usb.c | 461 struct usb_bus *bus = phy->otg->host; in msm_otg_suspend() 558 struct usb_bus *bus = phy->otg->host; in msm_otg_resume() 666 if (!phy->otg->host) in msm_otg_start_host() 669 hcd = bus_to_hcd(phy->otg->host); in msm_otg_start_host() 700 static int msm_otg_set_host(struct usb_otg *otg, struct usb_bus *host) in msm_otg_set_host() argument 702 struct msm_otg *motg = container_of(otg->usb_phy, struct msm_otg, phy); in msm_otg_set_host() 710 dev_info(otg->usb_phy->dev, "Host mode is not supported\n"); in msm_otg_set_host() 715 if (otg->state == OTG_STATE_A_HOST) { in msm_otg_set_host() 716 pm_runtime_get_sync(otg->usb_phy->dev); in msm_otg_set_host() 717 msm_otg_start_host(otg->usb_phy, 0); in msm_otg_set_host() [all …]
|
D | phy-ulpi.c | 212 static int ulpi_set_host(struct usb_otg *otg, struct usb_bus *host) in ulpi_set_host() argument 214 struct usb_phy *phy = otg->usb_phy; in ulpi_set_host() 218 otg->host = NULL; in ulpi_set_host() 222 otg->host = host; in ulpi_set_host() 238 static int ulpi_set_vbus(struct usb_otg *otg, bool on) in ulpi_set_vbus() argument 240 struct usb_phy *phy = otg->usb_phy; in ulpi_set_vbus() 261 struct usb_otg *otg; in otg_ulpi_create() local 267 otg = kzalloc(sizeof(*otg), GFP_KERNEL); in otg_ulpi_create() 268 if (!otg) { in otg_ulpi_create() 276 phy->otg = otg; in otg_ulpi_create() [all …]
|
D | phy-ab8500-usb.c | 442 ab->phy.otg->default_a = false; in ab9540_usb_link_status_update() 447 ab->phy.otg->state = OTG_STATE_B_IDLE; in ab9540_usb_link_status_update() 493 ab->phy.otg->default_a = true; in ab9540_usb_link_status_update() 514 ab->phy.otg->default_a = false; in ab9540_usb_link_status_update() 529 ab->phy.otg->default_a = false; in ab9540_usb_link_status_update() 582 ab->phy.otg->default_a = false; in ab8540_usb_link_status_update() 590 ab->phy.otg->state = OTG_STATE_B_IDLE; in ab8540_usb_link_status_update() 622 ab->phy.otg->default_a = true; in ab8540_usb_link_status_update() 641 ab->phy.otg->default_a = false; in ab8540_usb_link_status_update() 655 ab->phy.otg->default_a = false; in ab8540_usb_link_status_update() [all …]
|
D | phy-ulpi-viewport.c | 44 static int ulpi_viewport_read(struct usb_phy *otg, u32 reg) in ulpi_viewport_read() argument 47 void __iomem *view = otg->io_priv; in ulpi_viewport_read() 62 static int ulpi_viewport_write(struct usb_phy *otg, u32 val, u32 reg) in ulpi_viewport_write() argument 65 void __iomem *view = otg->io_priv; in ulpi_viewport_write()
|
D | Makefile | 16 obj-$(CONFIG_OMAP_OTG) += phy-omap-otg.o
|
D | phy-fsl-usb.h | 301 #define SET_OTG_STATE(phy, newstate) ((phy)->otg->state = newstate)
|
D | Kconfig | 110 will be called phy-omap-otg.
|
/linux-4.1.27/drivers/phy/ |
D | phy-exynos5250-usb2.c | 204 u32 otg; in exynos5250_power_on() local 217 otg = readl(drv->reg_phy + EXYNOS_5250_USBOTGSYS); in exynos5250_power_on() 219 otg &= ~EXYNOS_5250_USBOTGSYS_FSEL_MASK; in exynos5250_power_on() 220 otg |= drv->ref_reg_val << EXYNOS_5250_USBOTGSYS_FSEL_SHIFT; in exynos5250_power_on() 222 otg &= ~(EXYNOS_5250_USBOTGSYS_FORCE_SUSPEND | in exynos5250_power_on() 225 otg |= EXYNOS_5250_USBOTGSYS_PHY_SW_RST | in exynos5250_power_on() 230 otg &= ~EXYNOS_5250_USBOTGSYS_REFCLKSEL_MASK; in exynos5250_power_on() 231 otg |= EXYNOS_5250_REFCLKSEL_CLKCORE << in exynos5250_power_on() 233 writel(otg, drv->reg_phy + EXYNOS_5250_USBOTGSYS); in exynos5250_power_on() 235 otg &= ~(EXYNOS_5250_USBOTGSYS_PHY_SW_RST | in exynos5250_power_on() [all …]
|
D | phy-omap-usb2.c | 61 static int omap_usb_set_vbus(struct usb_otg *otg, bool enabled) in omap_usb_set_vbus() argument 63 struct omap_usb *phy = phy_to_omapusb(otg->usb_phy); in omap_usb_set_vbus() 71 static int omap_usb_start_srp(struct usb_otg *otg) in omap_usb_start_srp() argument 73 struct omap_usb *phy = phy_to_omapusb(otg->usb_phy); in omap_usb_start_srp() 81 static int omap_usb_set_host(struct usb_otg *otg, struct usb_bus *host) in omap_usb_set_host() argument 83 otg->host = host; in omap_usb_set_host() 85 otg->state = OTG_STATE_UNDEFINED; in omap_usb_set_host() 90 static int omap_usb_set_peripheral(struct usb_otg *otg, in omap_usb_set_peripheral() argument 93 otg->gadget = gadget; in omap_usb_set_peripheral() 95 otg->state = OTG_STATE_UNDEFINED; in omap_usb_set_peripheral() [all …]
|
D | phy-dm816x-usb.c | 62 static int dm816x_usb_phy_set_host(struct usb_otg *otg, struct usb_bus *host) in dm816x_usb_phy_set_host() argument 64 otg->host = host; in dm816x_usb_phy_set_host() 66 otg->state = OTG_STATE_UNDEFINED; in dm816x_usb_phy_set_host() 71 static int dm816x_usb_phy_set_peripheral(struct usb_otg *otg, in dm816x_usb_phy_set_peripheral() argument 74 otg->gadget = gadget; in dm816x_usb_phy_set_peripheral() 76 otg->state = OTG_STATE_UNDEFINED; in dm816x_usb_phy_set_peripheral() 190 struct usb_otg *otg; in dm816x_usb_phy_probe() local 225 otg = devm_kzalloc(&pdev->dev, sizeof(*otg), GFP_KERNEL); in dm816x_usb_phy_probe() 226 if (!otg) in dm816x_usb_phy_probe() 232 phy->phy.otg = otg; in dm816x_usb_phy_probe() [all …]
|
D | phy-twl4030-usb.c | 609 static int twl4030_set_peripheral(struct usb_otg *otg, in twl4030_set_peripheral() argument 612 if (!otg) in twl4030_set_peripheral() 615 otg->gadget = gadget; in twl4030_set_peripheral() 617 otg->state = OTG_STATE_UNDEFINED; in twl4030_set_peripheral() 622 static int twl4030_set_host(struct usb_otg *otg, struct usb_bus *host) in twl4030_set_host() argument 624 if (!otg) in twl4030_set_host() 627 otg->host = host; in twl4030_set_host() 629 otg->state = OTG_STATE_UNDEFINED; in twl4030_set_host() 652 struct usb_otg *otg; in twl4030_usb_probe() local 670 otg = devm_kzalloc(&pdev->dev, sizeof(*otg), GFP_KERNEL); in twl4030_usb_probe() [all …]
|
/linux-4.1.27/arch/arm/mach-pxa/ |
D | pxa3xx-ulpi.c | 36 struct usb_phy *otg; member 82 static int pxa310_ulpi_read(struct usb_phy *otg, u32 reg) in pxa310_ulpi_read() argument 101 static int pxa310_ulpi_write(struct usb_phy *otg, u32 val, u32 reg) in pxa310_ulpi_write() argument 142 err = usb_phy_init(u2d->otg); in pxa310_start_otg_host_transcvr() 148 err = otg_set_vbus(u2d->otg->otg, 1); in pxa310_start_otg_host_transcvr() 154 err = otg_set_host(u2d->otg->otg, host); in pxa310_start_otg_host_transcvr() 192 otg_set_host(u2d->otg->otg, NULL); in pxa310_stop_otg_hc() 193 otg_set_vbus(u2d->otg->otg, 0); in pxa310_stop_otg_hc() 194 usb_phy_shutdown(u2d->otg); in pxa310_stop_otg_hc() 224 u2d->otg = otg_ulpi_create(&pxa310_ulpi_access_ops, ulpi_mode); in pxa310_otg_init() [all …]
|
/linux-4.1.27/drivers/usb/musb/ |
D | musb_virthub.c | 72 musb->xceiv->otg->state = OTG_STATE_A_HOST; in musb_host_finish_resume() 79 struct usb_otg *otg = musb->xceiv->otg; in musb_port_suspend() local 110 switch (musb->xceiv->otg->state) { in musb_port_suspend() 112 musb->xceiv->otg->state = OTG_STATE_A_SUSPEND; in musb_port_suspend() 113 musb->is_active = otg->host->b_hnp_enable; in musb_port_suspend() 121 musb->xceiv->otg->state = OTG_STATE_B_WAIT_ACON; in musb_port_suspend() 122 musb->is_active = otg->host->b_hnp_enable; in musb_port_suspend() 127 usb_otg_state_string(musb->xceiv->otg->state)); in musb_port_suspend() 148 if (musb->xceiv->otg->state == OTG_STATE_B_IDLE) { in musb_port_reset() 219 struct usb_otg *otg = musb->xceiv->otg; in musb_root_disconnect() local [all …]
|
D | omap2430.c | 68 switch (musb->xceiv->otg->state) { in musb_do_idle() 73 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in musb_do_idle() 76 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in musb_do_idle() 93 musb->xceiv->otg->state = OTG_STATE_A_HOST; in musb_do_idle() 99 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in musb_do_idle() 101 musb->xceiv->otg->state = OTG_STATE_A_WAIT_BCON; in musb_do_idle() 119 && (musb->xceiv->otg->state == OTG_STATE_A_WAIT_BCON))) { in omap2430_musb_try_idle() 121 usb_otg_state_string(musb->xceiv->otg->state)); in omap2430_musb_try_idle() 138 usb_otg_state_string(musb->xceiv->otg->state), in omap2430_musb_try_idle() 145 struct usb_otg *otg = musb->xceiv->otg; in omap2430_musb_set_vbus() local [all …]
|
D | da8xx.c | 201 usb_otg_state_string(musb->xceiv->otg->state)); in otg_timer() 204 switch (musb->xceiv->otg->state) { in otg_timer() 211 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in otg_timer() 214 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in otg_timer() 229 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VRISE; in otg_timer() 251 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in otg_timer() 268 musb->xceiv->otg->state == OTG_STATE_A_WAIT_BCON)) { in da8xx_musb_try_idle() 270 usb_otg_state_string(musb->xceiv->otg->state)); in da8xx_musb_try_idle() 283 usb_otg_state_string(musb->xceiv->otg->state), in da8xx_musb_try_idle() 292 struct usb_otg *otg = musb->xceiv->otg; in da8xx_musb_interrupt() local [all …]
|
D | am35x.c | 152 usb_otg_state_string(musb->xceiv->otg->state)); in otg_timer() 155 switch (musb->xceiv->otg->state) { in otg_timer() 162 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in otg_timer() 165 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in otg_timer() 170 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VRISE; in otg_timer() 179 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in otg_timer() 196 musb->xceiv->otg->state == OTG_STATE_A_WAIT_BCON)) { in am35x_musb_try_idle() 198 usb_otg_state_string(musb->xceiv->otg->state)); in am35x_musb_try_idle() 211 usb_otg_state_string(musb->xceiv->otg->state), in am35x_musb_try_idle() 223 struct usb_otg *otg = musb->xceiv->otg; in am35x_musb_interrupt() local [all …]
|
D | tusb6010.c | 343 if (x->otg->default_a || mA < (musb->min_power << 1)) in tusb_draw_power() 464 switch (musb->xceiv->otg->state) { in musb_do_idle() 470 usb_otg_state_string(musb->xceiv->otg->state)); in musb_do_idle() 523 && (musb->xceiv->otg->state == OTG_STATE_A_WAIT_BCON))) { in tusb_musb_try_idle() 525 usb_otg_state_string(musb->xceiv->otg->state)); in tusb_musb_try_idle() 542 usb_otg_state_string(musb->xceiv->otg->state), in tusb_musb_try_idle() 559 struct usb_otg *otg = musb->xceiv->otg; in tusb_musb_set_vbus() local 572 otg->default_a = 1; in tusb_musb_set_vbus() 573 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VRISE; in tusb_musb_set_vbus() 586 switch (musb->xceiv->otg->state) { in tusb_musb_set_vbus() [all …]
|
D | davinci.c | 217 usb_otg_state_string(musb->xceiv->otg->state)); in otg_timer() 220 switch (musb->xceiv->otg->state) { in otg_timer() 231 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VRISE; in otg_timer() 254 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in otg_timer() 267 struct usb_otg *otg = musb->xceiv->otg; in davinci_musb_interrupt() local 328 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VFALL; in davinci_musb_interrupt() 333 otg->default_a = 1; in davinci_musb_interrupt() 334 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VRISE; in davinci_musb_interrupt() 340 otg->default_a = 0; in davinci_musb_interrupt() 341 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in davinci_musb_interrupt() [all …]
|
D | musb_core.c | 448 switch (musb->xceiv->otg->state) { in musb_otg_timer_func() 452 musb->xceiv->otg->state = OTG_STATE_B_PERIPHERAL; in musb_otg_timer_func() 458 usb_otg_state_string(musb->xceiv->otg->state)); in musb_otg_timer_func() 460 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VFALL; in musb_otg_timer_func() 464 usb_otg_state_string(musb->xceiv->otg->state)); in musb_otg_timer_func() 479 usb_otg_state_string(musb->xceiv->otg->state)); in musb_hnp_stop() 481 switch (musb->xceiv->otg->state) { in musb_hnp_stop() 485 usb_otg_state_string(musb->xceiv->otg->state)); in musb_hnp_stop() 491 musb->xceiv->otg->state = OTG_STATE_B_PERIPHERAL; in musb_hnp_stop() 500 usb_otg_state_string(musb->xceiv->otg->state)); in musb_hnp_stop() [all …]
|
D | musb_dsps.c | 182 musb->xceiv->otg->state == OTG_STATE_A_WAIT_BCON)) { in dsps_musb_try_idle() 184 usb_otg_state_string(musb->xceiv->otg->state)); in dsps_musb_try_idle() 204 usb_otg_state_string(musb->xceiv->otg->state), in dsps_musb_try_idle() 229 if (musb->xceiv->otg->state == OTG_STATE_B_IDLE && in dsps_musb_enable() 270 usb_otg_state_string(musb->xceiv->otg->state)); in otg_timer() 273 switch (musb->xceiv->otg->state) { in otg_timer() 282 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in otg_timer() 285 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in otg_timer() 294 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VRISE; in otg_timer() 357 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VFALL; in dsps_interrupt() [all …]
|
D | ux500.c | 59 if (musb->xceiv->otg->state == OTG_STATE_A_IDLE) { in ux500_musb_set_vbus() 78 musb->xceiv->otg->default_a = 1; in ux500_musb_set_vbus() 79 musb->xceiv->otg->state = OTG_STATE_A_WAIT_VRISE; in ux500_musb_set_vbus() 89 musb->xceiv->otg->default_a = 0; in ux500_musb_set_vbus() 105 usb_otg_state_string(musb->xceiv->otg->state), in ux500_musb_set_vbus() 115 event, usb_otg_state_string(musb->xceiv->otg->state)); in musb_otg_notifications() 130 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in musb_otg_notifications()
|
D | blackfin.c | 223 if ((musb->xceiv->otg->state == OTG_STATE_B_IDLE in blackfin_interrupt() 224 || musb->xceiv->otg->state == OTG_STATE_A_WAIT_BCON) || in blackfin_interrupt() 243 switch (musb->xceiv->otg->state) { in musb_conn_timer_handler() 257 musb->xceiv->otg->state = OTG_STATE_A_WAIT_BCON; in musb_conn_timer_handler() 267 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in musb_conn_timer_handler() 283 musb->xceiv->otg->state = OTG_STATE_A_WAIT_BCON; in musb_conn_timer_handler() 318 usb_otg_state_string(musb->xceiv->otg->state)); in musb_conn_timer_handler() 324 usb_otg_state_string(musb->xceiv->otg->state)); in musb_conn_timer_handler() 345 usb_otg_state_string(musb->xceiv->otg->state), in bfin_musb_set_vbus()
|
D | musb_gadget.c | 1549 switch (musb->xceiv->otg->state) { in musb_gadget_wakeup() 1579 otg_start_srp(musb->xceiv->otg); in musb_gadget_wakeup() 1590 usb_otg_state_string(musb->xceiv->otg->state)); in musb_gadget_wakeup() 1791 musb->xceiv->otg->default_a = 0; in musb_gadget_setup() 1792 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in musb_gadget_setup() 1840 struct usb_otg *otg = musb->xceiv->otg; in musb_gadget_start() local 1857 otg_set_peripheral(otg, &musb->g); in musb_gadget_start() 1858 musb->xceiv->otg->state = OTG_STATE_B_IDLE; in musb_gadget_start() 1904 musb->xceiv->otg->state = OTG_STATE_UNDEFINED; in musb_gadget_stop() 1906 otg_set_peripheral(musb->xceiv->otg, NULL); in musb_gadget_stop() [all …]
|
D | musb_host.c | 2466 switch (musb->xceiv->otg->state) { in musb_bus_suspend() 2476 musb->xceiv->otg->state = OTG_STATE_A_WAIT_BCON; in musb_bus_suspend() 2484 usb_otg_state_string(musb->xceiv->otg->state)); in musb_bus_suspend() 2679 musb->xceiv->otg->default_a = 1; in musb_host_setup() 2680 musb->xceiv->otg->state = OTG_STATE_A_IDLE; in musb_host_setup() 2682 otg_set_host(musb->xceiv->otg, &hcd->self); in musb_host_setup() 2684 musb->xceiv->otg->host = &hcd->self; in musb_host_setup()
|
/linux-4.1.27/drivers/usb/host/ |
D | ehci-mv.c | 32 struct usb_phy *otg; member 211 ehci_mv->otg = devm_usb_get_phy(&pdev->dev, USB_PHY_TYPE_USB2); in mv_ehci_probe() 212 if (IS_ERR(ehci_mv->otg)) { in mv_ehci_probe() 213 retval = PTR_ERR(ehci_mv->otg); in mv_ehci_probe() 224 retval = otg_set_host(ehci_mv->otg->otg, &hcd->self); in mv_ehci_probe() 275 if (!IS_ERR_OR_NULL(ehci_mv->otg)) in mv_ehci_remove() 276 otg_set_host(ehci_mv->otg->otg, NULL); in mv_ehci_remove()
|
D | ehci-mxc.c | 130 if (pdata->otg) { in ehci_mxc_drv_probe() 131 pdata->otg->io_priv = hcd->regs + ULPI_VIEWPORT_OFFSET; in ehci_mxc_drv_probe() 132 ret = usb_phy_init(pdata->otg); in ehci_mxc_drv_probe() 138 ret = otg_set_vbus(pdata->otg->otg, 1); in ehci_mxc_drv_probe() 181 if (pdata && pdata->otg) in ehci_mxc_drv_remove() 182 usb_phy_shutdown(pdata->otg); in ehci_mxc_drv_remove()
|
D | ohci-omap.c | 183 otg_start_hnp(hcd->usb_phy->otg); in start_hnp() 186 hcd->usb_phy->otg->state = OTG_STATE_A_SUSPEND; in start_hnp() 202 int need_transceiver = (config->otg != 0); in ohci_omap_reset() 207 if (config->otg) { in ohci_omap_reset() 208 hcd->self.otg_port = config->otg; in ohci_omap_reset() 225 int status = otg_set_host(hcd->usb_phy->otg, in ohci_omap_reset() 252 if (config->otg || config->rwc) { in ohci_omap_reset() 403 (void) otg_set_host(hcd->usb_phy->otg, 0); in usb_hcd_omap_remove()
|
D | ehci-tegra.c | 480 u_phy->otg = devm_kzalloc(&pdev->dev, sizeof(struct usb_otg), in tegra_ehci_probe() 482 if (!u_phy->otg) { in tegra_ehci_probe() 486 u_phy->otg->host = hcd_to_bus(hcd); in tegra_ehci_probe() 501 otg_set_host(u_phy->otg, &hcd->self); in tegra_ehci_probe() 513 otg_set_host(u_phy->otg, NULL); in tegra_ehci_probe() 529 otg_set_host(hcd->usb_phy->otg, NULL); in tegra_ehci_remove()
|
D | ehci-msm.c | 122 ret = otg_set_host(phy->otg, &hcd->self); in ehci_msm_probe() 155 otg_set_host(hcd->usb_phy->otg, NULL); in ehci_msm_remove()
|
D | ehci-fsl.c | 138 retval = otg_set_host(hcd->usb_phy->otg, in usb_hcd_fsl_probe() 179 otg_set_host(hcd->usb_phy->otg, NULL); in usb_hcd_fsl_remove()
|
D | oxu210hp-hcd.c | 3721 void *base, int irq, int otg) in oxu_create() argument 3730 oxu_writel(base + (otg ? OXU_OTG_CORE_OFFSET : OXU_SPH_CORE_OFFSET), in oxu_create() 3735 otg ? "oxu210hp_otg" : "oxu210hp_sph"); in oxu_create() 3746 oxu->is_otg = otg; in oxu_create()
|
D | ehci-hub.c | 926 otg_start_hnp(hcd->usb_phy->otg); in ehci_hub_control()
|
/linux-4.1.27/drivers/usb/common/ |
D | usb-otg-fsm.c | 127 if (fsm->otg->state == new_state) in otg_set_state() 130 otg_leave_state(fsm, fsm->otg->state); in otg_set_state() 170 usb_bus_start_enum(fsm->otg->host, in otg_set_state() 171 fsm->otg->host->otg_port); in otg_set_state() 239 fsm->otg->state = new_state; in otg_set_state() 250 state = fsm->otg->state; in otg_statemachine() 265 else if (fsm->b_sess_vld && fsm->otg->gadget) in otg_statemachine() 278 else if (fsm->b_bus_req && fsm->otg-> in otg_statemachine() 324 fsm->otg->host->b_hnp_enable) in otg_statemachine() 332 if (!fsm->b_conn && fsm->otg->host->b_hnp_enable) in otg_statemachine() [all …]
|
D | Makefile | 9 obj-$(CONFIG_USB_OTG_FSM) += usb-otg-fsm.o
|
/linux-4.1.27/arch/arm/mach-imx/ |
D | mx31moboard-devboard.c | 161 static int devboard_isp1105_init(struct usb_phy *otg) in devboard_isp1105_init() argument 180 static int devboard_isp1105_set_vbus(struct usb_otg *otg, bool on) in devboard_isp1105_set_vbus() argument 204 phy->otg = kzalloc(sizeof(struct usb_otg), GFP_KERNEL); in devboard_usbh1_init() 205 if (!phy->otg) { in devboard_usbh1_init() 212 phy->otg->set_vbus = devboard_isp1105_set_vbus; in devboard_usbh1_init() 214 usbh1_pdata.otg = phy; in devboard_usbh1_init()
|
D | mx31moboard-marxbot.c | 275 static int marxbot_isp1105_init(struct usb_phy *otg) in marxbot_isp1105_init() argument 294 static int marxbot_isp1105_set_vbus(struct usb_otg *otg, bool on) in marxbot_isp1105_set_vbus() argument 318 phy->otg = kzalloc(sizeof(struct usb_otg), GFP_KERNEL); in marxbot_usbh1_init() 319 if (!phy->otg) { in marxbot_usbh1_init() 326 phy->otg->set_vbus = marxbot_isp1105_set_vbus; in marxbot_usbh1_init() 328 usbh1_pdata.otg = phy; in marxbot_usbh1_init()
|
D | mach-pca100.c | 391 otg_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in pca100_init() 394 if (otg_pdata.otg) in pca100_init() 401 usbh2_pdata.otg = imx_otg_ulpi_create( in pca100_init() 404 if (usbh2_pdata.otg) in pca100_init()
|
D | mx31moboard-smartbot.c | 139 otg_host_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in smartbot_otg_host_init() 141 if (!otg_host_pdata.otg) in smartbot_otg_host_init()
|
D | mach-armadillo5x0.c | 545 usbotg_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in armadillo5x0_init() 547 if (usbotg_pdata.otg) in armadillo5x0_init() 549 usbh2_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in armadillo5x0_init() 551 if (usbh2_pdata.otg) in armadillo5x0_init()
|
D | mach-mx31lite.c | 263 usbh2_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in mx31lite_init() 265 if (usbh2_pdata.otg) in mx31lite_init()
|
D | mach-pcm037.c | 667 otg_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in pcm037_init() 669 if (otg_pdata.otg) in pcm037_init() 673 usbh2_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in pcm037_init() 675 if (usbh2_pdata.otg) in pcm037_init()
|
D | mach-mx31lilly.c | 201 usbh2_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in lilly1131_usb_init() 203 if (usbh2_pdata.otg) in lilly1131_usb_init()
|
D | mach-mx31_3ds.c | 721 otg_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in mx31_3ds_init() 723 if (otg_pdata.otg) in mx31_3ds_init() 726 usbh2_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in mx31_3ds_init() 728 if (usbh2_pdata.otg) in mx31_3ds_init()
|
D | mach-pcm043.c | 379 otg_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in pcm043_init() 381 if (otg_pdata.otg) in pcm043_init()
|
D | mach-mx27_3ds.c | 502 otg_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in mx27pdk_init() 505 if (otg_pdata.otg) in mx27pdk_init()
|
D | mach-mx31moboard.c | 432 usbh2_pdata.otg = imx_otg_ulpi_create(ULPI_OTG_DRVVBUS | in moboard_usbh2_init() 434 if (!usbh2_pdata.otg) in moboard_usbh2_init()
|
/linux-4.1.27/Documentation/devicetree/bindings/usb/ |
D | msm-hsusb.txt | 22 "qcom,usb-otg-ci" for chipsets with ChipIdea 45nm PHY 23 "qcom,usb-otg-snps" for chipsets with Synopsys 28nm PHY 48 - qcom,otg-control: OTG control (VBUS and ID notifications) can be one of 53 - dr_mode: One of "host", "peripheral" or "otg". Defaults to "otg" 75 compatible = "qcom,usb-otg-snps"; 92 qcom,otg-control = <1>;
|
D | dwc2.txt | 14 - clock-names: shall be "otg" 21 - dr_mode: shall be one of "host", "peripheral" and "otg" 35 clock-names = "otg";
|
D | generic.txt | 11 "peripheral" and "otg". In case this attribute isn't 23 dr_mode = "otg";
|
D | samsung-hsotg.txt | 24 - first entry: must be "otg" 36 clock-names = "otg";
|
D | ux500-usb.txt | 8 or both "otg" 23 dr_mode = "otg";
|
D | ci-hdrc-imx.txt | 13 - dr_mode: One of "host", "peripheral" or "otg". Defaults to "otg"
|
D | fsl-usb.txt | 27 controllers. Can be "host", "peripheral", or "otg". Default to 66 dr_mode = "otg"; 79 dr_mode = "otg";
|
D | twlxxxx-usb.txt | 6 interrupt number is the otg interrupt number that raises ID interrupts when 26 interrupt number is the otg interrupt number that raises ID interrupts
|
D | nvidia,tegra20-usb-phy.txt | 64 "host", "peripheral", or "otg". Defaults to "host" if not defined. 67 otg means it can operate as either ("on the go") 71 VBUS control (required for dr_mode == otg, optional for dr_mode == host):
|
D | exynos-usb.txt | 18 On Exynos5250, port 0 is USB2.0 otg phy 59 On Exynos5250, port 0 is USB2.0 otg phy
|
D | am33xx-usb.txt | 38 - dr_mode: Should be one of "host", "peripheral" or "otg". 108 dr_mode = "otg"
|
D | dwc3-st.txt | 37 is "otg", which isn't supported by this SoC. Valid dr_mode values for dwc3-st are either "host"
|
D | samsung-usbphy.txt | 57 clock-names = "xusbxti", "otg";
|
/linux-4.1.27/drivers/usb/chipidea/ |
D | otg_fsm.c | 339 if (ci->fsm.otg->state == OTG_STATE_B_IDLE) in b_ssend_srp_tmout() 564 ci->fsm.otg->state < OTG_STATE_A_IDLE) in ci_otg_fsm_work() 569 if (ci->fsm.otg->state == OTG_STATE_A_IDLE) { in ci_otg_fsm_work() 590 } else if (ci->fsm.otg->state == OTG_STATE_B_IDLE) { in ci_otg_fsm_work() 599 } else if (ci->fsm.otg->state == OTG_STATE_A_HOST) { in ci_otg_fsm_work() 622 switch (ci->fsm.otg->state) { in ci_otg_fsm_event() 770 ci->otg.phy = ci->phy; in ci_hdrc_otg_fsm_init() 772 ci->otg.usb_phy = ci->usb_phy; in ci_hdrc_otg_fsm_init() 774 ci->otg.gadget = &ci->gadget; in ci_hdrc_otg_fsm_init() 775 ci->fsm.otg = &ci->otg; in ci_hdrc_otg_fsm_init() [all …]
|
D | host.c | 134 struct usb_otg *otg = &ci->otg; in host_start() local 139 otg->host = &hcd->self; in host_start()
|
D | Makefile | 5 ci_hdrc-y := core.o otg.o
|
D | ci.h | 209 struct usb_otg otg; member
|
D | core.c | 867 if ((ci->fsm.otg->state == OTG_STATE_A_IDLE) && in ci_otg_fsm_suspend_for_srp() 879 if ((ci->fsm.otg->state == OTG_STATE_A_IDLE) && in ci_otg_fsm_wakeup_by_srp()
|
D | debug.c | 227 usb_otg_state_string(ci->otg.state)); in ci_otg_show()
|
D | udc.c | 1739 if (ci->fsm.otg->state == OTG_STATE_A_PERIPHERAL) { in ci_udc_stop_for_otg_fsm() 1742 } else if (ci->fsm.otg->state == OTG_STATE_B_PERIPHERAL) { in ci_udc_stop_for_otg_fsm() 1744 ci->fsm.otg->state = OTG_STATE_UNDEFINED; in ci_udc_stop_for_otg_fsm()
|
/linux-4.1.27/drivers/power/ |
D | isp1704_charger.c | 271 if (isp->phy->otg->gadget) in isp1704_charger_work() 272 usb_gadget_connect(isp->phy->otg->gadget); in isp1704_charger_work() 301 if (isp->phy->otg->gadget) in isp1704_charger_work() 302 usb_gadget_disconnect(isp->phy->otg->gadget); in isp1704_charger_work() 493 if (isp->phy->otg->gadget) in isp1704_charger_probe() 494 usb_gadget_disconnect(isp->phy->otg->gadget); in isp1704_charger_probe() 501 !isp->phy->otg->default_a) in isp1704_charger_probe()
|
/linux-4.1.27/arch/arm/mach-omap1/ |
D | usb.c | 87 if (config->otg) in omap_otg_init() 106 if (config->otg) in omap_otg_init() 107 printk(", Mini-AB on usb%d", config->otg - 1); in omap_otg_init() 127 if (config->otg || config->register_dev) { in omap_otg_init() 140 if (config->otg || config->register_host) { in omap_otg_init() 153 if (config->otg) { in omap_otg_init()
|
D | board-generic.c | 45 .otg = 1,
|
D | board-nokia770.c | 154 .otg = 1,
|
D | board-h2.c | 347 .otg = 2,
|
D | board-sx1.c | 289 .otg = 0,
|
D | board-innovator.c | 313 .otg = 2,
|
D | board-h3.c | 367 .otg = 2,
|
D | board-htcherald.c | 386 .otg = 0,
|
/linux-4.1.27/include/linux/platform_data/ |
D | usb-ehci-mxc.h | 9 struct usb_phy *otg; member
|
D | usb-omap1.h | 24 u8 otg; /* port number, 1-based: usb1 == 2 */ member
|
/linux-4.1.27/Documentation/usb/ |
D | chipidea.txt | 9 If you want to check some internal variables for otg fsm, 11 can show otg fsm variables and some controller registers value: 12 cat /sys/kernel/debug/ci_hdrc.0/otg
|
/linux-4.1.27/Documentation/devicetree/bindings/pinctrl/ |
D | nvidia,tegra124-xusb-padctl.txt | 59 - otg-0, otg-1, otg-2:
|
/linux-4.1.27/arch/arm/boot/dts/ |
D | rk3188-radxarock.dts | 71 vcc_otg: usb-otg-regulator { 77 regulator-name = "otg-vbus"; 310 otg_vbus_drv: otg-vbus-drv {
|
D | dra74x.dtsi | 71 dr_mode = "otg";
|
D | imx51-digi-connectcore-jsk.dts | 49 dr_mode = "otg";
|
D | imx28-cfa10036.dts | 46 usb0_otg_cfa10036: otg-10036@0 {
|
D | imx35-eukrea-mbimxsd35-baseboard.dts | 161 dr_mode = "otg";
|
D | tegra30-colibri-eval-v3.dts | 101 dr_mode = "otg";
|
D | imx27-pdk.dts | 118 dr_mode = "otg";
|
D | imx25-eukrea-mbimxsd25-baseboard.dts | 183 dr_mode = "otg";
|
D | rk3xxx.dtsi | 146 clock-names = "otg"; 155 clock-names = "otg";
|
D | imx28-apf28dev.dts | 71 usb0_otg_apf28dev: otg-apf28dev@0 {
|
D | rk3066a-rayeager.dts | 141 vcc_otg: usb-otg-regulator { 407 otg_drv: otg-drv {
|
D | rk3288-firefly.dtsi | 150 vcc_otg_5v: usb-otg-regulator { 418 otg_vbus_drv: otg-vbus-drv {
|
D | imx27-eukrea-cpuimx27.dtsi | 96 dr_mode = "otg";
|
D | imx51-eukrea-mbimxsd51-baseboard.dts | 285 dr_mode = "otg";
|
D | imx27-phytec-phycore-som.dtsi | 319 dr_mode = "otg";
|
D | imx25-pdk.dts | 313 dr_mode = "otg";
|
D | imx6qdl-cubox-i.dtsi | 90 reg_usbotg_vbus: usb-otg-vbus {
|
D | tegra114-tn7.dts | 260 /* Should be changed to "otg" once we have vbus_supply */
|
D | imx6qdl-hummingboard.dtsi | 80 reg_usbotg_vbus: usb-otg-vbus {
|
D | socfpga.dtsi | 750 clock-names = "otg"; 761 clock-names = "otg";
|
D | exynos5422-odroidxu3.dts | 355 dr_mode = "otg";
|
D | bcm21664.dtsi | 345 clock-names = "otg";
|
D | am33xx.dtsi | 518 dr_mode = "otg"; 565 dr_mode = "otg";
|
D | bcm11351.dtsi | 412 clock-names = "otg";
|
D | vexpress-v2m-rs1.dtsi | 65 port1-otg;
|
D | vexpress-v2m.dtsi | 64 port1-otg;
|
D | imx6dl-riotboard.dts | 301 dr_mode = "otg";
|
D | am4372.dtsi | 866 dr_mode = "otg"; 890 dr_mode = "otg";
|
D | tegra20-seaboard.dts | 728 dr_mode = "otg"; 734 dr_mode = "otg";
|
D | dra7.dtsi | 1298 dr_mode = "otg"; 1321 dr_mode = "otg"; 1344 dr_mode = "otg";
|
D | imx51-babbage.dts | 418 dr_mode = "otg";
|
D | rk3288.dtsi | 436 clock-names = "otg"; 448 clock-names = "otg";
|
D | exynos3250.dtsi | 278 clock-names = "otg";
|
D | s5pv210.dtsi | 427 clock-names = "otg";
|
D | exynos4415.dtsi | 276 clock-names = "otg";
|
D | atlas7.dtsi | 387 dr_mode = "otg";
|
D | exynos4.dtsi | 339 clock-names = "otg";
|
D | ste-dbx5x0.dtsi | 249 dr_mode = "otg";
|
D | tegra114-roth.dts | 990 /* Should be changed to "otg" once we have vbus_supply */
|
/linux-4.1.27/drivers/pinctrl/ |
D | pinctrl-tegra-xusb.c | 843 TEGRA124_LANE("otg-0", 0x004, 0, 0x3, 0, otg), 844 TEGRA124_LANE("otg-1", 0x004, 2, 0x3, 0, otg), 845 TEGRA124_LANE("otg-2", 0x004, 4, 0x3, 0, otg),
|
/linux-4.1.27/arch/powerpc/boot/dts/ |
D | mpc5121.dtsi | 304 dr_mode = "otg"; 317 dr_mode = "otg";
|
D | mpc8349emitxgp.dts | 148 dr_mode = "otg";
|
D | asp834x-redboot.dts | 180 dr_mode = "otg";
|
D | mpc834x_mds.dts | 166 dr_mode = "otg";
|
D | canyonlands.dts | 181 compatible = "amcc,dwc-otg";
|
/linux-4.1.27/drivers/usb/gadget/ |
D | configfs.c | 59 struct usb_otg_descriptor otg; member 1514 gi->otg.bLength = sizeof(struct usb_otg_descriptor); in gadgets_make() 1515 gi->otg.bDescriptorType = USB_DT_OTG; in gadgets_make() 1516 gi->otg.bmAttributes = USB_OTG_SRP | USB_OTG_HNP; in gadgets_make()
|
/linux-4.1.27/drivers/usb/gadget/udc/ |
D | omap_udc.c | 1160 retval = otg_start_srp(udc->transceiver->otg); in omap_wakeup() 2078 status = otg_set_peripheral(udc->transceiver->otg, in omap_udc_start() 2117 (void) otg_set_peripheral(udc->transceiver->otg, NULL); in omap_udc_stop() 2770 config->otg ? ", Mini-AB" : ""); in omap_udc_probe() 2800 else if (config->otg) { in omap_udc_probe() 2857 udc->gadget.is_otg = (config->otg != 0); in omap_udc_probe()
|
D | s3c-hsudc.c | 1165 ret = otg_set_peripheral(hsudc->transceiver->otg, in s3c_hsudc_start() 1211 (void) otg_set_peripheral(hsudc->transceiver->otg, NULL); in s3c_hsudc_stop()
|
D | pxa25x_udc.c | 1269 retval = otg_set_peripheral(dev->transceiver->otg, in pxa25x_udc_start() 1345 (void) otg_set_peripheral(dev->transceiver->otg, NULL); in pxa25x_udc_stop()
|
D | pxa27x_udc.c | 1802 retval = otg_set_peripheral(udc->transceiver->otg, in pxa27x_udc_start() 1856 return otg_set_peripheral(udc->transceiver->otg, NULL); in pxa27x_udc_stop()
|
D | fsl_udc_core.c | 1961 udc_controller->transceiver->otg, in fsl_udc_start() 1987 otg_set_peripheral(udc_controller->transceiver->otg, NULL); in fsl_udc_stop()
|
D | mv_udc_core.c | 1371 retval = otg_set_peripheral(udc->transceiver->otg, in mv_udc_start()
|
/linux-4.1.27/drivers/usb/dwc2/ |
D | gadget.c | 3068 otg_set_peripheral(hsotg->uphy->otg, &hsotg->gadget); in s3c_hsotg_udc_start() 3123 otg_set_peripheral(hsotg->uphy->otg, NULL); in s3c_hsotg_udc_stop()
|
/linux-4.1.27/ |
D | MAINTAINERS | 10358 F: drivers/usb/common/usb-otg-fsm.c
|