aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Wahren <stefan.wahren@i2se.com>2016-11-20 16:26:02 -0500
committerFelipe Balbi <felipe.balbi@linux.intel.com>2017-01-02 03:55:28 -0500
commitf3419735279564d40467ebe4147d8a41cef00685 (patch)
treeb16cd2ee96df9c0e61b4116d7e54c5eeb16a9a31
parent0c744ea4f77d72b3dcebb7a8f2684633ec79be88 (diff)
usb: dwc2: Do not set host parameter in peripheral mode
Since commit "usb: dwc2: Improve handling of host and device hwparams" the host mode specific hardware parameter aren't initialized in peripheral mode from the register settings anymore. So we better do not set them in this case which avoids the following warnings on bcm2835: 256 invalid for host_nperio_tx_fifo_size. Check HW configuration. 512 invalid for host_perio_tx_fifo_size. Check HW configuration. Fixes: 55e1040e424b ("usb: dwc2: Improve handling of host and device hwparams") Acked-by: John Youn <johnyoun@synopsys.com> Signed-off-by: Stefan Wahren <stefan.wahren@i2se.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
-rw-r--r--drivers/usb/dwc2/params.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/usb/dwc2/params.c b/drivers/usb/dwc2/params.c
index a786256535b6..fd5f7f83843d 100644
--- a/drivers/usb/dwc2/params.c
+++ b/drivers/usb/dwc2/params.c
@@ -1132,6 +1132,12 @@ static void dwc2_set_parameters(struct dwc2_hsotg *hsotg,
1132 false, "host-dma", 1132 false, "host-dma",
1133 true, false, 1133 true, false,
1134 dma_capable); 1134 dma_capable);
1135 dwc2_set_param_host_rx_fifo_size(hsotg,
1136 params->host_rx_fifo_size);
1137 dwc2_set_param_host_nperio_tx_fifo_size(hsotg,
1138 params->host_nperio_tx_fifo_size);
1139 dwc2_set_param_host_perio_tx_fifo_size(hsotg,
1140 params->host_perio_tx_fifo_size);
1135 } 1141 }
1136 dwc2_set_param_dma_desc_enable(hsotg, params->dma_desc_enable); 1142 dwc2_set_param_dma_desc_enable(hsotg, params->dma_desc_enable);
1137 dwc2_set_param_dma_desc_fs_enable(hsotg, params->dma_desc_fs_enable); 1143 dwc2_set_param_dma_desc_fs_enable(hsotg, params->dma_desc_fs_enable);
@@ -1140,12 +1146,6 @@ static void dwc2_set_parameters(struct dwc2_hsotg *hsotg,
1140 params->host_support_fs_ls_low_power); 1146 params->host_support_fs_ls_low_power);
1141 dwc2_set_param_enable_dynamic_fifo(hsotg, 1147 dwc2_set_param_enable_dynamic_fifo(hsotg,
1142 params->enable_dynamic_fifo); 1148 params->enable_dynamic_fifo);
1143 dwc2_set_param_host_rx_fifo_size(hsotg,
1144 params->host_rx_fifo_size);
1145 dwc2_set_param_host_nperio_tx_fifo_size(hsotg,
1146 params->host_nperio_tx_fifo_size);
1147 dwc2_set_param_host_perio_tx_fifo_size(hsotg,
1148 params->host_perio_tx_fifo_size);
1149 dwc2_set_param_max_transfer_size(hsotg, 1149 dwc2_set_param_max_transfer_size(hsotg,
1150 params->max_transfer_size); 1150 params->max_transfer_size);
1151 dwc2_set_param_max_packet_count(hsotg, 1151 dwc2_set_param_max_packet_count(hsotg,