Skip to content

Commit aac9662

Browse files
committed
Merge tag 'usb-5.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb
Pull USB/Thunderbolt/PHY driver updates from Greg KH: "Here is the big USB and Thunderbolt and PHY driver updates for 5.6-rc1. With the advent of USB4, "Thunderbolt" has really become USB4, so the renaming of the Kconfig option and starting to share subsystem code has begun, hence both subsystems coming in through the same tree here. PHY driver updates also touched USB drivers, so that is coming in through here as well. Major stuff included in here are: - USB 4 initial support added (i.e. Thunderbolt) - musb driver updates - USB gadget driver updates - PHY driver updates - USB PHY driver updates - lots of USB serial stuff fixed up - USB typec updates - USB-IP fixes - lots of other smaller USB driver updates All of these have been in linux-next for a while now (the usb-serial tree is already tested in linux-next on its own before merged into here), with no reported issues" [ Removed an incorrect compile test enablement for PHY_EXYNOS5250_SATA that causes configuration warnings - Linus ] * tag 'usb-5.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (207 commits) Doc: ABI: add usb charger uevent usb: phy: show USB charger type for user usb: cdns3: fix spelling mistake and rework grammar in text usb: phy: phy-gpio-vbus-usb: Convert to GPIO descriptors USB: serial: cyberjack: fix spelling mistake "To" -> "Too" USB: serial: ir-usb: simplify endpoint check USB: serial: ir-usb: make set_termios synchronous USB: serial: ir-usb: fix IrLAP framing USB: serial: ir-usb: fix link-speed handling USB: serial: ir-usb: add missing endpoint sanity check usb: typec: fusb302: fix "op-sink-microwatt" default that was in mW usb: typec: wcove: fix "op-sink-microwatt" default that was in mW usb: dwc3: pci: add ID for the Intel Comet Lake -V variant usb: typec: tcpci: mask event interrupts when remove driver usb: host: xhci-tegra: set MODULE_FIRMWARE for tegra186 usb: chipidea: add inline for ci_hdrc_host_driver_init if host is not defined usb: chipidea: handle single role for usb role class usb: musb: fix spelling mistake: "periperal" -> "peripheral" phy: ti: j721e-wiz: Fix build error without CONFIG_OF_ADDRESS USB: usbfs: Always unlink URBs in reverse order ...
2 parents 6ba3d70 + eaa5199 commit aac9662

File tree

199 files changed

+9923
-2466
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

199 files changed

+9923
-2466
lines changed

Documentation/ABI/testing/configfs-usb-gadget

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ Description:
1616
write UDC's name found in /sys/class/udc/*
1717
to bind a gadget, empty string "" to unbind.
1818

19+
max_speed - maximum speed the driver supports. Valid
20+
names are super-speed-plus, super-speed,
21+
high-speed, full-speed, and low-speed.
22+
1923
bDeviceClass - USB device class code
2024
bDeviceSubClass - USB device subclass code
2125
bDeviceProtocol - USB device protocol code
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
What: Raise a uevent when a USB charger is inserted or removed
2+
Date: 2020-01-14
3+
KernelVersion: 5.6
4+
5+
Description: There are two USB charger states:
6+
USB_CHARGER_ABSENT
7+
USB_CHARGER_PRESENT
8+
There are five USB charger types:
9+
USB_CHARGER_UNKNOWN_TYPE: Charger type is unknown
10+
USB_CHARGER_SDP_TYPE: Standard Downstream Port
11+
USB_CHARGER_CDP_TYPE: Charging Downstream Port
12+
USB_CHARGER_DCP_TYPE: Dedicated Charging Port
13+
USB_CHARGER_ACA_TYPE: Accessory Charging Adapter
14+
https://www.usb.org/document-library/battery-charging-v12-spec-and-adopters-agreement
15+
16+
Here are two examples taken using udevadm monitor -p when
17+
USB charger is online:
18+
UDEV change /devices/soc0/usbphynop1 (platform)
19+
ACTION=change
20+
DEVPATH=/devices/soc0/usbphynop1
21+
DRIVER=usb_phy_generic
22+
MODALIAS=of:Nusbphynop1T(null)Cusb-nop-xceiv
23+
OF_COMPATIBLE_0=usb-nop-xceiv
24+
OF_COMPATIBLE_N=1
25+
OF_FULLNAME=/usbphynop1
26+
OF_NAME=usbphynop1
27+
SEQNUM=2493
28+
SUBSYSTEM=platform
29+
USB_CHARGER_STATE=USB_CHARGER_PRESENT
30+
USB_CHARGER_TYPE=USB_CHARGER_SDP_TYPE
31+
USEC_INITIALIZED=227422826
32+
33+
USB charger is offline:
34+
KERNEL change /devices/soc0/usbphynop1 (platform)
35+
ACTION=change
36+
DEVPATH=/devices/soc0/usbphynop1
37+
DRIVER=usb_phy_generic
38+
MODALIAS=of:Nusbphynop1T(null)Cusb-nop-xceiv
39+
OF_COMPATIBLE_0=usb-nop-xceiv
40+
OF_COMPATIBLE_N=1
41+
OF_FULLNAME=/usbphynop1
42+
OF_NAME=usbphynop1
43+
SEQNUM=2494
44+
SUBSYSTEM=platform
45+
USB_CHARGER_STATE=USB_CHARGER_ABSENT
46+
USB_CHARGER_TYPE=USB_CHARGER_UNKNOWN_TYPE

