History

Merge tag 'usb-5.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb

Pull USB/PHY updates from Greg KH: "Here is the big USB/PHY driver pull request for 5.1-rc1. The usual set of gadget driver updates, phy driver updates, xhci updates, and typec additions. Also included in here are a lot of small cleanups and fixes and driver updates where needed. All of these have been in linux-next for a while with no reported issues" * tag 'usb-5.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (167 commits) wusb: Remove unnecessary static function ckhdid_printf usb: core: make default autosuspend delay configurable usb: core: Fix typo in description of "authorized_default" usb: chipidea: Refactor USB PHY selection and keep a single PHY usb: chipidea: Grab the (legacy) USB PHY by phandle first usb: chipidea: imx: set power polarity dt-bindings: usb: ci-hdrc-usb2: add property power-active-high usb: chipidea: imx: remove unused header files usb: chipidea: tegra: Fix missed ci_hdrc_remove_device() usb: core: add option of only authorizing internal devices usb: typec: tps6598x: handle block writes separately with plain-I2C adapters usb: xhci: Fix for Enabling USB ROLE SWITCH QUIRK on INTEL_SUNRISEPOINT_LP_XHCI usb: xhci: fix build warning - missing prototype usb: xhci: dbc: Fixing typo error. usb: xhci: remove unused member 'parent' in xhci_regset struct xhci: tegra: Prevent error pointer dereference USB: serial: option: add Telit ME910 ECM composition usb: core: Replace hardcoded check with inline function from usb.h usb: core: skip interfaces disabled in devicetree usb: typec: mux: remove redundant check on variable match ...

Linus Torvalds committed 7 years ago

Commit f90d6442 parents 67e79a6 1c7cf3d203 files · +2951 −1110Browse files

Showing the changes to include/linux (9 of 203 files). Show all

Unified · Split

9 files
  1. include/linux/device.h +6 −0
  2. include/linux/fsl_devices.h +4 −3
  3. include/linux/phy/phy-mipi-dphy.h +6 −7
  4. include/linux/usb/hcd.h +7 −3
  5. include/linux/usb/role.h +2 −0
  6. include/linux/usb/tcpm.h +0 −6
  7. include/linux/usb/typec_dp.h +4 −0
  8. include/linux/usb/typec_mux.h +2 −1
  9. include/linux/usb/wusb.h +0 −16
