diff options
author | Matthijs Kooijman <matthijs@stdin.nl> | 2013-08-30 12:45:18 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-08-30 17:14:53 -0400 |
commit | c35205aa051244a5ee8ed1e124b9c7b890d97ad9 (patch) | |
tree | 951fa3f1a3054e5969b4f9813352b3b142862982 | |
parent | 57bb8aeda06af912f92f10a18a446c1e1e000fc1 (diff) |
staging: dwc2: re-use hptxfsiz variable
For some reason, the value of the HPTXFSIZ register was built in the
ptxfsiz variable, while there was also a hptxfsiz variable availble.
Better just use that and remove the (now unused) ptxfsiz variable.
Signed-off-by: Matthijs Kooijman <matthijs@stdin.nl>
Acked-by: Paul Zimmerman <paulz@synopsys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/dwc2/core.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/staging/dwc2/core.c b/drivers/staging/dwc2/core.c index 1f8988671eb7..5799f478980c 100644 --- a/drivers/staging/dwc2/core.c +++ b/drivers/staging/dwc2/core.c | |||
@@ -507,7 +507,7 @@ void dwc2_disable_host_interrupts(struct dwc2_hsotg *hsotg) | |||
507 | static void dwc2_config_fifos(struct dwc2_hsotg *hsotg) | 507 | static void dwc2_config_fifos(struct dwc2_hsotg *hsotg) |
508 | { | 508 | { |
509 | struct dwc2_core_params *params = hsotg->core_params; | 509 | struct dwc2_core_params *params = hsotg->core_params; |
510 | u32 rxfsiz, nptxfsiz, ptxfsiz, hptxfsiz, dfifocfg; | 510 | u32 rxfsiz, nptxfsiz, hptxfsiz, dfifocfg; |
511 | 511 | ||
512 | if (!params->enable_dynamic_fifo) | 512 | if (!params->enable_dynamic_fifo) |
513 | return; | 513 | return; |
@@ -539,12 +539,12 @@ static void dwc2_config_fifos(struct dwc2_hsotg *hsotg) | |||
539 | /* Periodic Tx FIFO */ | 539 | /* Periodic Tx FIFO */ |
540 | dev_dbg(hsotg->dev, "initial hptxfsiz=%08x\n", | 540 | dev_dbg(hsotg->dev, "initial hptxfsiz=%08x\n", |
541 | readl(hsotg->regs + HPTXFSIZ)); | 541 | readl(hsotg->regs + HPTXFSIZ)); |
542 | ptxfsiz = params->host_perio_tx_fifo_size << | 542 | hptxfsiz = params->host_perio_tx_fifo_size << |
543 | FIFOSIZE_DEPTH_SHIFT & FIFOSIZE_DEPTH_MASK; | 543 | FIFOSIZE_DEPTH_SHIFT & FIFOSIZE_DEPTH_MASK; |
544 | ptxfsiz |= (params->host_rx_fifo_size + | 544 | hptxfsiz |= (params->host_rx_fifo_size + |
545 | params->host_nperio_tx_fifo_size) << | 545 | params->host_nperio_tx_fifo_size) << |
546 | FIFOSIZE_STARTADDR_SHIFT & FIFOSIZE_STARTADDR_MASK; | 546 | FIFOSIZE_STARTADDR_SHIFT & FIFOSIZE_STARTADDR_MASK; |
547 | writel(ptxfsiz, hsotg->regs + HPTXFSIZ); | 547 | writel(hptxfsiz, hsotg->regs + HPTXFSIZ); |
548 | dev_dbg(hsotg->dev, "new hptxfsiz=%08x\n", | 548 | dev_dbg(hsotg->dev, "new hptxfsiz=%08x\n", |
549 | readl(hsotg->regs + HPTXFSIZ)); | 549 | readl(hsotg->regs + HPTXFSIZ)); |
550 | 550 | ||