Home
last modified time | relevance | path

Searched +full:usb +full:- +full:role +full:- +full:switch (Results 1 – 25 of 165) sorted by relevance

1234567

/linux/drivers/usb/roles/
H A Dclass.c1 // SPDX-License-Identifier: GPL-2.0
3 * USB Role Switch Support
11 #include <linux/usb/role.h>
28 enum usb_role role; member
46 ret = sysfs_create_link(&dev->kobj, &connector->kobj, "connector"); in connector_bind()
50 ret = sysfs_create_link(&connector->kobj, &dev->kobj, "usb-role-switch"); in connector_bind()
52 sysfs_remove_link(&dev->kobj, "connector"); in connector_bind()
59 sysfs_remove_link(&connector->kobj, "usb-role-switch"); in connector_unbind()
60 sysfs_remove_link(&dev->kobj, "connector"); in connector_unbind()
69 * usb_role_switch_set_role - Set USB role for a switch
[all …]
H A DKconfig1 # SPDX-License-Identifier: GPL-2.0
4 tristate "USB Role Switch Support"
6 USB Role Switch is a device that can select the USB role - host or
7 device - for a USB port (connector). In most cases dual-role capable
8 USB controller will also represent the switch, but on some platforms
9 multiplexer/demultiplexer switch is used to route the data lines on
10 the USB connector between separate USB host and device controllers.
12 Say Y here if your USB connectors support both device and host roles.
19 tristate "Intel XHCI USB Role Switch"
22 Driver for the internal USB role switch for switching the USB data
[all …]
/linux/Documentation/devicetree/bindings/usb/
H A Dmediatek,mtu3.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
4 ---
5 $id: http://devicetree.org/schemas/usb/mediatek,mtu3.yaml#
6 $schema: http://devicetree.org/meta-schemas/core.yaml#
11 - Chunfeng Yun <chunfeng.yun@mediatek.com>
14 - $ref: usb-drd.yaml
23 - enum:
24 - mediatek,mt2712-mtu3
25 - mediatek,mt8173-mtu3
26 - mediatek,mt8183-mtu3
[all …]
H A Dmediatek,musb.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
4 ---
5 $id: http://devicetree.org/schemas/usb/mediatek,musb.yaml#
6 $schema: http://devicetree.org/meta-schemas/core.yaml#
11 - Min Guo <min.guo@mediatek.com>
15 pattern: '^usb@[0-9a-f]+$'
19 - enum:
20 - mediatek,mt8516-musb
21 - mediatek,mt2701-musb
22 - mediatek,mt7623-musb
[all …]
H A Dusb-drd.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
4 $id: http://devicetree.org/schemas/usb/usb-drd.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Generic USB OTG Controller
10 - Greg Kroah-Hartman <gregkh@linuxfoundation.org>
13 otg-rev:
15 Tells usb driver the release number of the OTG and EH supplement with
16 which the device and its descriptors are compliant, in binary-coded
18 features (HNP/SRP/ADP) is enabled. If ADP is required, otg-rev should be
[all …]
H A Ddwc2.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
4 $id: http://devicetree.org/schemas/usb/dwc2.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: DesignWare HS OTG USB 2.0 controller
10 - Rob Herring <robh@kernel.org>
13 - $ref: usb-drd.yaml#
14 - $ref: usb-hcd.yaml#
19 - const: brcm,bcm2835-usb
20 - const: hisilicon,hi6220-usb
[all …]
H A Drealtek,rtd-dwc3.yaml1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
4 ---
5 $id: http://devicetree.org/schemas/usb/realtek,rtd-dwc3.yaml#
6 $schema: http://devicetree.org/meta-schemas/core.yaml#
8 title: Realtek DWC3 USB SoC Controller Glue
11 - Stanley Chang <stanley_chang@realtek.com>
14 The Realtek DHC SoC embeds a DWC3 USB IP Core configured for USB 2.0
15 and USB 3.0 in host or dual-role mode.
20 - enum:
21 - realtek,rtd1295-dwc3
[all …]
H A Dmediatek,mt6360-tcpc.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/usb/mediatek,mt6360-tcpc.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Mediatek MT6360 Type-C Port Switch and Power Delivery controller
10 - ChiYuan Huang <cy_huang@richtek.com>
13 Mediatek MT6360 is a multi-functional device. It integrates charger, ADC, flash, RGB indicators,
14 regulators (BUCKs/LDOs), and TypeC Port Switch with Power Delivery controller.
15 This document only describes MT6360 Type-C Port Switch and Power Delivery controller.
20 - mediatek,mt6360-tcpc
[all …]
/linux/Documentation/ABI/testing/
H A Dsysfs-class-usb_role5 Place in sysfs for USB Role Switches. USB Role Switch is a
6 device that can select the data role (host or device) for USB
9 What: /sys/class/usb_role/<switch>/role
13 The current role of the switch. This attribute can be used for
14 requesting role swapping with non-USB Type-C ports. With USB
15 Type-C ports, the ABI defined for USB Type-C connector class
19 - none
20 - host
21 - device
23 What: /sys/class/usb_role/<switch>/connector
[all …]
/linux/include/linux/usb/
H A Drole.h1 // SPDX-License-Identifier: GPL-2.0
17 enum usb_role role);
21 * struct usb_role_switch_desc - USB Role Switch Descriptor
22 * @fwnode: The device node to be associated with the role switch
26 * @set: Callback for setting the role
27 * @get: Callback for getting the role (optional)
28 * @allow_userspace_control: If true userspace may change the role through sysfs
30 * @name: Name for the switch (optional)
32 * @usb2_port and @usb3_port will point to the USB host port and @udc to the USB
33 * device controller behind the USB connector with the role switch. If
[all …]
/linux/drivers/usb/cdns3/
H A DKconfig2 tristate "Cadence USB Support"
3 depends on USB_SUPPORT && (USB || USB_GADGET) && HAS_DMA
8 dual-role controller.
9 It supports: dual-role switch, Host-only, and Peripheral-only.
17 tristate "Cadence USB3 Dual-Role Controller"
20 Say Y here if your system has a Cadence USB3 dual-role controller.
21 It supports: dual-role switch, Host-only, and Peripheral-only.
34 Cadence USBSS-DEV driver.
41 depends on USB=y || USB=USB_CDNS3
51 tristate "Cadence USB3 support on PCIe-based platforms"
[all …]
H A Dcore.h1 /* SPDX-License-Identifier: GPL-2.0 */
5 * Copyright (C) 2017-2018 NXP
6 * Copyright (C) 2018-2019 Cadence.
14 #include <linux/usb/otg.h>
15 #include <linux/usb/role.h>
20 * struct cdns_role_driver - host/gadget role driver
21 * @start: start this role
22 * @stop: stop this role
23 * @suspend: suspend callback for this role
24 * @resume: resume callback for this role
[all …]
/linux/Documentation/usb/
H A Dchipidea.rst2 ChipIdea Highspeed Dual Role Controller Driver
6 -----------------------------------
12 -------------------------
29 otg-rev = <0x0200>;
30 adp-disable;
33 -------------------
38 2) Connect 2 boards with usb cable: one end is micro A plug, the other end
41 The A-device (with micro A plug inserted) should enumerate B-device.
43 3) Role switch
45 On B-device::
[all …]
/linux/drivers/usb/mtu3/
H A Dmtu3.h1 /* SPDX-License-Identifier: GPL-2.0 */
3 * mtu3.h - MediaTek USB3 DRD header
22 #include <linux/usb.h>
23 #include <linux/usb/ch9.h>
24 #include <linux/usb/gadget.h>
25 #include <linux/usb/otg.h>
26 #include <linux/usb/role.h>
35 #define MU3D_EP_TXCR0(epnum) (U3D_TX1CSR0 + (((epnum) - 1) * 0x10))
36 #define MU3D_EP_TXCR1(epnum) (U3D_TX1CSR1 + (((epnum) - 1) * 0x10))
37 #define MU3D_EP_TXCR2(epnum) (U3D_TX1CSR2 + (((epnum) - 1) * 0x10))
[all …]
/linux/Documentation/devicetree/bindings/phy/
H A Dnvidia,tegra194-xusb-padctl.yaml1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
3 ---
4 $id: http://devicetree.org/schemas/phy/nvidia,tegra194-xusb-padctl.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
10 - Thierry Reding <thierry.reding@gmail.com>
11 - Jon Hunter <jonathanh@nvidia.com>
21 Some of the lanes are high-speed lanes, which can be used for PCIe, SATA or
22 super-speed USB. Other lanes are for various types of low-speed, full-speed
23 or high-speed USB (such as UTMI, ULPI and HSIC). The XUSB pad controller
24 contains a software-configurable mux that sits between the I/O controller
[all …]
H A Dnvidia,tegra186-xusb-padctl.yaml1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
3 ---
4 $id: http://devicetree.org/schemas/phy/nvidia,tegra186-xusb-padctl.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
10 - Thierry Reding <thierry.reding@gmail.com>
11 - Jon Hunter <jonathanh@nvidia.com>
21 Some of the lanes are high-speed lanes, which can be used for PCIe, SATA or
22 super-speed USB. Other lanes are for various types of low-speed, full-speed
23 or high-speed USB (such as UTMI, ULPI and HSIC). The XUSB pad controller
24 contains a software-configurable mux that sits between the I/O controller
[all …]
H A Dnvidia,tegra210-xusb-padctl.yaml1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
3 ---
4 $id: http://devicetree.org/schemas/phy/nvidia,tegra210-xusb-padctl.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
10 - Thierry Reding <thierry.reding@gmail.com>
11 - Jon Hunter <jonathanh@nvidia.com>
21 Some of the lanes are high-speed lanes, which can be used for PCIe, SATA or
22 super-speed USB. Other lanes are for various types of low-speed, full-speed
23 or high-speed USB (such as UTMI, ULPI and HSIC). The XUSB pad controller
24 contains a software-configurable mux that sits between the I/O controller
[all …]
/linux/Documentation/driver-api/usb/
H A Dtypec.rst3 USB Type-C connector class
7 ------------
9 The typec class is meant for describing the USB Type-C ports in a system to the
14 The platforms are expected to register every USB Type-C port they have with the
15 class. In a normal case the registration will be done by a USB Type-C or PD PHY
17 USB PD controller or even driver for Thunderbolt3 controller. This document
18 considers the component registering the USB Type-C ports with the class as "port
26 attributes are described in Documentation/ABI/testing/sysfs-class-typec.
29 --------------------
36 "port0-partner". Full path to the device would be
[all …]
/linux/drivers/usb/dwc2/
H A Ddrd.c1 // SPDX-License-Identifier: GPL-2.0
3 * drd.c - DesignWare USB2 DRD Controller Dual-role support
13 #include <linux/usb/role.h>
25 spin_lock_irqsave(&hsotg->lock, flags); in dwc2_ovr_init()
30 if (hsotg->role_sw_default_mode == USB_DR_MODE_HOST) in dwc2_ovr_init()
32 else if (hsotg->role_sw_default_mode == USB_DR_MODE_PERIPHERAL) in dwc2_ovr_init()
36 spin_unlock_irqrestore(&hsotg->lock, flags); in dwc2_ovr_init()
38 dwc2_force_mode(hsotg, (hsotg->dr_mode == USB_DR_MODE_HOST) || in dwc2_ovr_init()
39 (hsotg->role_sw_default_mode == USB_DR_MODE_HOST)); in dwc2_ovr_init()
46 /* Check if A-Session is already in the right state */ in dwc2_ovr_avalid()
[all …]
/linux/drivers/usb/common/
H A Dusb-conn-gpio.c1 // SPDX-License-Identifier: GPL-2.0
3 * USB GPIO Based Connection Detection Driver
9 * Some code borrowed from drivers/extcon/extcon-usb-gpio.c
23 #include <linux/usb/role.h>
36 int conn_id; /* store the IDA-allocated ID */
59 * Role | ID | VBUS
60 * ------------------------------------
67 * - VBUS only - we want to distinguish between [1] and [2], so ID is always 1
68 * - ID only - we want to distinguish between [1] and [4], so VBUS = ID
73 enum usb_role role; in usb_conn_detect_cable() local
[all …]
/linux/drivers/usb/chipidea/
H A Dotg.c1 // SPDX-License-Identifier: GPL-2.0
3 * otg.c - ChipIdea USB IP core OTG driver
15 #include <linux/usb/otg.h>
16 #include <linux/usb/gadget.h>
17 #include <linux/usb/chipidea.h>
25 * hw_read_otgsc - returns otgsc register bits value.
38 cable = &ci->platdata->vbus_extcon; in hw_read_otgsc()
39 if (!IS_ERR(cable->edev) || ci->role_switch) { in hw_read_otgsc()
40 if (cable->changed) in hw_read_otgsc()
45 if (cable->connected) in hw_read_otgsc()
[all …]
H A DKconfig1 # SPDX-License-Identifier: GPL-2.0
4 tristate "ChipIdea Highspeed Dual Role Controller"
12 Say Y here if your system has a dual role high speed USB
14 Dual-role switch (ID, OTG FSM, sysfs), Host-only, and
15 Peripheral-only.
51 tristate "Enable i.MX USB glue driver" if EXPERT
60 tristate "Enable Tegra USB glue driver" if EXPERT
/linux/drivers/extcon/
H A Dextcon-usbc-cros-ec.c1 // SPDX-License-Identifier: GPL-2.0
7 #include <linux/extcon-provider.h>
28 unsigned int dr; /* data role */
29 bool pr; /* power role (true if VBUS enabled) */
49 * cros_ec_pd_command() - Send a command to the EC.
73 return -ENOMEM; in cros_ec_pd_command()
75 msg->version = version; in cros_ec_pd_command()
76 msg->command = command; in cros_ec_pd_command()
77 msg->outsize = outsize; in cros_ec_pd_command()
78 msg->insize = insize; in cros_ec_pd_command()
[all …]
/linux/drivers/usb/phy/
H A DKconfig1 # SPDX-License-Identifier: GPL-2.0
3 # Physical Layer USB driver configuration
5 menu "USB Physical Layer drivers"
12 # USB Transceiver Drivers
15 tristate "AB8500 USB Transceiver Driver"
19 Enable this to support the USB OTG transceiver in AB8500 chip.
24 tristate "Freescale USB OTG Transceiver Driver"
29 Enable this to support Freescale USB OTG transceiver.
32 tristate "Keystone USB PHY Driver"
36 Enable this to support Keystone USB phy. This driver provides
[all …]
/linux/drivers/usb/typec/mux/
H A Dintel_pmc_mux.c1 // SPDX-License-Identifier: GPL-2.0
3 * Driver for Intel PMC USB mux control
14 #include <linux/usb/pd.h>
15 #include <linux/usb/role.h>
16 #include <linux/usb/typec_mux.h>
17 #include <linux/usb/typec_dp.h>
18 #include <linux/usb/typec_tbt.h>
20 #include <linux/usb.h>
141 enum usb_role role; member
169 /* SoC expects the USB Type-C port numbers to start with 0 */ in update_port_status()
[all …]

1234567