Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e7a2c3fa authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman
Browse files

Merge tag 'usb-for-v4.20' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb into usb-next

Felipe writes:

USB for v4.20

With 63 non-merge commits, this is not a large merge window for USB
peripheral. The largest changes go to the UVC gadget driver which a
few folks have been improving.

Apart from UVC changes, we have a few more devices being added to
Renesas USB3 and DWC3 controller drivers and a couple minor bug fixes
on other drivers.

* tag 'usb-for-v4.20' of git://git.kernel.org/pub/scm/linux/kernel/git/balbi/usb: (63 commits)
  USB: net2280: Remove ->disconnect() callback from net2280_pullup()
  usb: dwc2: disable power_down on rockchip devices
  usb: gadget: udc: renesas_usb3: add support for r8a77990
  dt-bindings: usb: renesas_usb3: add bindings for r8a77990
  usb: gadget: udc: renesas_usb3: Add r8a774a1 support
  usb: gadget: udc: renesas_usb3: Fix b-device mode for "workaround"
  usb: dwc2: gadget: Add handler for WkupAlert interrupt
  usb: dwc2: gadget: enable WKUP_ALERT interrupt
  usb: dwc2: gadget: Program GREFCLK register
  usb: dwc2: gadget: Add parameters for GREFCLK register
  usb: dwc2: Add definitions for new registers
  usb: dwc2: Update target (u)frame calculation
  usb: dwc2: Add dwc2_gadget_dec_frame_num_by_one() function
  usb: dwc2: Add core parameter for service interval support
  usb: dwc2: Update registers definitions to support service interval
  usb: renesas_usbhs: add support for R-Car E3
  dt-bindings: usb: renesas_usbhs: add bindings for r8a77990
  usb: renesas_usbhs: rcar3: Use OTG mode for R-Car D3
  Revert "usb: renesas_usbhs: set the mode by using extcon state for non-otg channel"
  usb: gadget: f_uac2: disable IN/OUT ep if unused
  ...
parents 3c168909 3b766f45
Loading
Loading
Loading
Loading
+24 −0
Original line number Diff line number Diff line
@@ -12,6 +12,10 @@ Date: Dec 2014
KernelVersion:	4.0
Description:	Control descriptors

		All attributes read only:
		bInterfaceNumber	- USB interface number for this
					  streaming interface

What:		/config/usb-gadget/gadget/functions/uvc.name/control/class
Date:		Dec 2014
KernelVersion:	4.0
@@ -109,6 +113,10 @@ Date: Dec 2014
KernelVersion:	4.0
Description:	Streaming descriptors

		All attributes read only:
		bInterfaceNumber	- USB interface number for this
					  streaming interface

What:		/config/usb-gadget/gadget/functions/uvc.name/streaming/class
Date:		Dec 2014
KernelVersion:	4.0
@@ -160,6 +168,10 @@ Description: Specific MJPEG format descriptors

		All attributes read only,
		except bmaControls and bDefaultFrameIndex:
		bFormatIndex		- unique id for this format descriptor;
					only defined after parent header is
					linked into the streaming class;
					read-only
		bmaControls		- this format's data for bmaControls in
					the streaming header
		bmInterfaceFlags	- specifies interlace information,
@@ -177,6 +189,10 @@ Date: Dec 2014
KernelVersion:	4.0
Description:	Specific MJPEG frame descriptors

		bFrameIndex		- unique id for this framedescriptor;
					only defined after parent format is
					linked into the streaming header;
					read-only
		dwFrameInterval		- indicates how frame interval can be
					programmed; a number of values
					separated by newline can be specified
@@ -204,6 +220,10 @@ Date: Dec 2014
KernelVersion:	4.0
Description:	Specific uncompressed format descriptors

		bFormatIndex		- unique id for this format descriptor;
					only defined after parent header is
					linked into the streaming class;
					read-only
		bmaControls		- this format's data for bmaControls in
					the streaming header
		bmInterfaceFlags	- specifies interlace information,
@@ -224,6 +244,10 @@ Date: Dec 2014
KernelVersion:	4.0
Description:	Specific uncompressed frame descriptors

		bFrameIndex		- unique id for this framedescriptor;
					only defined after parent format is
					linked into the streaming header;
					read-only
		dwFrameInterval		- indicates how frame interval can be
					programmed; a number of values
					separated by newline can be specified
+1 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@ Exception for clocks:
    "cavium,octeon-7130-usb-uctl"
    "qcom,dwc3"
    "samsung,exynos5250-dwusb3"
    "samsung,exynos5433-dwusb3"
    "samsung,exynos7-dwusb3"
    "sprd,sc9860-dwc3"
    "st,stih407-dwc3"
