aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Reichel <sre@kernel.org>2016-06-17 16:05:32 -0400
committerSebastian Reichel <sre@kernel.org>2016-06-27 18:39:43 -0400
commitd2b8d695c61c4d2864eee900bebc2ced4f425645 (patch)
tree5ec3e41a3c67c61c28fbe8de3bfb63778cff293b
parentfa1572d956ee072e965da01d2c46f10d2b67d017 (diff)
HSI: omap_ssi_port: replace pm_runtime_put_sync with non-sync variant
There is no need to wait for hardware to really reach idle states, so just release runtime PM asynchronously. Signed-off-by: Sebastian Reichel <sre@kernel.org> Tested-by: Pavel Machek <pavel@ucw.cz>
-rw-r--r--drivers/hsi/controllers/omap_ssi_port.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/hsi/controllers/omap_ssi_port.c b/drivers/hsi/controllers/omap_ssi_port.c
index 92064221dbab..aef5a8666d48 100644
--- a/drivers/hsi/controllers/omap_ssi_port.c
+++ b/drivers/hsi/controllers/omap_ssi_port.c
@@ -375,7 +375,7 @@ static int ssi_async_break(struct hsi_msg *msg)
375 spin_unlock_bh(&omap_port->lock); 375 spin_unlock_bh(&omap_port->lock);
376 } 376 }
377out: 377out:
378 pm_runtime_put_sync(omap_port->pdev); 378 pm_runtime_put(omap_port->pdev);
379 379
380 return err; 380 return err;
381} 381}
@@ -515,7 +515,7 @@ static int ssi_setup(struct hsi_client *cl)
515 omap_port->ssr.mode = cl->rx_cfg.mode; 515 omap_port->ssr.mode = cl->rx_cfg.mode;
516out: 516out:
517 spin_unlock_bh(&omap_port->lock); 517 spin_unlock_bh(&omap_port->lock);
518 pm_runtime_put_sync(omap_port->pdev); 518 pm_runtime_put(omap_port->pdev);
519 519
520 return err; 520 return err;
521} 521}
@@ -546,7 +546,7 @@ static int ssi_flush(struct hsi_client *cl)
546 continue; 546 continue;
547 writew_relaxed(0, omap_ssi->gdd + SSI_GDD_CCR_REG(i)); 547 writew_relaxed(0, omap_ssi->gdd + SSI_GDD_CCR_REG(i));
548 if (msg->ttype == HSI_MSG_READ) 548 if (msg->ttype == HSI_MSG_READ)
549 pm_runtime_put_sync(omap_port->pdev); 549 pm_runtime_put(omap_port->pdev);
550 omap_ssi->gdd_trn[i].msg = NULL; 550 omap_ssi->gdd_trn[i].msg = NULL;
551 } 551 }
552 /* Flush all SST buffers */ 552 /* Flush all SST buffers */
@@ -570,7 +570,7 @@ static int ssi_flush(struct hsi_client *cl)
570 for (i = 0; i < omap_port->channels; i++) { 570 for (i = 0; i < omap_port->channels; i++) {
571 /* Release write clocks */ 571 /* Release write clocks */
572 if (!list_empty(&omap_port->txqueue[i])) 572 if (!list_empty(&omap_port->txqueue[i]))
573 pm_runtime_put_sync(omap_port->pdev); 573 pm_runtime_put(omap_port->pdev);
574 ssi_flush_queue(&omap_port->txqueue[i], NULL); 574 ssi_flush_queue(&omap_port->txqueue[i], NULL);
575 ssi_flush_queue(&omap_port->rxqueue[i], NULL); 575 ssi_flush_queue(&omap_port->rxqueue[i], NULL);
576 } 576 }
@@ -580,7 +580,7 @@ static int ssi_flush(struct hsi_client *cl)
580 pinctrl_pm_select_default_state(omap_port->pdev); 580 pinctrl_pm_select_default_state(omap_port->pdev);
581 581
582 spin_unlock_bh(&omap_port->lock); 582 spin_unlock_bh(&omap_port->lock);
583 pm_runtime_put_sync(omap_port->pdev); 583 pm_runtime_put(omap_port->pdev);
584 584
585 return 0; 585 return 0;
586} 586}
@@ -687,7 +687,7 @@ static void ssi_cleanup_queues(struct hsi_client *cl)
687 txbufstate |= (1 << i); 687 txbufstate |= (1 << i);
688 status |= SSI_DATAACCEPT(i); 688 status |= SSI_DATAACCEPT(i);
689 /* Release the clocks writes, also GDD ones */ 689 /* Release the clocks writes, also GDD ones */
690 pm_runtime_put_sync(omap_port->pdev); 690 pm_runtime_put(omap_port->pdev);
691 } 691 }
692 ssi_flush_queue(&omap_port->txqueue[i], cl); 692 ssi_flush_queue(&omap_port->txqueue[i], cl);
693 } 693 }
@@ -742,7 +742,7 @@ static void ssi_cleanup_gdd(struct hsi_controller *ssi, struct hsi_client *cl)
742 * ssi_cleanup_queues 742 * ssi_cleanup_queues
743 */ 743 */
744 if (msg->ttype == HSI_MSG_READ) 744 if (msg->ttype == HSI_MSG_READ)
745 pm_runtime_put_sync(omap_port->pdev); 745 pm_runtime_put(omap_port->pdev);
746 omap_ssi->gdd_trn[i].msg = NULL; 746 omap_ssi->gdd_trn[i].msg = NULL;
747 } 747 }
748 tmp = readl_relaxed(omap_ssi->sys + SSI_GDD_MPU_IRQ_ENABLE_REG); 748 tmp = readl_relaxed(omap_ssi->sys + SSI_GDD_MPU_IRQ_ENABLE_REG);
@@ -790,7 +790,7 @@ static int ssi_release(struct hsi_client *cl)
790 WARN_ON(omap_port->wk_refcount != 0); 790 WARN_ON(omap_port->wk_refcount != 0);
791 } 791 }
792 spin_unlock_bh(&omap_port->lock); 792 spin_unlock_bh(&omap_port->lock);
793 pm_runtime_put_sync(omap_port->pdev); 793 pm_runtime_put(omap_port->pdev);
794 794
795 return 0; 795 return 0;
796} 796}
@@ -937,7 +937,7 @@ static void ssi_pio_complete(struct hsi_port *port, struct list_head *queue)
937 reg = readl(omap_ssi->sys + SSI_MPU_ENABLE_REG(port->num, 0)); 937 reg = readl(omap_ssi->sys + SSI_MPU_ENABLE_REG(port->num, 0));
938 if (msg->ttype == HSI_MSG_WRITE) { 938 if (msg->ttype == HSI_MSG_WRITE) {
939 /* Release clocks for write transfer */ 939 /* Release clocks for write transfer */
940 pm_runtime_put_sync(omap_port->pdev); 940 pm_runtime_put(omap_port->pdev);
941 } 941 }
942 reg &= ~val; 942 reg &= ~val;
943 writel_relaxed(reg, omap_ssi->sys + SSI_MPU_ENABLE_REG(port->num, 0)); 943 writel_relaxed(reg, omap_ssi->sys + SSI_MPU_ENABLE_REG(port->num, 0));