Documentation/admin-guide/thunderbolt.rst

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,28 @@
1-
=============
2-
Thunderbolt
3-
=============
1+
.. SPDX-License-Identifier: GPL-2.0
2+
3+
======================
4+
USB4 and Thunderbolt
5+
======================
6+
USB4 is the public specification based on Thunderbolt 3 protocol with
7+
some differences at the register level among other things. Connection
8+
manager is an entity running on the host router (host controller)
9+
responsible for enumerating routers and establishing tunnels. A
10+
connection manager can be implemented either in firmware or software.
11+
Typically PCs come with a firmware connection manager for Thunderbolt 3
12+
and early USB4 capable systems. Apple systems on the other hand use
13+
software connection manager and the later USB4 compliant devices follow
14+
the suit.
15+
16+
The Linux Thunderbolt driver supports both and can detect at runtime which
17+
connection manager implementation is to be used. To be on the safe side the
18+
software connection manager in Linux also advertises security level
19+
``user`` which means PCIe tunneling is disabled by default. The
20+
documentation below applies to both implementations with the exception that
21+
the software connection manager only supports ``user`` security level and
22+
is expected to be accompanied with an IOMMU based DMA protection.
23+
24+
Security levels and how to use them
25+
-----------------------------------
426
The interface presented here is not meant for end users. Instead there
527
should be a userspace tool that handles all the low-level details, keeps
628
a database of the authorized devices and prompts users for new connections.
@@ -18,8 +40,6 @@ This will authorize all devices automatically when they appear. However,
1840
keep in mind that this bypasses the security levels and makes the system
1941
vulnerable to DMA attacks.
2042

21-
Security levels and how to use them
22-
-----------------------------------
2343
Starting with Intel Falcon Ridge Thunderbolt controller there are 4
2444
security levels available. Intel Titan Ridge added one more security level
2545
(usbonly). The reason for these is the fact that the connected devices can

Documentation/devicetree/bindings/connector/usb-connector.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
USB Connector
22
=============
33

4-
USB connector node represents physical USB connector. It should be
5-
a child of USB interface controller.
4+
A USB connector node represents a physical USB connector. It should be
5+
a child of a USB interface controller.
66

