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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1359978868-28736-44-git-send-email-lee.jones@linaro.org>
Date:	Mon,  4 Feb 2013 11:53:58 +0000
From:	Lee Jones <lee.jones@...aro.org>
To:	linux-kernel@...r.kernel.org, broonie@...nsource.wolfsonmicro.com
Cc:	Lee Jones <lee.jones@...aro.org>,
	Zhenhua HUANG <zhenhua.huang@...ricsson.com>
Subject: [PATCH 43/73] regulator: ab8500: Add VSDIO definition for the AB8540

Add the definitions for VSDIO to Regulator Framework for AB8540.

Signed-off-by: Zhenhua HUANG <zhenhua.huang@...ricsson.com>
Signed-off-by: Lee Jones <lee.jones@...aro.org>
Reviewed-by: Xiao Mei ZHANG <xiaomei.zhang@...ricsson.com>
Reviewed-by: Mattias WALLIN <mattias.wallin@...ricsson.com>
Reviewed-by: Mian Yousaf KAUKAB <mian.yousaf.kaukab@...ricsson.com>
Reviewed-by: Philippe LANGLAIS <philippe.langlais@...ricsson.com>
Tested-by: Maxime COQUELIN <maxime.coquelin@...ricsson.com>
---
 drivers/regulator/ab8500.c       |   35 +++++++++++++++++++++++++++++++++++
 include/linux/regulator/ab8500.h |    1 +
 2 files changed, 36 insertions(+)

diff --git a/drivers/regulator/ab8500.c b/drivers/regulator/ab8500.c
index 1f1f361..2a08642 100644
--- a/drivers/regulator/ab8500.c
+++ b/drivers/regulator/ab8500.c
@@ -132,6 +132,17 @@ static const unsigned int ldo_vintcore_voltages[] = {
 	1350000,
 };
 
+static const int ldo_sdio_voltages[] = {
+	1160000,
+	1050000,
+	1100000,
+	1500000,
+	1800000,
+	2200000,
+	2910000,
+	3050000,
+};
+
 static int ab8500_regulator_enable(struct regulator_dev *rdev)
 {
 	int ret;
@@ -1409,6 +1420,30 @@ static struct ab8500_regulator_info
 		.update_val_idle	= 0x0c,
 		.update_val_normal	= 0x04,
 	},
+	[AB8540_LDO_SDIO] = {
+		.desc = {
+			.name		= "LDO-SDIO",
+			.ops		= &ab8500_regulator_volt_mode_ops,
+			.type		= REGULATOR_VOLTAGE,
+			.id		= AB8540_LDO_SDIO,
+			.owner		= THIS_MODULE,
+			.n_voltages = ARRAY_SIZE(ldo_sdio_voltages),
+		},
+		.min_uV			= 1050000,
+		.max_uV			= 3050000,
+		.load_lp_uA		= 5000,
+		.update_bank		= 0x03,
+		.update_reg		= 0x88,
+		.update_mask		= 0x30,
+		.update_val		= 0x10,
+		.update_val_idle	= 0x00,
+		.update_val_normal	= 0x20,
+		.voltage_bank		= 0x03,
+		.voltage_reg		= 0x88,
+		.voltage_mask		= 0x07,
+		.voltages		= ldo_sdio_voltages,
+		.voltages_len		= ARRAY_SIZE(ldo_sdio_voltages),
+	},
 };
 
 struct ab8500_reg_init {
diff --git a/include/linux/regulator/ab8500.h b/include/linux/regulator/ab8500.h
index e3d4a5b..caa9f6a 100644
--- a/include/linux/regulator/ab8500.h
+++ b/include/linux/regulator/ab8500.h
@@ -82,6 +82,7 @@ enum ab8540_regulator_id {
 	AB8540_LDO_ANAMIC2,
 	AB8540_LDO_DMIC,
 	AB8540_LDO_ANA,
+	AB8540_LDO_SDIO,
 	AB8540_SYSCLKREQ_2,
 	AB8540_SYSCLKREQ_4,
 	AB8540_NUM_REGULATORS,
-- 
1.7.9.5

--
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