aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-sh-msiof.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/spi/spi-sh-msiof.c')
-rw-r--r--drivers/spi/spi-sh-msiof.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/spi/spi-sh-msiof.c b/drivers/spi/spi-sh-msiof.c
index 239be7cbe5a8..96a5fc0878d8 100644
--- a/drivers/spi/spi-sh-msiof.c
+++ b/drivers/spi/spi-sh-msiof.c
@@ -480,6 +480,8 @@ static int sh_msiof_spi_setup(struct spi_device *spi)
480 struct device_node *np = spi->master->dev.of_node; 480 struct device_node *np = spi->master->dev.of_node;
481 struct sh_msiof_spi_priv *p = spi_master_get_devdata(spi->master); 481 struct sh_msiof_spi_priv *p = spi_master_get_devdata(spi->master);
482 482
483 pm_runtime_get_sync(&p->pdev->dev);
484
483 if (!np) { 485 if (!np) {
484 /* 486 /*
485 * Use spi->controller_data for CS (same strategy as spi_gpio), 487 * Use spi->controller_data for CS (same strategy as spi_gpio),
@@ -498,6 +500,9 @@ static int sh_msiof_spi_setup(struct spi_device *spi)
498 if (spi->cs_gpio >= 0) 500 if (spi->cs_gpio >= 0)
499 gpio_set_value(spi->cs_gpio, !(spi->mode & SPI_CS_HIGH)); 501 gpio_set_value(spi->cs_gpio, !(spi->mode & SPI_CS_HIGH));
500 502
503
504 pm_runtime_put_sync(&p->pdev->dev);
505
501 return 0; 506 return 0;
502} 507}
503 508