77
Required properties:
88
- compatible: describes type of the connector, must be one of:
Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,135 @@
1+
# SPDX-License-Identifier: GPL-2.0
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/phy/allwinner,sun9i-a80-usb-phy.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Allwinner A80 USB PHY Device Tree Bindings
8+
9+
maintainers:
10+
- Chen-Yu Tsai <[email protected]>
11+
- Maxime Ripard <[email protected]>
12+
13+
properties:
14+
"#phy-cells":
15+
const: 0
16+
17+
compatible:
18+
const: allwinner,sun9i-a80-usb-phy
19+
20+
reg:
21+
maxItems: 1
22+
23+
clocks:
24+
anyOf:
25+
- description: Main PHY Clock
26+
27+
- items:
28+
- description: Main PHY clock
29+
- description: HSIC 12MHz clock
30+
- description: HSIC 480MHz clock
31+
32+
clock-names:
33+
oneOf:
34+
- const: phy
35+
36+
- items:
37+
- const: phy
38+
- const: hsic_12M
39+
- const: hsic_480M
40+
41+
resets:
42+
anyOf:
43+
- description: Normal USB PHY reset
44+
45+
- items:
46+
- description: Normal USB PHY reset
47+
- description: HSIC Reset
48+
49+
reset-names:
50+
oneOf:
51+
- const: phy
52+
53+
- items:
54+
- const: phy
55+
- const: hsic
56+
57+
phy_type:
58+
const: hsic
59+
description:
60+
When absent, the PHY type will be assumed to be normal USB.
61+
62+
phy-supply:
63+
description:
64+
Regulator that powers VBUS
65+
66+
required:
67+
- "#phy-cells"
68+
- compatible
69+
- reg
70+
- clocks
71+
- clock-names
72+
- resets
73+
- reset-names
74+
75+
additionalProperties: false
76+
77+
if:
78+
properties:
79+
phy_type:
80+
const: hsic
81+
82+
required:
83+
- phy_type
84+
85+
then:
86+
properties:
87+
clocks:
88+
maxItems: 3
89+
90+
clock-names:
91+
maxItems: 3
92+
93+
resets:
94+
maxItems: 2
95+
96+
reset-names:
97+
maxItems: 2
98+
99+
examples:
100+
- |
101+
#include <dt-bindings/clock/sun9i-a80-usb.h>
102+
#include <dt-bindings/reset/sun9i-a80-usb.h>
103+
104+
usbphy1: phy@a00800 {
105+
compatible = "allwinner,sun9i-a80-usb-phy";
106+
reg = <0x00a00800 0x4>;
107+
clocks = <&usb_clocks CLK_USB0_PHY>;
108+
clock-names = "phy";
109+
resets = <&usb_clocks RST_USB0_PHY>;
110+
reset-names = "phy";
111+
phy-supply = <&reg_usb1_vbus>;
112+
#phy-cells = <0>;
113+
};
114+
115+
- |
116+
#include <dt-bindings/clock/sun9i-a80-usb.h>
117+
#include <dt-bindings/reset/sun9i-a80-usb.h>
118+
119+
usbphy3: phy@a02800 {
120+
compatible = "allwinner,sun9i-a80-usb-phy";
121+
reg = <0x00a02800 0x4>;
122+
clocks = <&usb_clocks CLK_USB2_PHY>,
123+
<&usb_clocks CLK_USB_HSIC>,
124+
<&usb_clocks CLK_USB2_HSIC>;
125+
clock-names = "phy",
126+
"hsic_12M",
127+
"hsic_480M";
128+
resets = <&usb_clocks RST_USB2_PHY>,
129+
<&usb_clocks RST_USB2_HSIC>;
130+
reset-names = "phy",
131+
"hsic";
132+
phy_type = "hsic";
133+
phy-supply = <&reg_usb3_vbus>;
134+
#phy-cells = <0>;
135+
};
Lines changed: 56 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,49 @@
11
Broadcom STB USB PHY
22

