* [PATCH v2 2/9] i2c: tegra: Add clk_prepare/clk_unprepare
[not found] ` <1338869966-8430-1-git-send-email-pgaikwad-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
@ 2012-06-05 4:19 ` Prashant Gaikwad
2012-06-05 4:19 ` [PATCH v2 6/9] spi/tegra: add clk_prepare/clk_unprepare Prashant Gaikwad
1 sibling, 0 replies; 6+ messages in thread
From: Prashant Gaikwad @ 2012-06-05 4:19 UTC (permalink / raw)
To: pgaikwad-DDmLM1+adcrQT0dZR+AlfA
Cc: khali-PUYAD+kWke1g9hUCZPvPmw, ben-linux-elnMNo+KYs3YtjvyW6yDsg,
w.sang-bIcnvbaLZ9MEGnE8C9+IrQ, linux-i2c-u79uwXL29TY76Z2rM5mHXA
Use clk_prepare/clk_unprepare as required by the generic clk framework.
Signed-off-by: Prashant Gaikwad <pgaikwad-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
---
This patch should go through Tegra tree since other patches to port tegra
to generic clock framework are dependent on it. Posting here to get ack from
the maintainers.
drivers/i2c/busses/i2c-tegra.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/i2c/busses/i2c-tegra.c b/drivers/i2c/busses/i2c-tegra.c
index 8b2e555..3da7ee3 100644
--- a/drivers/i2c/busses/i2c-tegra.c
+++ b/drivers/i2c/busses/i2c-tegra.c
@@ -341,7 +341,7 @@ static int tegra_i2c_init(struct tegra_i2c_dev *i2c_dev)
u32 val;
int err = 0;
- clk_enable(i2c_dev->clk);
+ clk_prepare_enable(i2c_dev->clk);
tegra_periph_reset_assert(i2c_dev->clk);
udelay(2);
@@ -372,7 +372,7 @@ static int tegra_i2c_init(struct tegra_i2c_dev *i2c_dev)
if (tegra_i2c_flush_fifos(i2c_dev))
err = -ETIMEDOUT;
- clk_disable(i2c_dev->clk);
+ clk_disable_unprepare(i2c_dev->clk);
if (i2c_dev->irq_disabled) {
i2c_dev->irq_disabled = 0;
@@ -546,14 +546,14 @@ static int tegra_i2c_xfer(struct i2c_adapter *adap, struct i2c_msg msgs[],
if (i2c_dev->is_suspended)
return -EBUSY;
- clk_enable(i2c_dev->clk);
+ clk_prepare_enable(i2c_dev->clk);
for (i = 0; i < num; i++) {
int stop = (i == (num - 1)) ? 1 : 0;
ret = tegra_i2c_xfer_msg(i2c_dev, &msgs[i], stop);
if (ret)
break;
}
- clk_disable(i2c_dev->clk);
+ clk_disable_unprepare(i2c_dev->clk);
return ret ?: i;
}
@@ -666,7 +666,7 @@ static int __devinit tegra_i2c_probe(struct platform_device *pdev)
goto err_free;
}
- clk_enable(i2c_dev->i2c_clk);
+ clk_prepare_enable(i2c_dev->i2c_clk);
i2c_set_adapdata(&i2c_dev->adapter, i2c_dev);
i2c_dev->adapter.owner = THIS_MODULE;
--
1.7.4.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v2 3/9] mmc: tegra: add clk_prepare/clk_unprepare
[not found] <1338869966-8430-1-git-send-email-pgaikwad@nvidia.com>
@ 2012-06-05 4:19 ` Prashant Gaikwad
2012-06-05 4:19 ` [PATCH v2 5/9] Input: tegra-kbc - " Prashant Gaikwad
` (2 subsequent siblings)
3 siblings, 0 replies; 6+ messages in thread
From: Prashant Gaikwad @ 2012-06-05 4:19 UTC (permalink / raw)
To: pgaikwad; +Cc: cjb, linux-mmc
Use clk_prepare/clk_unprepare as required by the generic clk framework.
Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com>
---
This patch should go through Tegra tree since other patches to port tegra
to generic clock framework are dependent on it. Posting here to get ack from
the maintainers.
drivers/mmc/host/sdhci-tegra.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/mmc/host/sdhci-tegra.c b/drivers/mmc/host/sdhci-tegra.c
index b38d8a7..2789656 100644
--- a/drivers/mmc/host/sdhci-tegra.c
+++ b/drivers/mmc/host/sdhci-tegra.c
@@ -334,7 +334,7 @@ static int __devinit sdhci_tegra_probe(struct platform_device *pdev)
rc = PTR_ERR(clk);
goto err_clk_get;
}
- clk_enable(clk);
+ clk_prepare_enable(clk);
pltfm_host->clk = clk;
host->mmc->pm_caps = plat->pm_flags;
@@ -349,7 +349,7 @@ static int __devinit sdhci_tegra_probe(struct platform_device *pdev)
return 0;
err_add_host:
- clk_disable(pltfm_host->clk);
+ clk_disable_unprepare(pltfm_host->clk);
clk_put(pltfm_host->clk);
err_clk_get:
if (gpio_is_valid(plat->wp_gpio))
@@ -390,7 +390,7 @@ static int __devexit sdhci_tegra_remove(struct platform_device *pdev)
if (gpio_is_valid(plat->power_gpio))
gpio_free(plat->power_gpio);
- clk_disable(pltfm_host->clk);
+ clk_disable_unprepare(pltfm_host->clk);
clk_put(pltfm_host->clk);
sdhci_pltfm_free(pdev);
--
1.7.4.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v2 5/9] Input: tegra-kbc - add clk_prepare/clk_unprepare
[not found] <1338869966-8430-1-git-send-email-pgaikwad@nvidia.com>
2012-06-05 4:19 ` [PATCH v2 3/9] mmc: tegra: add clk_prepare/clk_unprepare Prashant Gaikwad
@ 2012-06-05 4:19 ` Prashant Gaikwad
2012-06-05 5:20 ` Shubhrajyoti
[not found] ` <1338869966-8430-1-git-send-email-pgaikwad-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2012-06-05 4:19 ` [PATCH v2 9/9] crypto: " Prashant Gaikwad
3 siblings, 1 reply; 6+ messages in thread
From: Prashant Gaikwad @ 2012-06-05 4:19 UTC (permalink / raw)
To: pgaikwad; +Cc: dmitry.torokhov, linux-input
Use clk_prepare/clk_unprepare as required by the generic clk framework.
Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com>
---
This patch should go through Tegra tree since other patches to port tegra
to generic clock framework are dependent on it. Posting here to get ack from
the maintainers.
drivers/input/keyboard/tegra-kbc.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/input/keyboard/tegra-kbc.c b/drivers/input/keyboard/tegra-kbc.c
index 4ffe64d..2c1c9ed 100644
--- a/drivers/input/keyboard/tegra-kbc.c
+++ b/drivers/input/keyboard/tegra-kbc.c
@@ -492,7 +492,7 @@ static int tegra_kbc_start(struct tegra_kbc *kbc)
unsigned int debounce_cnt;
u32 val = 0;
- clk_enable(kbc->clk);
+ clk_prepare_enable(kbc->clk);
/* Reset the KBC controller to clear all previous status.*/
tegra_periph_reset_assert(kbc->clk);
@@ -556,7 +556,7 @@ static void tegra_kbc_stop(struct tegra_kbc *kbc)
disable_irq(kbc->irq);
del_timer_sync(&kbc->timer);
- clk_disable(kbc->clk);
+ clk_disable_unprepare(kbc->clk);
}
static int tegra_kbc_open(struct input_dev *dev)
--
1.7.4.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v2 6/9] spi/tegra: add clk_prepare/clk_unprepare
[not found] ` <1338869966-8430-1-git-send-email-pgaikwad-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2012-06-05 4:19 ` [PATCH v2 2/9] i2c: tegra: Add clk_prepare/clk_unprepare Prashant Gaikwad
@ 2012-06-05 4:19 ` Prashant Gaikwad
1 sibling, 0 replies; 6+ messages in thread
From: Prashant Gaikwad @ 2012-06-05 4:19 UTC (permalink / raw)
To: pgaikwad-DDmLM1+adcrQT0dZR+AlfA
Cc: spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
Use clk_prepare/clk_unprepare as required by the generic clk framework.
Signed-off-by: Prashant Gaikwad <pgaikwad-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
---
This patch should go through Tegra tree since other patches to port Tegra
to generic clock framework are dependent on it. Posting here to get ack from
the maintainers.
drivers/spi/spi-tegra.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/spi-tegra.c b/drivers/spi/spi-tegra.c
index ae6d78a..7f99ff3 100644
--- a/drivers/spi/spi-tegra.c
+++ b/drivers/spi/spi-tegra.c
@@ -261,7 +261,7 @@ static void spi_tegra_start_transfer(struct spi_device *spi,
clk_set_rate(tspi->clk, speed);
if (tspi->cur_speed == 0)
- clk_enable(tspi->clk);
+ clk_prepare_enable(tspi->clk);
tspi->cur_speed = speed;
@@ -373,7 +373,7 @@ static void tegra_spi_rx_dma_complete(struct tegra_dma_req *req)
spi = m->state;
spi_tegra_start_message(spi, m);
} else {
- clk_disable(tspi->clk);
+ clk_disable_unprepare(tspi->clk);
tspi->cur_speed = 0;
}
}
--
1.7.4.1
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH v2 9/9] crypto: add clk_prepare/clk_unprepare
[not found] <1338869966-8430-1-git-send-email-pgaikwad@nvidia.com>
` (2 preceding siblings ...)
[not found] ` <1338869966-8430-1-git-send-email-pgaikwad-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
@ 2012-06-05 4:19 ` Prashant Gaikwad
3 siblings, 0 replies; 6+ messages in thread
From: Prashant Gaikwad @ 2012-06-05 4:19 UTC (permalink / raw)
To: pgaikwad; +Cc: herbert, davem, linux-crypto
Use clk_prepare/clk_unprepare as required by the generic clk framework.
Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com>
---
This patch should go through Tegra tree since other patches to port Tegra
to generic clock framework are dependent on it. Posting here to get ack from
the maintainers.
drivers/crypto/tegra-aes.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/crypto/tegra-aes.c b/drivers/crypto/tegra-aes.c
index 422a976..ac236f6 100644
--- a/drivers/crypto/tegra-aes.c
+++ b/drivers/crypto/tegra-aes.c
@@ -572,7 +572,7 @@ static void aes_workqueue_handler(struct work_struct *work)
struct tegra_aes_dev *dd = aes_dev;
int ret;
- ret = clk_enable(dd->aes_clk);
+ ret = clk_prepare_enable(dd->aes_clk);
if (ret)
BUG_ON("clock enable failed");
@@ -581,7 +581,7 @@ static void aes_workqueue_handler(struct work_struct *work)
ret = tegra_aes_handle_req(dd);
} while (!ret);
- clk_disable(dd->aes_clk);
+ clk_disable_unprepare(dd->aes_clk);
}
static irqreturn_t aes_irq(int irq, void *dev_id)
@@ -673,7 +673,7 @@ static int tegra_aes_get_random(struct crypto_rng *tfm, u8 *rdata,
/* take mutex to access the aes hw */
mutex_lock(&aes_lock);
- ret = clk_enable(dd->aes_clk);
+ ret = clk_prepare_enable(dd->aes_clk);
if (ret)
return ret;
@@ -700,7 +700,7 @@ static int tegra_aes_get_random(struct crypto_rng *tfm, u8 *rdata,
}
out:
- clk_disable(dd->aes_clk);
+ clk_disable_unprepare(dd->aes_clk);
mutex_unlock(&aes_lock);
dev_dbg(dd->dev, "%s: done\n", __func__);
@@ -758,7 +758,7 @@ static int tegra_aes_rng_reset(struct crypto_rng *tfm, u8 *seed,
dd->flags = FLAGS_ENCRYPT | FLAGS_RNG;
- ret = clk_enable(dd->aes_clk);
+ ret = clk_prepare_enable(dd->aes_clk);
if (ret)
return ret;
@@ -788,7 +788,7 @@ static int tegra_aes_rng_reset(struct crypto_rng *tfm, u8 *seed,
memcpy(dd->dt, dt, DEFAULT_RNG_BLK_SZ);
out:
- clk_disable(dd->aes_clk);
+ clk_disable_unprepare(dd->aes_clk);
mutex_unlock(&aes_lock);
dev_dbg(dd->dev, "%s: done\n", __func__);
--
1.7.4.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH v2 5/9] Input: tegra-kbc - add clk_prepare/clk_unprepare
2012-06-05 4:19 ` [PATCH v2 5/9] Input: tegra-kbc - " Prashant Gaikwad
@ 2012-06-05 5:20 ` Shubhrajyoti
0 siblings, 0 replies; 6+ messages in thread
From: Shubhrajyoti @ 2012-06-05 5:20 UTC (permalink / raw)
To: Prashant Gaikwad; +Cc: dmitry.torokhov, linux-input
On Tuesday 05 June 2012 09:49 AM, Prashant Gaikwad wrote:
> Use clk_prepare/clk_unprepare as required by the generic clk framework.
Not a comment just curious to know what does
clk_prepare/clk_unprepare do differently vis a vis enable.
> Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com>
> ---
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2012-06-05 5:20 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1338869966-8430-1-git-send-email-pgaikwad@nvidia.com>
2012-06-05 4:19 ` [PATCH v2 3/9] mmc: tegra: add clk_prepare/clk_unprepare Prashant Gaikwad
2012-06-05 4:19 ` [PATCH v2 5/9] Input: tegra-kbc - " Prashant Gaikwad
2012-06-05 5:20 ` Shubhrajyoti
[not found] ` <1338869966-8430-1-git-send-email-pgaikwad-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2012-06-05 4:19 ` [PATCH v2 2/9] i2c: tegra: Add clk_prepare/clk_unprepare Prashant Gaikwad
2012-06-05 4:19 ` [PATCH v2 6/9] spi/tegra: add clk_prepare/clk_unprepare Prashant Gaikwad
2012-06-05 4:19 ` [PATCH v2 9/9] crypto: " Prashant Gaikwad
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.