include/linux/device.h+6−0
@@ -758,11 +758,17 @@ struct device_dma_parameters { · 757 unmodified lines
758 758
759/**759/**
760 * struct device_connection - Device Connection Descriptor760 * struct device_connection - Device Connection Descriptor
761 * @fwnode: The device node of the connected device
761 * @endpoint: The names of the two devices connected together762 * @endpoint: The names of the two devices connected together
762 * @id: Unique identifier for the connection763 * @id: Unique identifier for the connection
763 * @list: List head, private, for internal use only764 * @list: List head, private, for internal use only
765 *
766 * NOTE: @fwnode is not used together with @endpoint. @fwnode is used when
767 * platform firmware defines the connection. When the connection is registered
768 * with device_connection_add() @endpoint is used instead.
764 */769 */
765struct device_connection {770struct device_connection {
771 struct fwnode_handle *fwnode;
766 const char *endpoint[2];772 const char *endpoint[2];
767 const char *id;773 const char *id;
768 struct list_head list;774 struct list_head list;
include/linux/fsl_devices.h+4−3
@@ -98,10 +98,11 @@ struct fsl_usb2_platform_data { · 97 unmodified lines
98 98
99 unsigned suspended:1;99 unsigned suspended:1;
100 unsigned already_suspended:1;100 unsigned already_suspended:1;
101 unsigned has_fsl_erratum_a007792:1;101 unsigned has_fsl_erratum_a007792:1;
102 unsigned has_fsl_erratum_a005275:1;102 unsigned has_fsl_erratum_14:1;
103 unsigned has_fsl_erratum_a005275:1;
103 unsigned has_fsl_erratum_a005697:1;104 unsigned has_fsl_erratum_a005697:1;
104 unsigned check_phy_clk_valid:1;105 unsigned check_phy_clk_valid:1;
105 106
106 /* register save area for suspend/resume */107 /* register save area for suspend/resume */
107 u32 pm_command;108 u32 pm_command;
include/linux/phy/phy-mipi-dphy.h+6−7
@@ -6,8 +6,6 @@ · 5 unmodified lines
6#ifndef __PHY_MIPI_DPHY_H_6#ifndef __PHY_MIPI_DPHY_H_
7#define __PHY_MIPI_DPHY_H_7#define __PHY_MIPI_DPHY_H_
8 8
9#include <video/videomode.h>
10
11/**9/**
12 * struct phy_configure_opts_mipi_dphy - MIPI D-PHY configuration set10 * struct phy_configure_opts_mipi_dphy - MIPI D-PHY configuration set
13 *11 *
@@ -192,10 +190,10 @@ struct phy_configure_opts_mipi_dphy { · 178 unmodified lines
192 /**190 /**
193 * @init:191 * @init:
194 *192 *
195 * Time, in picoseconds for the initialization period to193 * Time, in microseconds for the initialization period to
196 * complete.194 * complete.
197 *195 *
198 * Minimum value: 100000000 ps196 * Minimum value: 100 us
199 */197 */
200 unsigned int init;198 unsigned int init;
201 199
@@ -246,11 +244,11 @@ struct phy_configure_opts_mipi_dphy { · 44 unmodified lines
246 /**244 /**
247 * @wakeup:245 * @wakeup:
248 *246 *
249 * Time, in picoseconds, that a transmitter drives a Mark-1247 * Time, in microseconds, that a transmitter drives a Mark-1
250 * state prior to a Stop state in order to initiate an exit248 * state prior to a Stop state in order to initiate an exit
251 * from ULPS.249 * from ULPS.
252 *250 *
253 * Minimum value: 1000000000 ps251 * Minimum value: 1000 us
254 */252 */
255 unsigned int wakeup;253 unsigned int wakeup;
256 254
@@ -271,7 +269,8 @@ struct phy_configure_opts_mipi_dphy { · 14 unmodified lines
271 /**269 /**
272 * @lanes:270 * @lanes:
273 *271 *
274 * Number of active data lanes used for the transmissions.272 * Number of active, consecutive, data lanes, starting from
273 * lane 0, used for the transmissions.
275 */274 */
276 unsigned char lanes;275 unsigned char lanes;
277};276};
include/linux/usb/hcd.h+7−3
@@ -72,6 +72,12 @@ struct giveback_urb_bh { · 71 unmodified lines
72 struct usb_host_endpoint *completing_ep;72 struct usb_host_endpoint *completing_ep;
73};73};
74 74
75enum usb_dev_authorize_policy {
76 USB_DEVICE_AUTHORIZE_NONE = 0,
77 USB_DEVICE_AUTHORIZE_ALL = 1,
78 USB_DEVICE_AUTHORIZE_INTERNAL = 2,
79};
80
75struct usb_hcd {81struct usb_hcd {
76 82
77 /*83 /*
@@ -117,7 +123,6 @@ struct usb_hcd { · 39 unmodified lines
117#define HCD_FLAG_RH_RUNNING 5 /* root hub is running? */123#define HCD_FLAG_RH_RUNNING 5 /* root hub is running? */
118#define HCD_FLAG_DEAD 6 /* controller has died? */124#define HCD_FLAG_DEAD 6 /* controller has died? */
119#define HCD_FLAG_INTF_AUTHORIZED 7 /* authorize interfaces? */125#define HCD_FLAG_INTF_AUTHORIZED 7 /* authorize interfaces? */
120#define HCD_FLAG_DEV_AUTHORIZED 8 /* authorize devices? */
121 126
122 /* The flags can be tested using these macros; they are likely to127 /* The flags can be tested using these macros; they are likely to
123 * be slightly faster than test_bit().128 * be slightly faster than test_bit().
@@ -142,8 +147,7 @@ struct usb_hcd { · 18 unmodified lines
142 * or they require explicit user space authorization; this bit is147 * or they require explicit user space authorization; this bit is
143 * settable through /sys/class/usb_host/X/authorized_default148 * settable through /sys/class/usb_host/X/authorized_default
144 */149 */
145#define HCD_DEV_AUTHORIZED(hcd) \150 enum usb_dev_authorize_policy dev_policy;
146 ((hcd)->flags & (1U << HCD_FLAG_DEV_AUTHORIZED))
147 151
148 /* Flags that get set only during HCD registration or removal. */152 /* Flags that get set only during HCD registration or removal. */
149 unsigned rh_registered:1;/* is root hub registered? */153 unsigned rh_registered:1;/* is root hub registered? */
include/linux/usb/role.h+2−0
@@ -18,6 +18,7 @@ typedef enum usb_role (*usb_role_switch_get_t)(struct device *dev); · 17 unmodified lines
18 18
19/**19/**
20 * struct usb_role_switch_desc - USB Role Switch Descriptor20 * struct usb_role_switch_desc - USB Role Switch Descriptor
21 * @fwnode: The device node to be associated with the role switch
21 * @usb2_port: Optional reference to the host controller port device (USB2)22 * @usb2_port: Optional reference to the host controller port device (USB2)
22 * @usb3_port: Optional reference to the host controller port device (USB3)23 * @usb3_port: Optional reference to the host controller port device (USB3)
23 * @udc: Optional reference to the peripheral controller device24 * @udc: Optional reference to the peripheral controller device
@@ -32,6 +33,7 @@ typedef enum usb_role (*usb_role_switch_get_t)(struct device *dev); · 8 unmodified lines
32 * usb_role_switch_register() before registering the switch.33 * usb_role_switch_register() before registering the switch.
33 */34 */
34struct usb_role_switch_desc {35struct usb_role_switch_desc {
36 struct fwnode_handle *fwnode;
35 struct device *usb2_port;37 struct device *usb2_port;
36 struct device *usb3_port;38 struct device *usb3_port;
37 struct device *udc;39 struct device *udc;
include/linux/usb/tcpm.h+0−6
@@ -159,12 +159,6 @@ struct tcpm_port; · 158 unmodified lines
159struct tcpm_port *tcpm_register_port(struct device *dev, struct tcpc_dev *tcpc);159struct tcpm_port *tcpm_register_port(struct device *dev, struct tcpc_dev *tcpc);
160void tcpm_unregister_port(struct tcpm_port *port);160void tcpm_unregister_port(struct tcpm_port *port);
161 161
162int tcpm_update_source_capabilities(struct tcpm_port *port, const u32 *pdo,
163 unsigned int nr_pdo);
164int tcpm_update_sink_capabilities(struct tcpm_port *port, const u32 *pdo,
165 unsigned int nr_pdo,
166 unsigned int operating_snk_mw);
167
168void tcpm_vbus_change(struct tcpm_port *port);162void tcpm_vbus_change(struct tcpm_port *port);
169void tcpm_cc_change(struct tcpm_port *port);163void tcpm_cc_change(struct tcpm_port *port);
170void tcpm_pd_receive(struct tcpm_port *port,164void tcpm_pd_receive(struct tcpm_port *port,
include/linux/usb/typec_dp.h+4−0
@@ -92,4 +92,8 @@ enum { · 91 unmodified lines
92#define DP_CONF_PIN_ASSIGNEMENT_SHIFT 892#define DP_CONF_PIN_ASSIGNEMENT_SHIFT 8
93#define DP_CONF_PIN_ASSIGNEMENT_MASK GENMASK(15, 8)93#define DP_CONF_PIN_ASSIGNEMENT_MASK GENMASK(15, 8)
94 94
95/* Helper for setting/getting the pin assignement value to the configuration */
96#define DP_CONF_SET_PIN_ASSIGN(_a_) ((_a_) << 8)
97#define DP_CONF_GET_PIN_ASSIGN(_conf_) (((_conf_) & GENMASK(15, 8)) >> 8)
98
95#endif /* __USB_TYPEC_DP_H */99#endif /* __USB_TYPEC_DP_H */
include/linux/usb/typec_mux.h+2−1
@@ -47,7 +47,8 @@ void typec_switch_put(struct typec_switch *sw); · 46 unmodified lines
47int typec_switch_register(struct typec_switch *sw);47int typec_switch_register(struct typec_switch *sw);
48void typec_switch_unregister(struct typec_switch *sw);48void typec_switch_unregister(struct typec_switch *sw);
49 49
50struct typec_mux *typec_mux_get(struct device *dev, const char *name);50struct typec_mux *
51typec_mux_get(struct device *dev, const struct typec_altmode_desc *desc);
51void typec_mux_put(struct typec_mux *mux);52void typec_mux_put(struct typec_mux *mux);
52int typec_mux_register(struct typec_mux *mux);53int typec_mux_register(struct typec_mux *mux);
53void typec_mux_unregister(struct typec_mux *mux);54void typec_mux_unregister(struct typec_mux *mux);
include/linux/usb/wusb.h+0−16
@@ -236,22 +236,6 @@ enum { · 235 unmodified lines
236 WUSB_TRUST_TIMEOUT_MS = 4000, /* [WUSB] section 4.15.1 */236 WUSB_TRUST_TIMEOUT_MS = 4000, /* [WUSB] section 4.15.1 */
237};237};
238 238
239static inline size_t ckhdid_printf(char *pr_ckhdid, size_t size,
240 const struct wusb_ckhdid *ckhdid)
241{
242 return scnprintf(pr_ckhdid, size,
243 "%02hx %02hx %02hx %02hx %02hx %02hx %02hx %02hx "
244 "%02hx %02hx %02hx %02hx %02hx %02hx %02hx %02hx",
245 ckhdid->data[0], ckhdid->data[1],
246 ckhdid->data[2], ckhdid->data[3],
247 ckhdid->data[4], ckhdid->data[5],
248 ckhdid->data[6], ckhdid->data[7],
249 ckhdid->data[8], ckhdid->data[9],
250 ckhdid->data[10], ckhdid->data[11],
251 ckhdid->data[12], ckhdid->data[13],
252 ckhdid->data[14], ckhdid->data[15]);
253}
254
255/*239/*
256 * WUSB Crypto stuff (WUSB1.0[6])240 * WUSB Crypto stuff (WUSB1.0[6])
257 */241 */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t