diff options
author | Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com> | 2014-11-10 06:02:47 -0500 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2014-11-12 10:11:31 -0500 |
commit | d3cf6a4b01894e69e9e800ef76f34eaa13357ff1 (patch) | |
tree | e4a6fb6fc850b1c3d5750d847874b650af349f58 | |
parent | 53e734b1ec13af5e4d687681275a56acfde646ba (diff) |
usb: renesas_usbhs: expand USB-DMAC channels for R-Car Gen2
This patch expands USB-DMAC channels for R-Car Gen2 SoCs. The SoCs
have 4 channels. If d{2,3}_{t,x}x_id are not set, this driver never
uses the expanded USB-DMAC channels.
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
-rw-r--r-- | drivers/usb/renesas_usbhs/common.h | 4 | ||||
-rw-r--r-- | drivers/usb/renesas_usbhs/fifo.c | 2 | ||||
-rw-r--r-- | drivers/usb/renesas_usbhs/fifo.h | 2 | ||||
-rw-r--r-- | include/linux/usb/renesas_usbhs.h | 4 |
4 files changed, 11 insertions, 1 deletions
diff --git a/drivers/usb/renesas_usbhs/common.h b/drivers/usb/renesas_usbhs/common.h index c45667f942b6..0427cdd1a483 100644 --- a/drivers/usb/renesas_usbhs/common.h +++ b/drivers/usb/renesas_usbhs/common.h | |||
@@ -102,6 +102,10 @@ struct usbhs_priv; | |||
102 | #define DEVADD8 0x00E0 | 102 | #define DEVADD8 0x00E0 |
103 | #define DEVADD9 0x00E2 | 103 | #define DEVADD9 0x00E2 |
104 | #define DEVADDA 0x00E4 | 104 | #define DEVADDA 0x00E4 |
105 | #define D2FIFOSEL 0x00F0 /* for R-Car Gen2 */ | ||
106 | #define D2FIFOCTR 0x00F2 /* for R-Car Gen2 */ | ||
107 | #define D3FIFOSEL 0x00F4 /* for R-Car Gen2 */ | ||
108 | #define D3FIFOCTR 0x00F6 /* for R-Car Gen2 */ | ||
105 | 109 | ||
106 | /* SYSCFG */ | 110 | /* SYSCFG */ |
107 | #define SCKE (1 << 10) /* USB Module Clock Enable */ | 111 | #define SCKE (1 << 10) /* USB Module Clock Enable */ |
diff --git a/drivers/usb/renesas_usbhs/fifo.c b/drivers/usb/renesas_usbhs/fifo.c index bc9a0506b54e..f46271ce1b15 100644 --- a/drivers/usb/renesas_usbhs/fifo.c +++ b/drivers/usb/renesas_usbhs/fifo.c | |||
@@ -1234,6 +1234,8 @@ int usbhs_fifo_probe(struct usbhs_priv *priv) | |||
1234 | /* DFIFO */ | 1234 | /* DFIFO */ |
1235 | USBHS_DFIFO_INIT(priv, fifo, 0); | 1235 | USBHS_DFIFO_INIT(priv, fifo, 0); |
1236 | USBHS_DFIFO_INIT(priv, fifo, 1); | 1236 | USBHS_DFIFO_INIT(priv, fifo, 1); |
1237 | USBHS_DFIFO_INIT_NO_PORT(priv, fifo, 2); | ||
1238 | USBHS_DFIFO_INIT_NO_PORT(priv, fifo, 3); | ||
1237 | 1239 | ||
1238 | return 0; | 1240 | return 0; |
1239 | } | 1241 | } |
diff --git a/drivers/usb/renesas_usbhs/fifo.h b/drivers/usb/renesas_usbhs/fifo.h index 899729ac085f..f07037c1185f 100644 --- a/drivers/usb/renesas_usbhs/fifo.h +++ b/drivers/usb/renesas_usbhs/fifo.h | |||
@@ -38,7 +38,7 @@ struct usbhs_fifo { | |||
38 | struct sh_dmae_slave rx_slave; | 38 | struct sh_dmae_slave rx_slave; |
39 | }; | 39 | }; |
40 | 40 | ||
41 | #define USBHS_MAX_NUM_DFIFO 2 | 41 | #define USBHS_MAX_NUM_DFIFO 4 |
42 | struct usbhs_fifo_info { | 42 | struct usbhs_fifo_info { |
43 | struct usbhs_fifo cfifo; | 43 | struct usbhs_fifo cfifo; |
44 | struct usbhs_fifo dfifo[USBHS_MAX_NUM_DFIFO]; | 44 | struct usbhs_fifo dfifo[USBHS_MAX_NUM_DFIFO]; |
diff --git a/include/linux/usb/renesas_usbhs.h b/include/linux/usb/renesas_usbhs.h index d5952bb66752..9fd9e481ea98 100644 --- a/include/linux/usb/renesas_usbhs.h +++ b/include/linux/usb/renesas_usbhs.h | |||
@@ -145,6 +145,10 @@ struct renesas_usbhs_driver_param { | |||
145 | int d0_rx_id; | 145 | int d0_rx_id; |
146 | int d1_tx_id; | 146 | int d1_tx_id; |
147 | int d1_rx_id; | 147 | int d1_rx_id; |
148 | int d2_tx_id; | ||
149 | int d2_rx_id; | ||
150 | int d3_tx_id; | ||
151 | int d3_rx_id; | ||
148 | 152 | ||
149 | /* | 153 | /* |
150 | * option: | 154 | * option: |