+2 −0
Original line number Diff line number Diff line
@@ -83,6 +83,8 @@ Required properties:
 - compatible: should be one of the following -
	       "samsung,exynos5250-dwusb3": for USB 3.0 DWC3 controller on
					    Exynos5250/5420.
	       "samsung,exynos5433-dwusb3": for USB 3.0 DWC3 controller on
					    Exynos5433.
	       "samsung,exynos7-dwusb3": for USB 3.0 DWC3 controller on Exynos7.
 - #address-cells, #size-cells : should be '1' if the device has sub-nodes
				 with 'reg' property.
+1 −0
Original line number Diff line number Diff line
@@ -6,6 +6,7 @@ Required properties:
	- "renesas,r8a7795-usb3-peri"
	- "renesas,r8a7796-usb3-peri"
	- "renesas,r8a77965-usb3-peri"
	- "renesas,r8a77990-usb3-peri"
	- "renesas,rcar-gen3-usb3-peri" for a generic R-Car Gen3 or RZ/G2
	  compatible device

+29 −0
Original line number Diff line number Diff line
@@ -393,6 +393,20 @@ enum dwc2_ep0_state {
 *			0 - No
 *			1 - Yes
 * @hird_threshold:	Value of BESL or HIRD Threshold.
 * @ref_clk_per:        Indicates in terms of pico seconds the period
 *                      of ref_clk.
 *			62500 - 16MHz
 *                      58823 - 17MHz
 *                      52083 - 19.2MHz
 *			50000 - 20MHz
 *			41666 - 24MHz
 *			33333 - 30MHz (default)
 *			25000 - 40MHz
 * @sof_cnt_wkup_alert: Indicates in term of number of SOF's after which
 *                      the controller should generate an interrupt if the
 *                      device had been in L1 state until that period.
 *                      This is used by SW to initiate Remote WakeUp in the
 *                      controller so as to sync to the uF number from the host.
 * @activate_stm_fs_transceiver: Activate internal transceiver using GGPIO
 *			register.
 *			0 - Deactivate the transceiver (default)
@@ -416,6 +430,9 @@ enum dwc2_ep0_state {
 *                      back to DWC2_SPEED_PARAM_HIGH while device is gone.
 *			0 - No (default)
 *			1 - Yes
 * @service_interval:   Enable service interval based scheduling.
 *                      0 - No
 *                      1 - Yes
 *
 * The following parameters may be specified when starting the module. These
 * parameters define how the DWC_otg controller should be configured. A
@@ -461,6 +478,7 @@ struct dwc2_core_params {
	bool lpm_clock_gating;
	bool besl;
	bool hird_threshold_en;
	bool service_interval;
	u8 hird_threshold;
	bool activate_stm_fs_transceiver;
	bool ipg_isoc_en;
@@ -468,6 +486,10 @@ struct dwc2_core_params {
	u32 max_transfer_size;
	u32 ahbcfg;

	/* GREFCLK parameters */
	u32 ref_clk_per;
	u16 sof_cnt_wkup_alert;

	/* Host parameters */
	bool host_dma;
	bool dma_desc_enable;
@@ -605,6 +627,10 @@ struct dwc2_core_params {
 *			FIFO sizing is enabled 16 to 32768
 *			Actual maximum value is autodetected and also
 *			the default.
 * @service_interval_mode: For enabling service interval based scheduling in the
 *                         controller.
 *                           0 - Disable
 *                           1 - Enable
 */
struct dwc2_hw_params {
	unsigned op_mode:3;
@@ -635,6 +661,7 @@ struct dwc2_hw_params {
	unsigned utmi_phy_data_width:2;
	unsigned lpm_mode:1;
	unsigned ipg_isoc_en:1;
	unsigned service_interval_mode:1;
	u32 snpsid;
	u32 dev_ep_dirs;
	u32 g_tx_fifo_size[MAX_EPS_CHANNELS];
@@ -1354,6 +1381,7 @@ int dwc2_hsotg_tx_fifo_count(struct dwc2_hsotg *hsotg);
int dwc2_hsotg_tx_fifo_total_depth(struct dwc2_hsotg *hsotg);
int dwc2_hsotg_tx_fifo_average_depth(struct dwc2_hsotg *hsotg);
void dwc2_gadget_init_lpm(struct dwc2_hsotg *hsotg);
void dwc2_gadget_program_ref_clk(struct dwc2_hsotg *hsotg);
#else
static inline int dwc2_hsotg_remove(struct dwc2_hsotg *dwc2)
{ return 0; }
@@ -1388,6 +1416,7 @@ static inline int dwc2_hsotg_tx_fifo_total_depth(struct dwc2_hsotg *hsotg)
static inline int dwc2_hsotg_tx_fifo_average_depth(struct dwc2_hsotg *hsotg)
{ return 0; }
static inline void dwc2_gadget_init_lpm(struct dwc2_hsotg *hsotg) {}
static inline void dwc2_gadget_program_ref_clk(struct dwc2_hsotg *hsotg) {}
#endif

#if IS_ENABLED(CONFIG_USB_DWC2_HOST) || IS_ENABLED(CONFIG_USB_DWC2_DUAL_ROLE)
Loading