33
Required properties:
4-
- compatible: brcm,brcmstb-usb-phy
5-
- reg: two offset and length pairs.
6-
The first pair specifies a manditory set of memory mapped
7-
registers used for general control of the PHY.
8-
The second pair specifies optional registers used by some of
9-
the SoCs that support USB 3.x
10-
- #phy-cells: Shall be 1 as it expects one argument for setting
11-
the type of the PHY. Possible values are:
12-
- PHY_TYPE_USB2 for USB1.1/2.0 PHY
13-
- PHY_TYPE_USB3 for USB3.x PHY
4+
- compatible: should be one of
5+
"brcm,brcmstb-usb-phy"
6+
"brcm,bcm7216-usb-phy"
7+
"brcm,bcm7211-usb-phy"
8+
9+
- reg and reg-names properties requirements are specific to the
10+
compatible string.
11+
"brcm,brcmstb-usb-phy":
12+
- reg: 1 or 2 offset and length pairs. One for the base CTRL registers
13+
and an optional pair for systems with USB 3.x support
14+
- reg-names: not specified
15+
"brcm,bcm7216-usb-phy":
16+
- reg: 3 offset and length pairs for CTRL, XHCI_EC and XHCI_GBL
17+
registers
18+
- reg-names: "ctrl", "xhci_ec", "xhci_gbl"
19+
"brcm,bcm7211-usb-phy":
20+
- reg: 5 offset and length pairs for CTRL, XHCI_EC, XHCI_GBL,
21+
USB_PHY and USB_MDIO registers and an optional pair
22+
for the BDC registers
23+
- reg-names: "ctrl", "xhci_ec", "xhci_gbl", "usb_phy", "usb_mdio", "bdc_ec"
24+
25+
- #phy-cells: Shall be 1 as it expects one argument for setting
26+
the type of the PHY. Possible values are:
27+
- PHY_TYPE_USB2 for USB1.1/2.0 PHY
28+
- PHY_TYPE_USB3 for USB3.x PHY
1429

1530
Optional Properties:
1631
- clocks : clock phandles.
1732
- clock-names: String, clock name.
33+
- interrupts: wakeup interrupt
34+
- interrupt-names: "wakeup"
1835
- brcm,ipp: Boolean, Invert Port Power.
1936
Possible values are: 0 (Don't invert), 1 (Invert)
2037
- brcm,ioc: Boolean, Invert Over Current detection.
2138
Possible values are: 0 (Don't invert), 1 (Invert)
22-
NOTE: one or both of the following two properties must be set
23-
- brcm,has-xhci: Boolean indicating the phy has an XHCI phy.
24-
- brcm,has-eohci: Boolean indicating the phy has an EHCI/OHCI phy.
2539
- dr_mode: String, PHY Device mode.
2640
Possible values are: "host", "peripheral ", "drd" or "typec-pd"
2741
If this property is not defined, the phy will default to "host" mode.
42+
- brcm,syscon-piarbctl: phandle to syscon for handling config registers
43+
NOTE: one or both of the following two properties must be set
44+
- brcm,has-xhci: Boolean indicating the phy has an XHCI phy.
45+
- brcm,has-eohci: Boolean indicating the phy has an EHCI/OHCI phy.
46+
2847

2948
Example:
3049

@@ -41,3 +60,27 @@ usbphy_0: usb-phy@f0470200 {
4160
clocks = <&usb20>, <&usb30>;
4261
clock-names = "sw_usb", "sw_usb3";
4362
};
63+
64+
usb-phy@29f0200 {
65+
reg = <0x29f0200 0x200>,
66+
<0x29c0880 0x30>,
67+
<0x29cc100 0x534>,
68+
<0x2808000 0x24>,
69+
<0x2980080 0x8>;
70+
reg-names = "ctrl",
71+
"xhci_ec",
72+
"xhci_gbl",
73+
"usb_phy",
74+
"usb_mdio";
75+
brcm,ioc = <0x0>;
76+
brcm,ipp = <0x0>;
77+
compatible = "brcm,bcm7211-usb-phy";
78+
interrupts = <0x30>;
79+
interrupt-parent = <&vpu_intr1_nosec_intc>;
80+
interrupt-names = "wake";
81+
#phy-cells = <0x1>;
82+
brcm,has-xhci;
83+
syscon-piarbctl = <&syscon_piarbctl>;
84+
clocks = <&scmi_clk 256>;
85+
clock-names = "sw_usb";
86+
};

Documentation/devicetree/bindings/phy/brcm-sata-phy.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
Required properties:
44
- compatible: should be one or more of
5+
"brcm,bcm7216-sata-phy"
56
"brcm,bcm7425-sata-phy"
67
"brcm,bcm7445-sata-phy"
78
"brcm,iproc-ns2-sata-phy"

0 commit comments

Comments
 (0)