Home
last modified time | relevance | path

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

123456789

/kernel/linux/linux-5.10/drivers/usb/roles/
Dclass.c1 // SPDX-License-Identifier: GPL-2.0
3 * USB Role Switch Support
10 #include <linux/usb/role.h>
22 enum usb_role role; member
36 * usb_role_switch_set_role - Set USB role for a switch
37 * @sw: USB role switch
38 * @role: USB role to be switched to
40 * Set USB role @role for @sw.
42 int usb_role_switch_set_role(struct usb_role_switch *sw, enum usb_role role) in usb_role_switch_set_role() argument
49 mutex_lock(&sw->lock); in usb_role_switch_set_role()
[all …]
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 …]
Dintel-xhci-usb-role-switch.c1 // SPDX-License-Identifier: GPL-2.0+
3 * Intel XHCI (Cherry Trail, Broxton and others) USB OTG role switch driver
5 * Copyright (c) 2016-2017 Hans de Goede <hdegoede@redhat.com>
23 #include <linux/usb/role.h>
52 "intel-xhci-usb-sw",
56 enum usb_role role) in intel_xhci_usb_set_role() argument
71 dev_err(data->dev, "Error could not acquire lock\n"); in intel_xhci_usb_set_role()
72 return -EIO; in intel_xhci_usb_set_role()
75 pm_runtime_get_sync(data->dev); in intel_xhci_usb_set_role()
80 * SW_SWITCH_EN bits to be zero for role switch, in intel_xhci_usb_set_role()
[all …]
/kernel/linux/linux-4.19/drivers/usb/roles/
Dclass.c1 // SPDX-License-Identifier: GPL-2.0
3 * USB Role Switch Support
10 #include <linux/usb/role.h>
21 enum usb_role role; member
35 * usb_role_switch_set_role - Set USB role for a switch
36 * @sw: USB role switch
37 * @role: USB role to be switched to
39 * Set USB role @role for @sw.
41 int usb_role_switch_set_role(struct usb_role_switch *sw, enum usb_role role) in usb_role_switch_set_role() argument
48 mutex_lock(&sw->lock); in usb_role_switch_set_role()
[all …]
DKconfig2 tristate "USB Role Switch Support"
4 USB Role Switch is a device that can select the USB role - host or
5 device - for a USB port (connector). In most cases dual-role capable
6 USB controller will also represent the switch, but on some platforms
7 multiplexer/demultiplexer switch is used to route the data lines on
8 the USB connector between separate USB host and device controllers.
10 Say Y here if your USB connectors support both device and host roles.
17 tristate "Intel XHCI USB Role Switch"
20 Driver for the internal USB role switch for switching the USB data
25 be called intel-xhci-usb-role-switch.
Dintel-xhci-usb-role-switch.c1 // SPDX-License-Identifier: GPL-2.0+
3 * Intel XHCI (Cherry Trail, Broxton and others) USB OTG role switch driver
5 * Copyright (c) 2016-2017 Hans de Goede <hdegoede@redhat.com>
22 #include <linux/usb/role.h>
42 static int intel_xhci_usb_set_role(struct device *dev, enum usb_role role) in intel_xhci_usb_set_role() argument
57 return -EIO; in intel_xhci_usb_set_role()
63 val = readl(data->base + DUAL_ROLE_CFG0); in intel_xhci_usb_set_role()
64 switch (role) { in intel_xhci_usb_set_role()
80 writel(val, data->base + DUAL_ROLE_CFG0); in intel_xhci_usb_set_role()
87 /* Polling on CFG1 register to confirm mode switch.*/ in intel_xhci_usb_set_role()
[all …]
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/usb/
Dmediatek,mtu3.txt4 - compatible : should be "mediatek,<soc-model>-mtu3", "mediatek,mtu3",
5 soc-model is the name of SoC, such as mt8173, mt2712 etc,
8 - "mediatek,mt8173-mtu3"
9 - reg : specifies physical base address and size of the registers
10 - reg-names: should be "mac" for device IP and "ippc" for IP port control
11 - interrupts : interrupt used by the device IP
12 - power-domains : a phandle to USB power domain node to control USB's
14 - vusb33-supply : regulator of USB avdd3.3v
15 - clocks : a list of phandle + clock-specifier pairs, one for each
16 entry in clock-names
[all …]
Dmediatek,musb.txt2 -------------------------------------------
5 - compatible : should be one of:
6 "mediatek,mt2701-musb"
8 followed by "mediatek,mtk-musb"
9 - reg : specifies physical base address and size of
11 - interrupts : interrupt used by musb controller
12 - interrupt-names : must be "mc"
13 - phys : PHY specifier for the OTG phy
14 - dr_mode : should be one of "host", "peripheral" or "otg",
15 refer to usb/generic.txt
[all …]
Dgeneric.txt1 Generic USB Properties
4 - maximum-speed: tells USB controllers we want to work up to a certain
5 speed. Valid arguments are "super-speed-plus",
6 "super-speed", "high-speed", "full-speed" and
7 "low-speed". In case this isn't passed via DT, USB
10 - dr_mode: tells Dual-Role USB controllers that we want to work on a
13 passed via DT, USB DRD controllers should default to
15 - phy_type: tells USB controllers that we want to configure the core to support
16 a UTMI+ PHY with an 8- or 16-bit interface if UTMI+ is
18 In case this isn't passed via DT, USB controllers should
[all …]
Drenesas,usb3-peri.yaml1 # SPDX-License-Identifier: GPL-2.0-only
3 ---
4 $id: http://devicetree.org/schemas/usb/renesas,usb3-peri.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: Renesas USB 3.0 Peripheral controller
10 - Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
15 - enum:
16 - renesas,r8a774a1-usb3-peri # RZ/G2M
17 - renesas,r8a774b1-usb3-peri # RZ/G2N
18 - renesas,r8a774c0-usb3-peri # RZ/G2E
[all …]
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 DT bindings
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 …]
/kernel/linux/linux-4.19/Documentation/ABI/testing/
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
/kernel/linux/linux-5.10/Documentation/ABI/testing/
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
/kernel/linux/linux-5.10/include/linux/usb/
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 …]
/kernel/linux/linux-4.19/include/linux/usb/
Drole.h1 // SPDX-License-Identifier: GPL-2.0
16 typedef int (*usb_role_switch_set_t)(struct device *dev, enum usb_role role);
20 * struct usb_role_switch_desc - USB Role Switch Descriptor
24 * @set: Callback for setting the role
25 * @get: Callback for getting the role (optional)
26 * @allow_userspace_control: If true userspace may change the role through sysfs
28 * @usb2_port and @usb3_port will point to the USB host port and @udc to the USB
29 * device controller behind the USB connector with the role switch. If
32 * usb_role_switch_register() before registering the switch.
43 int usb_role_switch_set_role(struct usb_role_switch *sw, enum usb_role role);
Dtypec.h1 /* SPDX-License-Identifier: GPL-2.0 */
8 /* USB Type-C Specification releases */
73 * struct usb_pd_identity - USB Power Delivery identity data
78 * USB power delivery Discover Identity command response data.
80 * REVISIT: This is USB Power Delivery specific information, so this structure
81 * probable belongs to USB Power Delivery header file once we have them.
93 * struct typec_altmode_desc - USB Type-C Alternate Mode Descriptor
96 * @vdo: VDO returned by Discover Modes USB PD command
131 * struct typec_plug_desc - USB Type-C Cable Plug Descriptor
135 * Represents USB Type-C Cable Plug.
[all …]
/kernel/linux/linux-4.19/drivers/extcon/
Dextcon-axp288.c2 * extcon-axp288.c - X-Power AXP288 PMIC extcon cable detection driver
4 * Copyright (c) 2017-2018 Hans de Goede <hdegoede@redhat.com>
27 #include <linux/extcon-provider.h>
30 #include <linux/usb/role.h>
34 #include <asm/intel-family.h>
60 /* BC USB status register */
145 ret = regmap_read(info->regmap, AXP288_PS_BOOT_REASON_REG, &val); in axp288_extcon_log_rsi()
148 dev_dbg(info->dev, "%s\n", *rsi); in axp288_extcon_log_rsi()
154 regmap_write(info->regmap, AXP288_PS_BOOT_REASON_REG, clear_mask); in axp288_extcon_log_rsi()
158 * The below code to control the USB role-switch on devices with an AXP288
[all …]
DKconfig10 host USB ports. Many of 30-pin connectors including PDMI are
32 tristate "X-Power AXP288 EXTCON support"
36 Say Y here to enable support for USB peripheral detection
37 and USB MUX switching by X-Power AXP288 PMIC.
50 Say Y here to enable extcon support for USB OTG ports controlled by
70 Maxim MAX14577/77836. The MAX14577/77836 MUIC is a USB port accessory
71 detector and switch.
74 tristate "Maxim MAX3355 USB OTG EXTCON Support"
77 If you say yes here you get support for the USB OTG role detection by
79 enable a system with an integrated USB OTG dual-role transceiver to
[all …]
/kernel/linux/linux-5.10/Documentation/usb/
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 with 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 …]
/kernel/linux/linux-4.19/Documentation/usb/
Dchipidea.txt2 -----------------------------------
7 ---------------------------------------
15 otg-rev = <0x0200>;
16 adp-disable;
19 -------------------
23 2) Connect 2 boards with usb cable with one end is micro A plug, the other end
26 The A-device(with micro A plug inserted) should enumerate B-device.
28 3) Role switch
29 On B-device:
32 B-device should take host role and enumerate A-device.
[all …]
/kernel/linux/linux-5.10/drivers/extcon/
DKconfig1 # SPDX-License-Identifier: GPL-2.0-only
11 host USB ports. Many of 30-pin connectors including PDMI are
33 tristate "X-Power AXP288 EXTCON support"
37 Say Y here to enable support for USB peripheral detection
38 and USB MUX switching by X-Power AXP288 PMIC.
47 FSA9480 microUSB switch and accessory detector chip. The FSA9480 is a USB
48 port accessory detector and switch. The FSA9480 is fully controlled using
49 I2C and enables USB data, stereo and mono audio, video, microphone
63 Say Y here to enable extcon support for USB OTG ports controlled by
90 Maxim MAX14577/77836. The MAX14577/77836 MUIC is a USB port accessory
[all …]
/kernel/linux/linux-5.10/drivers/usb/common/
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
22 #include <linux/usb/role.h>
53 * Role | ID | VBUS
54 * ------------------------------------
61 * - VBUS only - we want to distinguish between [1] and [2], so ID is always 1
62 * - ID only - we want to distinguish between [1] and [4], so VBUS = ID
67 enum usb_role role; in usb_conn_detect_cable() local
74 id = info->id_gpiod ? in usb_conn_detect_cable()
[all …]
/kernel/linux/linux-5.10/Documentation/driver-api/usb/
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 …]
/kernel/linux/linux-4.19/Documentation/driver-api/usb/
Dtypec.rst2 USB Type-C connector class
6 ------------
8 The typec class is meant for describing the USB Type-C ports in a system to the
13 The platforms are expected to register every USB Type-C port they have with the
14 class. In a normal case the registration will be done by a USB Type-C or PD PHY
16 USB PD controller or even driver for Thunderbolt3 controller. This document
17 considers the component registering the USB Type-C ports with the class as "port
25 attributes are described in Documentation/ABI/testing/sysfs-class-typec.
28 --------------------
35 "port0-partner". Full path to the device would be
[all …]
/kernel/linux/linux-4.19/Documentation/devicetree/bindings/usb/
Dmediatek,mtu3.txt4 - compatible : should be "mediatek,<soc-model>-mtu3", "mediatek,mtu3",
5 soc-model is the name of SoC, such as mt8173, mt2712 etc,
8 - "mediatek,mt8173-mtu3"
9 - reg : specifies physical base address and size of the registers
10 - reg-names: should be "mac" for device IP and "ippc" for IP port control
11 - interrupts : interrupt used by the device IP
12 - power-domains : a phandle to USB power domain node to control USB's
14 - vusb33-supply : regulator of USB avdd3.3v
15 - clocks : a list of phandle + clock-specifier pairs, one for each
16 entry in clock-names
[all …]

123456789