imx6: disable MSI interrupts
[oweals/openwrt.git] / target / linux / lantiq / patches-4.4 / 0060-usb-dwc2-Add-support-for-Lantiq-ARX-and-XRX-SoCs.patch
1 From 6c0c0951bbf8c2c216675fe277fba4c42aa0a2bf Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Antti=20Sepp=C3=A4l=C3=A4?= <a.seppala@gmail.com>
3 Date: Sat, 27 Feb 2016 12:31:24 +0200
4 Subject: [PATCH] usb: dwc2: Add support for Lantiq ARX and XRX SoCs
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 Add support for Lantiq ARX and XRX SoC families to the dwc2 driver.
10
11 Acked-by: John Youn <johnyoun@synopsys.com>
12 Signed-off-by: Antti Seppälä <a.seppala@gmail.com>
13 Signed-off-by: Felipe Balbi <balbi@kernel.org>
14 ---
15  Documentation/devicetree/bindings/usb/dwc2.txt |  2 ++
16  drivers/usb/dwc2/platform.c                    | 34 ++++++++++++++++++++++++++
17  2 files changed, 36 insertions(+)
18
19 --- a/Documentation/devicetree/bindings/usb/dwc2.txt
20 +++ b/Documentation/devicetree/bindings/usb/dwc2.txt
21 @@ -7,6 +7,8 @@ Required properties:
22    - rockchip,rk3066-usb: The DWC2 USB controller instance in the rk3066 Soc;
23    - "rockchip,rk3188-usb", "rockchip,rk3066-usb", "snps,dwc2": for rk3188 Soc;
24    - "rockchip,rk3288-usb", "rockchip,rk3066-usb", "snps,dwc2": for rk3288 Soc;
25 +  - "lantiq,arx100-usb": The DWC2 USB controller instance in Lantiq ARX SoCs;
26 +  - "lantiq,xrx200-usb": The DWC2 USB controller instance in Lantiq XRX SoCs;
27    - snps,dwc2: A generic DWC2 USB controller with default parameters.
28  - reg : Should contain 1 register range (address and length)
29  - interrupts : Should contain 1 interrupt
30 --- a/drivers/usb/dwc2/platform.c
31 +++ b/drivers/usb/dwc2/platform.c
32 @@ -116,6 +116,37 @@ static const struct dwc2_core_params par
33         .hibernation                    = -1,
34  };
35  
36 +static const struct dwc2_core_params params_ltq = {
37 +       .otg_cap                        = 2,    /* non-HNP/non-SRP */
38 +       .otg_ver                        = -1,
39 +       .dma_enable                     = -1,
40 +       .dma_desc_enable                = -1,
41 +       .speed                          = -1,
42 +       .enable_dynamic_fifo            = -1,
43 +       .en_multiple_tx_fifo            = -1,
44 +       .host_rx_fifo_size              = 288,  /* 288 DWORDs */
45 +       .host_nperio_tx_fifo_size       = 128,  /* 128 DWORDs */
46 +       .host_perio_tx_fifo_size        = 96,   /* 96 DWORDs */
47 +       .max_transfer_size              = 65535,
48 +       .max_packet_count               = 511,
49 +       .host_channels                  = -1,
50 +       .phy_type                       = -1,
51 +       .phy_utmi_width                 = -1,
52 +       .phy_ulpi_ddr                   = -1,
53 +       .phy_ulpi_ext_vbus              = -1,
54 +       .i2c_enable                     = -1,
55 +       .ulpi_fs_ls                     = -1,
56 +       .host_support_fs_ls_low_power   = -1,
57 +       .host_ls_low_power_phy_clk      = -1,
58 +       .ts_dline                       = -1,
59 +       .reload_ctl                     = -1,
60 +       .ahbcfg                         = GAHBCFG_HBSTLEN_INCR16 <<
61 +                                         GAHBCFG_HBSTLEN_SHIFT,
62 +       .uframe_sched                   = -1,
63 +       .external_id_pin_ctl            = -1,
64 +       .hibernation                    = -1,
65 +};
66 +
67  static int __dwc2_lowlevel_hw_enable(struct dwc2_hsotg *hsotg)
68  {
69         struct platform_device *pdev = to_platform_device(hsotg->dev);
70 @@ -310,6 +341,8 @@ static int dwc2_driver_remove(struct pla
71  static const struct of_device_id dwc2_of_match_table[] = {
72         { .compatible = "brcm,bcm2835-usb", .data = &params_bcm2835 },
73         { .compatible = "rockchip,rk3066-usb", .data = &params_rk3066 },
74 +       { .compatible = "lantiq,arx100-usb", .data = &params_ltq },
75 +       { .compatible = "lantiq,xrx200-usb", .data = &params_ltq },
76         { .compatible = "snps,dwc2", .data = NULL },
77         { .compatible = "samsung,s3c6400-hsotg", .data = NULL},
78         {},