lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Thu,  8 Nov 2012 20:39:54 +0530
From:	Viresh Kumar <viresh.kumar@...aro.org>
To:	jgarzik@...ox.com
Cc:	linux-ide@...r.kernel.org, linux-kernel@...r.kernel.org,
	spear-devel@...t.st.com,
	Vipul Kumar Samar <vipulkumar.samar@...com>,
	Viresh Kumar <viresh.kumar@...aro.org>
Subject: [PATCH] ata: pata_arasan: Initialize cf clock to 166MHz

From: Vipul Kumar Samar <vipulkumar.samar@...com>

PATA arasan driver expects the clock to be set to 166 MHz for proper functioning.
This patch sets clk to 166 MHz in probe.

Signed-off-by: Vipul Kumar Samar <vipulkumar.samar@...com>
Signed-off-by: Viresh Kumar <viresh.kumar@...aro.org>
---
 drivers/ata/pata_arasan_cf.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/ata/pata_arasan_cf.c b/drivers/ata/pata_arasan_cf.c
index 26201eb..71111f2 100644
--- a/drivers/ata/pata_arasan_cf.c
+++ b/drivers/ata/pata_arasan_cf.c
@@ -317,6 +317,12 @@ static int cf_init(struct arasan_cf_dev *acdev)
 		return ret;
 	}
 
+	ret = clk_set_rate(acdev->clk, 166000000);
+	if (ret) {
+		dev_warn(acdev->host->dev, "clock set rate failed");
+		return ret;
+	}
+
 	spin_lock_irqsave(&acdev->host->lock, flags);
 	/* configure CF interface clock */
 	writel((pdata->cf_if_clk <= CF_IF_CLK_200M) ? pdata->cf_if_clk :
-- 
1.7.12.rc2.18.g61b472e

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